* gst_query_add_allocation_meta:
* @query: a GST_QUERY_ALLOCATION type query #GstQuery
* @api: the metadata API
- * @params: (transfer full) (allow-none): API specific parameters
+ * @params: (transfer none) (allow-none): API specific parameters
*
* Add @api with @params as one of the supported metadata API to @query.
*/
void
gst_query_add_allocation_meta (GstQuery * query, GType api,
- GstStructure * params)
+ const GstStructure * params)
{
GArray *array;
GstStructure *structure;
(GDestroyNotify) allocation_meta_free);
am.api = api;
- am.params = params;
+ am.params = (params ? gst_structure_copy (params) : NULL);
g_array_append_val (array, am);
}
const GstAllocationParams *params);
/* metadata */
-void gst_query_add_allocation_meta (GstQuery *query, GType api, GstStructure *params);
+void gst_query_add_allocation_meta (GstQuery *query, GType api, const GstStructure *params);
guint gst_query_get_n_allocation_metas (GstQuery *query);
GType gst_query_parse_nth_allocation_meta (GstQuery *query, guint index,
const GstStructure **params);
api = gst_query_parse_nth_allocation_meta (decide_query, i, ¶ms);
GST_DEBUG_OBJECT (trans, "proposing metadata %s", g_type_name (api));
- gst_query_add_allocation_meta (query, api, gst_structure_copy (params));
+ gst_query_add_allocation_meta (query, api, params);
}
ret = TRUE;
}