mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-11 09:55:36 +00:00
Flashed out transform function
Original commit message from CVS: Flashed out transform function
This commit is contained in:
parent
6637a949e7
commit
580a572044
1 changed files with 23 additions and 13 deletions
|
@ -74,6 +74,8 @@ transform_func (const GValue *src_value,
|
|||
{
|
||||
GstProps *props = g_value_peek_pointer (src_value);
|
||||
GString *result = g_string_new ("");
|
||||
|
||||
if (props) {
|
||||
GList *propslist = props->properties;
|
||||
|
||||
while (propslist) {
|
||||
|
@ -82,7 +84,14 @@ transform_func (const GValue *src_value,
|
|||
|
||||
switch (entry->propstype) {
|
||||
case GST_PROPS_STRING_TYPE:
|
||||
g_string_append_printf (result, "%s='%s'", name, entry->data.string_data.string);
|
||||
g_string_append_printf (result, "%s=(string) '%s'", name, entry->data.string_data.string);
|
||||
break;
|
||||
case GST_PROPS_INT_TYPE:
|
||||
g_string_append_printf (result, "%s=(int) %d", name, entry->data.int_data);
|
||||
break;
|
||||
case GST_PROPS_FOURCC_TYPE:
|
||||
g_string_append_printf (result, "%s=(fourcc) '%4.4s'", name, (gchar *)&entry->data.fourcc_data);
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
@ -92,6 +101,7 @@ transform_func (const GValue *src_value,
|
|||
g_string_append (result, "; ");
|
||||
}
|
||||
}
|
||||
}
|
||||
dest_value->data[0].v_pointer = result->str;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue