mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-29 19:50:40 +00:00
mp4gdepay: reset depayloader state
This commit is contained in:
parent
e8b8753c90
commit
1eb0f65f39
1 changed files with 14 additions and 9 deletions
|
@ -315,6 +315,18 @@ gst_rtp_mp4g_depay_clear_queue (GstRtpMP4GDepay * rtpmp4gdepay)
|
|||
gst_buffer_unref (outbuf);
|
||||
}
|
||||
|
||||
static void
|
||||
gst_rtp_mp4g_depay_reset (GstRtpMP4GDepay * rtpmp4gdepay)
|
||||
{
|
||||
gst_adapter_clear (rtpmp4gdepay->adapter);
|
||||
rtpmp4gdepay->max_AU_index = -1;
|
||||
rtpmp4gdepay->next_AU_index = -1;
|
||||
rtpmp4gdepay->prev_AU_index = -1;
|
||||
rtpmp4gdepay->prev_rtptime = -1;
|
||||
rtpmp4gdepay->last_AU_index = -1;
|
||||
gst_rtp_mp4g_depay_clear_queue (rtpmp4gdepay);
|
||||
}
|
||||
|
||||
static void
|
||||
gst_rtp_mp4g_depay_flush_queue (GstRtpMP4GDepay * rtpmp4gdepay)
|
||||
{
|
||||
|
@ -710,13 +722,7 @@ gst_rtp_mp4g_depay_change_state (GstElement * element,
|
|||
|
||||
switch (transition) {
|
||||
case GST_STATE_CHANGE_READY_TO_PAUSED:
|
||||
gst_adapter_clear (rtpmp4gdepay->adapter);
|
||||
rtpmp4gdepay->max_AU_index = -1;
|
||||
rtpmp4gdepay->next_AU_index = -1;
|
||||
rtpmp4gdepay->prev_AU_index = -1;
|
||||
rtpmp4gdepay->prev_rtptime = -1;
|
||||
rtpmp4gdepay->last_AU_index = -1;
|
||||
rtpmp4gdepay->prev_AU_num = -1;
|
||||
gst_rtp_mp4g_depay_reset (rtpmp4gdepay);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
@ -726,8 +732,7 @@ gst_rtp_mp4g_depay_change_state (GstElement * element,
|
|||
|
||||
switch (transition) {
|
||||
case GST_STATE_CHANGE_PAUSED_TO_READY:
|
||||
gst_adapter_clear (rtpmp4gdepay->adapter);
|
||||
gst_rtp_mp4g_depay_clear_queue (rtpmp4gdepay);
|
||||
gst_rtp_mp4g_depay_reset (rtpmp4gdepay);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue