[Ffmpeg-devel] merge audio and video at frame level

Michel Bardiaux mbardiaux
Thu Jan 18 10:46:20 CET 2007

Paul wrote:
>> From a webcam (micro integrated ):
> 1) i have buffer PCM , and i success to encode this buffer to MPEG1
> frame(s) audio. 2) I also can capture webcam to different buffer and
> encode to MPEG1 frame video. But video and audio are seperated
> stream. All of audio frame(s) will be write direct to audio output
> file. And All of Video frames also write to video output file.
> So, after have video and audio output. I will use ffmpeg.exe to
> merge. But i can see the final output seem not synch. if i capture
> long time, i see have not synch. I check the audio output is correct
> time of recording but video output is missing. So when merge , i see
> the final output cannot synch audio with video.
> How can i make synch improve?
> Can i also have different question: i see ffmpeg.exe can merge audio
> and video to final video (file level). So, can you show me where/what
> is sample code to merge MPEG1 audio frame and MPEG1 video frame
> (frame level) to the final frame, so that i will write directly final
> frame to the final output file?

This belongs on ffmpeg-user. ffmpeg-devel is for development *of*, not 
*with*, ffmpeg.

Michel Bardiaux
R&D Director
T +32 [0] 2 790 29 41
F +32 [0] 2 790 29 02
E mailto:mbardiaux at mediaxim.be

Mediaxim NV/SA
Vorstlaan 191 Boulevard du Souverain
Brussel 1160 Bruxelles

More information about the ffmpeg-devel mailing list