projects
/
platform
/
upstream
/
gst-plugins-base.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
948d06e
)
videoscale: use can_intersect to avoid a caps copy
author
Stefan Kost
<ensonic@users.sf.net>
Thu, 6 May 2010 06:17:33 +0000
(09:17 +0300)
committer
Stefan Kost
<ensonic@users.sf.net>
Thu, 6 May 2010 06:17:33 +0000
(09:17 +0300)
gst/videoscale/gstvideoscale.c
patch
|
blob
|
history
diff --git
a/gst/videoscale/gstvideoscale.c
b/gst/videoscale/gstvideoscale.c
index
00479e1
..
1844e43
100644
(file)
--- a/
gst/videoscale/gstvideoscale.c
+++ b/
gst/videoscale/gstvideoscale.c
@@
-356,16
+356,13
@@
static int
gst_video_scale_get_format (GstCaps * caps)
{
gint i;
- GstCaps *
icaps, *
scaps;
+ GstCaps *scaps;
for (i = 0; i < G_N_ELEMENTS (gst_video_scale_format_caps); i++) {
scaps = gst_static_caps_get (&gst_video_scale_format_caps[i]);
- icaps = gst_caps_intersect (caps, scaps);
- if (!gst_caps_is_empty (icaps)) {
- gst_caps_unref (icaps);
+ if (gst_caps_can_intersect (caps, scaps)) {
return i;
}
- gst_caps_unref (icaps);
}
return -1;