mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
mxf: Don't use GLib 2.16 API unconditionally in the example
This commit is contained in:
parent
22a9d7577f
commit
922e6428f6
1 changed files with 4 additions and 0 deletions
|
@ -30,8 +30,12 @@ static gchar *
|
|||
g_value_to_string (const GValue * val)
|
||||
{
|
||||
if (G_VALUE_TYPE (val) == GST_TYPE_BUFFER) {
|
||||
#if GLIB_CHECK_VERSION (2,16,0)
|
||||
const GstBuffer *buf = gst_value_get_buffer (val);
|
||||
gchar *ret = g_base64_encode (GST_BUFFER_DATA (buf), GST_BUFFER_SIZE (buf));
|
||||
#else
|
||||
gchar *ret = gst_value_serialize (val);
|
||||
#endif
|
||||
|
||||
return ret;
|
||||
} else {
|
||||
|
|
Loading…
Reference in a new issue