[Bug 775615] decodebin3: Select default track by GstStreamFlags
GStreamer (GNOME Bugzilla)
bugzilla at gnome.org
Thu Feb 2 07:29:40 UTC 2017
https://bugzilla.gnome.org/show_bug.cgi?id=775615
Edward Hervey <bilboed at bilboed.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #344712|none |needs-work
status| |
--- Comment #15 from Edward Hervey <bilboed at bilboed.com> ---
Review of attachment 344712:
--> (https://bugzilla.gnome.org/review?bug=775615&attachment=344712)
::: gst/playback/gstdecodebin3.c
@@ +1102,3 @@
+ * GCompareFunc to use with lists of GstStream.
+ * Sorts GstStreams by mime type and select flag and stream-id
+ * First video, then audio, then others.
Is there any added-value for having it in that order of types ?
It just adds complexity to the code. Just using the type itself (which is an
enum) should be sufficient (it still groups them by stream type).
@@ +1143,3 @@
+
+ ret =
+ (flaga == GST_STREAM_FLAG_SELECT) ? ((flagb ==
Use & instead of == (it's a flagset, not an enum).
@@ +1153,3 @@
+ ida = gst_stream_get_stream_id (sa);
+ idb = gst_stream_get_stream_id (sb);
+ ret = (ida) ? ((idb) ? g_strcmp0 (ida, idb) : -1) : 1;
just use g_strcmp0() directly. It handles NULL entries gracefully.
@@ +1165,3 @@
GstStreamCollection *res = NULL;
GList *tmp;
+ GList *all_streams = NULL;
rename it to unsorted_streams for clarity.
--
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