From 912800fb76bec7bc64a1da796faa037c0bf33dc7 Mon Sep 17 00:00:00 2001 From: Thiago Santos Date: Tue, 26 Apr 2011 15:21:34 -0300 Subject: [PATCH] camerabin2: imagecapturebin: Fix tags merging mode Use merge replace mode to allow new tags to override old ones and fix the use case where the last sent tags should be serialized to the captured images. --- gst/camerabin2/gstimagecapturebin.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/gst/camerabin2/gstimagecapturebin.c b/gst/camerabin2/gstimagecapturebin.c index b4aba2aa08..7526d98883 100644 --- a/gst/camerabin2/gstimagecapturebin.c +++ b/gst/camerabin2/gstimagecapturebin.c @@ -327,6 +327,14 @@ gst_image_capture_bin_change_state (GstElement * element, GstStateChange trans) if (!gst_image_capture_bin_create_elements (imagebin)) { return GST_STATE_CHANGE_FAILURE; } + + /* set our image muxer to MERGE_REPLACE mode if it is a tagsetter */ + if (imagebin->muxer && gst_element_implements_interface (imagebin->muxer, + GST_TYPE_TAG_SETTER)) { + gst_tag_setter_set_tag_merge_mode (GST_TAG_SETTER (imagebin->muxer), + GST_TAG_MERGE_REPLACE); + } + break; default: break;