[gst-devel] Audio playback not sync with video playback

Michael Smith msmith at xiph.org
Wed Jun 16 19:20:52 CEST 2010


On Wed, Jun 16, 2010 at 2:13 AM, ericcardmanNo3 <daniel.kuhne at yahoo.de> wrote:
>
> playing avi (mpeg4/mp3) files result in a bit faster video playback than
> audio playback.
> does anyone know such problem? how to solve it?
>
> i do:
>
> gst-launch filesrc location=/home/out_CR.avi ! avidemux name=demux
> demux.audio
> _00 ! mad ! volume volume=0.5 ! alsasink  demux.video_00 ! queue ! video
> /mpeg,scalewidth=512,scaleheight=288 ! mympeg4dec ! ximagesink

GStreamer handles synchronising the audio and video for you,
automatically - you don't need to do anything special.

However, in order to do this, it needs correct timestamps on the
buffers - since you're using a private element here ("mympeg4dec"), my
guess would be that you have a bug in there, and that you're putting
incorrect (or no) timestamps on the buffers being pushed out.

It should work correctly once you put correct timestamps on your buffers.

Mike




More information about the gstreamer-devel mailing list