Segment for video and audio decoder

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Segment for video and audio decoder

Majaja
Hi all:

I found that if I set segment to audio & video decoder, they behave differently.

For example, if the segment start = 5 seconds and playback from the beginning.

For video decoder = gstvideodecoder, the function gst_video_decoder_clip_and_push_buf () will drop the frames which are range from 0 to 5 seconds.

But for audio decoder, it seems that all packets are passed down & dropped at sink.

I am wondering why audio needs to do so. Why we do NOT just drop the packets at decoder as video?

Thanks~
Reply | Threaded
Open this post in threaded view
|

Re: Segment for video and audio decoder

Majaja
hi:

I guess I made a mistake.

The audio decoder actually check segment & drop the packets out of segment within gst_audio_decoder_push_forward()'s gst_audio_buffer_clip ().

Thanks
Reply | Threaded
Open this post in threaded view
|

Re: Segment for video and audio decoder

Sebastian Dröge-3
In reply to this post by Majaja
On Tue, 2016-09-06 at 00:24 -0700, Majaja wrote:

> Hi all:
>
> I found that if I set segment to audio & video decoder, they behave
> differently.
>
> For example, if the segment start = 5 seconds and playback from the
> beginning. 
>
> For video decoder = gstvideodecoder, the function
> gst_video_decoder_clip_and_push_buf () will drop the frames which are range
> from 0 to 5 seconds. 
>
> But for audio decoder, it seems that all packets are passed down & dropped
> at sink.
>
> I am wondering why audio needs to do so. Why we do NOT just drop the packets
> at decoder as video?
These lines here in GstAudioDecoder should clip/drop the frames:
https://cgit.freedesktop.org/gstreamer/gst-plugins-base/tree/gst-libs/gst/audio/gstaudiodecoder.c#n936

You'll have to debug inside that code to see why it doesn't do
anything.


What's the exact segment that is configured (all the values), and the
PTS/timestamp on the buffers getting there?

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (949 bytes) Download Attachment