Log in

View Full Version : Extracting H264 video from .mov file


darshak
1st March 2008, 06:58
Hi Guys,

I need your help to solve a puzzle.

I would like to parse mov file containing H264 video and get H264 video stream.

I am using SPS and PPS data from mov file as below along with sample details.

00 00 00 01 + SPS Data + 00 00 00 01 + PPS Data + Sample[1] + Sample[2] ...+ Sample[n]
(assuming mov file has n samples)
(First 4 byte of each Sample is replaced with 00 00 00 01)

I am able to play generated H264 video in vlc, however it contains macro block.
It looks like that it can not get information to decode frame.

Is anyone in this forum know whether above approach is correct or not?

Regards,
DS

cacepi
1st March 2008, 09:14
I am able to play generated H264 video in vlc, however it contains macro block.
Why don't you use MP4Box? It can read .mov files:

MP4Box -raw TrackID filename.mov