[Bug 777206] mosaic issue for MPEG DASH live streaming

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Tue Jan 17 02:54:47 UTC 2017


https://bugzilla.gnome.org/show_bug.cgi?id=777206

John Chang <r97922153 at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #343518|needs-work                  |none
             status|                            |
 Attachment #343518|0                           |1
        is obsolete|                            |

--- Comment #9 from John Chang <r97922153 at gmail.com> ---
Created attachment 343607
  --> https://bugzilla.gnome.org/attachment.cgi?id=343607&action=edit
Fix the issue when updating thread sets slow start without passing necessary
header & caps down

Dear Sebastian:

::: ext/dash/gstdashdemux.c
@@ +1154,3 @@
   if (gst_mpd_client_get_next_fragment_timestamp (dashdemux->client,
           dashstream->index, &ts)) {
+    if (gst_mpd_client_is_live(dashdemux->client)) {

Why only for live streams? Should be the same for VOD streams?

=> it is because the issue only happens when we have an update loop thread
which may set representation as slow start. For VOD, since there are only
download loop thread & source thread there, it has no problem. 
As the result, I make this check to avoid redundant actions for VOD.



@@ +1164,3 @@
+                dashstream->active_stream->cur_representation->bandwidth);
+            caps = gst_dash_demux_get_input_caps (dashdemux,
dashstream->active_stream);
+            gst_adaptive_demux_stream_set_caps (stream, caps);

You're probably leaking the caps here

=> according to the latest version of gst_adaptive_demux_stream_set_caps()

/* must be called with manifest_lock taken */
void
gst_adaptive_demux_stream_set_caps (GstAdaptiveDemuxStream * stream,
    GstCaps * caps)
{
  GST_DEBUG_OBJECT (stream->pad, "setting new caps for stream %"
GST_PTR_FORMAT,
      caps);
  gst_caps_replace (&stream->pending_caps, caps);
  gst_caps_unref (caps);
}

It unrefs the caps at the end.

Also, from the usage case within gst_dash_demux_stream_select_bitrate()
    ...
    if (gst_mpd_client_setup_representation (demux->client, active_stream,
rep)) {
      GstCaps *caps;

      GST_INFO_OBJECT (demux, "Switching bitrate to %d",
          active_stream->cur_representation->bandwidth);
      caps = gst_dash_demux_get_input_caps (demux, active_stream);
      gst_adaptive_demux_stream_set_caps (stream, caps);
      ret = TRUE;

    } else {
      GST_WARNING_OBJECT (demux, "Can not switch representation, aborting...");
    }
    ...

It seems to pass the caps and the caps will be unreffered within
gst_adaptive_demux_stream_set_caps().

Thanks a lot for your suggestion.

John Chang

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list