Search
SailfishOS Open Build Service
>
Projects
>
home:sledge
:
branches:nemo:devel:hw:ti:omap4:common
>
gstreamer
> hand_revert_f56c6e12255b37d75b1eb949e434fa8e3bb33f51
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File hand_revert_f56c6e12255b37d75b1eb949e434fa8e3bb33f51 of Package gstreamer
Description: Workaround webcam issues Manually revert upstream commit f56c6e12255b37d75b1eb949e434fa8e3bb33f51 That's to fix LP: #966294 Author: Stéphane Graber <stgraber@ubuntu.com> Index: precise/libs/gst/base/gstbasetransform.c =================================================================== --- precise.orig/libs/gst/base/gstbasetransform.c 2012-04-12 16:59:32.000000000 +0200 +++ precise/libs/gst/base/gstbasetransform.c 2012-04-12 17:07:45.389486730 +0200 @@ -700,7 +700,7 @@ GstBaseTransform *trans; GstPad *otherpad; const GstCaps *templ; - GstCaps *peercaps, *caps, *temp; + GstCaps *caps, *temp; gboolean samecaps; int cache_index; @@ -710,10 +710,10 @@ cache_index = (pad == trans->srcpad) ? 0 : 1; /* we can do what the peer can */ - peercaps = gst_pad_peer_get_caps_reffed (otherpad); + caps = gst_pad_peer_get_caps_reffed (otherpad); GST_OBJECT_LOCK (trans); - samecaps = (peercaps && trans->priv->cached_peer_caps[cache_index] - && gst_caps_is_strictly_equal (peercaps, + samecaps = (caps && trans->priv->cached_peer_caps[cache_index] + && gst_caps_is_strictly_equal (caps, trans->priv->cached_peer_caps[cache_index])); if (!samecaps) { if (trans->priv->cached_peer_caps[cache_index]) { @@ -732,14 +732,15 @@ } GST_OBJECT_UNLOCK (trans); - if (peercaps) { - GST_DEBUG_OBJECT (pad, "peer caps %" GST_PTR_FORMAT, peercaps); + if (caps) { + GST_DEBUG_OBJECT (pad, "peer caps %" GST_PTR_FORMAT, caps); /* filtered against our padtemplate on the other side */ templ = gst_pad_get_pad_template_caps (otherpad); GST_DEBUG_OBJECT (pad, "our template %" GST_PTR_FORMAT, templ); - temp = gst_caps_intersect_full (peercaps, templ, GST_CAPS_INTERSECT_FIRST); + temp = gst_caps_intersect (caps, templ); GST_DEBUG_OBJECT (pad, "intersected %" GST_PTR_FORMAT, temp); + gst_caps_unref (caps); } else { temp = gst_caps_copy (gst_pad_get_pad_template_caps (otherpad)); GST_DEBUG_OBJECT (pad, "no peer, using our template caps %" GST_PTR_FORMAT, @@ -763,24 +764,10 @@ gst_caps_unref (caps); caps = temp; - if (peercaps) { - /* Now try if we can put the untransformed downstream caps first */ - temp = gst_caps_intersect_full (peercaps, caps, GST_CAPS_INTERSECT_FIRST); - if (!gst_caps_is_empty (temp)) { - gst_caps_merge (temp, caps); - caps = temp; - } else { - gst_caps_unref (temp); - } - } - done_update_cache: GST_DEBUG_OBJECT (trans, "returning %" GST_PTR_FORMAT, caps); GST_OBJECT_LOCK (trans); - if (peercaps) { - trans->priv->cached_peer_caps[cache_index] = gst_caps_ref (peercaps); - } if (caps) { trans->priv->cached_transformed_caps[cache_index] = gst_caps_ref (caps); } @@ -788,9 +775,6 @@ done: GST_OBJECT_UNLOCK (trans); - if (peercaps) - gst_caps_unref (peercaps); - gst_object_unref (trans); return caps;