[gstreamer-bugs] [Bug 617045] New: [caps] New method for intersecting caps while retaining order
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Wed Apr 28 00:36:19 PDT 2010
https://bugzilla.gnome.org/show_bug.cgi?id=617045
GStreamer | gstreamer (core) | git
Summary: [caps] New method for intersecting caps while
retaining order
Classification: Desktop
Product: GStreamer
Version: git
OS/Version: Linux
Status: UNCONFIRMED
Severity: enhancement
Priority: Normal
Component: gstreamer (core)
AssignedTo: gstreamer-bugs at lists.sourceforge.net
ReportedBy: bilboed at gmail.com
QAContact: gstreamer-bugs at lists.sourceforge.net
GNOME target: ---
GNOME version: ---
Right now gst_caps_intersect() intersects the caps by zig-zagging through the
structures of each caps. While this tries to keep a homogenous ordering for the
output, there are some cases where we want to intersect two caps but keep the
exact same ordering as one of the caps.
This is essential in two cases so far:
* default caps fixation in GstBaseSrc : we want to fixate to the first
intersecting caps from downstream.
* caps filtering in GstBaseTransform : we want to keep the ordering of caps
that the element gave to us.
c1 = Gst.Caps("A;B;C;D") # our sorted caps
c2 = Gst.Caps("D;A;B;C") # the unsorted caps
Example with gst_caps_intersect:
gst_caps_intersect(c1, c2) => "B;A;D;C"
gst_caps_intersect(c2, c1) => "A;B;D;C"
Example with gst_caps_sorted:
gst_caps_intersect_sorted(c1, c2) => "A;B;C;D"
gst_caps_intersect_sorted(c2, c1) => "D;A;B;C"
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- 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