jifmux: Add GstTagXmpWriter support
Adds GstTagXmpWriter interface to jifmux element
This commit is contained in:
parent
3061e8d7c8
commit
dfe64965d7
@ -5,8 +5,8 @@ libgstjpegformat_la_CFLAGS = \
|
|||||||
$(GST_PLUGINS_BASE_CFLAGS) \
|
$(GST_PLUGINS_BASE_CFLAGS) \
|
||||||
$(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS)
|
$(GST_PLUGINS_BASE_CFLAGS) $(GST_CFLAGS)
|
||||||
libgstjpegformat_la_LIBADD = \
|
libgstjpegformat_la_LIBADD = \
|
||||||
$(GST_PLUGINS_BASE_LIBS) -lgsttag-@GST_MAJORMINOR@ \
|
$(GST_PLUGINS_BASE_LIBS) -lgstinterfaces-@GST_MAJORMINOR@ \
|
||||||
$(GST_LIBS) $(GST_BASE_LIBS)
|
-lgsttag-@GST_MAJORMINOR@ $(GST_LIBS) $(GST_BASE_LIBS)
|
||||||
libgstjpegformat_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
libgstjpegformat_la_LDFLAGS = $(GST_PLUGIN_LDFLAGS)
|
||||||
libgstjpegformat_la_LIBTOOLFLAGS = --tag=disable-static
|
libgstjpegformat_la_LIBTOOLFLAGS = --tag=disable-static
|
||||||
|
|
||||||
|
@ -58,6 +58,7 @@ gst-launch videotestsrc num-buffers=1 ! jpegenc ! taginject tags="comment=\"test
|
|||||||
#include <gst/base/gstbytereader.h>
|
#include <gst/base/gstbytereader.h>
|
||||||
#include <gst/base/gstbytewriter.h>
|
#include <gst/base/gstbytewriter.h>
|
||||||
#include <gst/tag/tag.h>
|
#include <gst/tag/tag.h>
|
||||||
|
#include <gst/tag/xmpwriter.h>
|
||||||
|
|
||||||
#include "gstjifmux.h"
|
#include "gstjifmux.h"
|
||||||
|
|
||||||
@ -118,8 +119,11 @@ static void
|
|||||||
gst_jif_type_init (GType type)
|
gst_jif_type_init (GType type)
|
||||||
{
|
{
|
||||||
static const GInterfaceInfo tag_setter_info = { NULL, NULL, NULL };
|
static const GInterfaceInfo tag_setter_info = { NULL, NULL, NULL };
|
||||||
|
static const GInterfaceInfo tag_xmp_writer_info = { NULL, NULL, NULL };
|
||||||
|
|
||||||
g_type_add_interface_static (type, GST_TYPE_TAG_SETTER, &tag_setter_info);
|
g_type_add_interface_static (type, GST_TYPE_TAG_SETTER, &tag_setter_info);
|
||||||
|
g_type_add_interface_static (type, GST_TYPE_TAG_XMP_WRITER,
|
||||||
|
&tag_xmp_writer_info);
|
||||||
|
|
||||||
GST_DEBUG_CATEGORY_INIT (jif_mux_debug, "jifmux", 0,
|
GST_DEBUG_CATEGORY_INIT (jif_mux_debug, "jifmux", 0,
|
||||||
"JPEG interchange format muxer");
|
"JPEG interchange format muxer");
|
||||||
@ -570,7 +574,9 @@ gst_jif_mux_mangle_markers (GstJifMux * self)
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* add xmp */
|
/* add xmp */
|
||||||
xmp_data = gst_tag_list_to_xmp_buffer (tags, FALSE);
|
xmp_data =
|
||||||
|
gst_tag_xmp_writer_tag_list_to_xmp_buffer (GST_TAG_XMP_WRITER (self),
|
||||||
|
tags, FALSE);
|
||||||
if (xmp_data) {
|
if (xmp_data) {
|
||||||
guint8 *data, *xmp = GST_BUFFER_DATA (xmp_data);
|
guint8 *data, *xmp = GST_BUFFER_DATA (xmp_data);
|
||||||
guint size = GST_BUFFER_SIZE (xmp_data);
|
guint size = GST_BUFFER_SIZE (xmp_data);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user