summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ext/ffmpeg/gstffmpegenc.c5
-rw-r--r--ext/libswscale/gstffmpegscale.c4
2 files changed, 5 insertions, 4 deletions
diff --git a/ext/ffmpeg/gstffmpegenc.c b/ext/ffmpeg/gstffmpegenc.c
index 9388e09..df420a5 100644
--- a/ext/ffmpeg/gstffmpegenc.c
+++ b/ext/ffmpeg/gstffmpegenc.c
@@ -315,7 +315,7 @@ gst_ffmpegenc_finalize (GObject * object)
static GstCaps *
gst_ffmpegenc_get_possible_sizes (GstFFMpegEnc * ffmpegenc, GstPad * pad,
- const GstCaps * caps)
+ GstCaps * caps)
{
GstCaps *othercaps = NULL;
GstCaps *tmpcaps = NULL;
@@ -357,7 +357,8 @@ gst_ffmpegenc_get_possible_sizes (GstFFMpegEnc * ffmpegenc, GstPad * pad,
gst_structure_set_value (tmps, "height", height);
if (framerate)
gst_structure_set_value (tmps, "framerate", framerate);
- gst_caps_merge_structure (tmpcaps, tmps);
+
+ tmpcaps = gst_caps_merge_structure (tmpcaps, tmps);
}
gst_caps_unref (intersect);
diff --git a/ext/libswscale/gstffmpegscale.c b/ext/libswscale/gstffmpegscale.c
index a987f10..ae5fb83 100644
--- a/ext/libswscale/gstffmpegscale.c
+++ b/ext/libswscale/gstffmpegscale.c
@@ -311,14 +311,14 @@ gst_ffmpegscale_transform_caps (GstBaseTransform * trans,
"width", GST_TYPE_INT_RANGE, 1, G_MAXINT,
"height", GST_TYPE_INT_RANGE, 1, G_MAXINT, NULL);
- gst_caps_merge_structure (ret, gst_structure_copy (structure));
+ ret = gst_caps_merge_structure (ret, gst_structure_copy (structure));
/* if pixel aspect ratio, make a range of it */
if ((par = gst_structure_get_value (structure, "pixel-aspect-ratio"))) {
gst_structure_set (structure,
"pixel-aspect-ratio", GST_TYPE_FRACTION_RANGE, 0, 1, G_MAXINT, 1, NULL);
- gst_caps_merge_structure (ret, structure);
+ ret = gst_caps_merge_structure (ret, structure);
} else {
gst_structure_free (structure);
}