GNOME Bugzilla – Bug 772742
mpegtsdemux: Implement efficient program updates
Last modified: 2016-10-31 14:35:16 UTC
See commit message
Created attachment 337397 [details] [review] mpegtsdemux: Implement efficient program updates If the parent bin can handle it, only add/remove the new/gone stream instead of re-adding/re-moving everything
commit 6622e2dacf3d61d880ac7bcccf5680f62ccac7a0 Author: Edward Hervey <edward@centricular.com> Date: Tue Oct 11 11:11:16 2016 +0200 mpegtsdemux: Implement efficient program updates If the parent bin can handle it, only add/remove the new/gone stream instead of re-adding/re-moving everything https://bugzilla.gnome.org/show_bug.cgi?id=772742
Review of attachment 337397 [details] [review]: more review later ::: gst/mpegtsdemux/mpegtsbase.c @@ +213,3 @@ + base->streams_aware = GST_OBJECT_PARENT (base) + && GST_OBJECT_FLAG_IS_SET (GST_OBJECT_PARENT (base), + GST_BIN_FLAG_STREAMS_AWARE); This is not threadsafe and will also be wrong if the element is added to the bin after this.
_reset() is called in 3 places: * init (when created) * READY=>PAUSED * PAUSED=>READY Since elements are added *before* being set to PAUSED, this is not an issue. Usage of that streams-aware value will also be in the streaming-thread, i.e. after _reset() is called. Elements that are streams-aware will (or should) set this when initializing themselves (they either are or are not streams-aware). So not an issue there again.
Ok then! :)