[gst-devel] Video frame timings (revisited)

Michael Smith msmith at xiph.org
Wed Jan 12 17:40:14 CET 2011


On Wed, Jan 12, 2011 at 7:50 AM, Darren Staples
<dstaples at friendmts.co.uk> wrote:
> Hi, I'm hoping someone can help with this please, as I'm struggling...
>
> When doing audio and video decoding of a H.264 MP4 file I find that
> the timing of the video frames seems to be affected by the processing
> of the audio frames.
> My pipeline looks like this:
>
>                     / ffmpegcolorspace - queue - appsink
> uridecodebin
>                    \ audioconvert - queue - appsink
>
> I have setup callbacks on both the audio and video appsinks.
> In the video callback I get the buffer from the appsink and then call
> gst_element_query_position() to get the frame time.
> In the audio callback I'm just getting the buffer and discarding it (for now).

Don't use gst_element_query_position, then. It's not doing what you want.

Instead, use the buffer timestamps directly (GST_BUFFER_TIMESTAMP(buffer)).

Mike




More information about the gstreamer-devel mailing list