pad: make an ACCEPT_CAPS query
[platform/upstream/gstreamer.git] / gst / gstquery.h
index 4b0a2e2..db0e9e4 100644 (file)
@@ -55,6 +55,7 @@ G_BEGIN_DECLS
  * @GST_QUERY_URI: query the URI of the source or sink. Since 0.10.22.
  * @GST_QUERY_ALLOCATION: the buffer allocation properties
  * @GST_QUERY_SCHEDULING: the scheduling properties
+ * @GST_QUERY_ACCEPT_CAPS: the accept caps query
  *
  * Standard predefined Query types
  */
@@ -75,7 +76,9 @@ typedef enum {
   GST_QUERY_CUSTOM,
   GST_QUERY_URI,
   GST_QUERY_ALLOCATION,
-  GST_QUERY_SCHEDULING
+  GST_QUERY_SCHEDULING,
+  GST_QUERY_ACCEPT_CAPS,
+  GST_QUERY_LAST
 } GstQueryType;
 
 /**
@@ -143,7 +146,6 @@ struct _GstQueryTypeDefinition
  * GstQuery:
  * @mini_object: The parent #GstMiniObject type
  * @type: the #GstQueryType
- * @structure: the #GstStructure containing the query details.
  *
  * The #GstQuery structure.
  */
@@ -171,7 +173,7 @@ gboolean        gst_query_types_contains       (const GstQueryType *types,
 
 /* query for query details */
 
-G_CONST_RETURN GstQueryTypeDefinition*
+const GstQueryTypeDefinition*
                 gst_query_type_get_details         (GstQueryType type);
 GstIterator*    gst_query_type_iterate_definitions (void);
 
@@ -364,6 +366,11 @@ void            gst_query_parse_allocation_params (GstQuery *query, guint *size,
 void            gst_query_add_allocation_meta       (GstQuery *query, const gchar *api);
 guint           gst_query_get_n_allocation_metas    (GstQuery *query);
 const gchar *   gst_query_parse_nth_allocation_meta (GstQuery *query, guint index);
+gboolean        gst_query_has_allocation_meta       (GstQuery *query, const gchar *api);
+
+void            gst_query_add_allocation_memory       (GstQuery *query, const gchar *alloc);
+guint           gst_query_get_n_allocation_memories   (GstQuery *query);
+const gchar *   gst_query_parse_nth_allocation_memory (GstQuery *query, guint index);
 
 /* scheduling query */
 GstQuery *      gst_query_new_scheduling          (void);
@@ -374,6 +381,11 @@ void            gst_query_set_scheduling          (GstQuery *query, gboolean pul
 void            gst_query_parse_scheduling        (GstQuery *query, gboolean *pull_mode,
                                                    gboolean *random_access, gboolean *sequential,
                                                    gint *minsize, gint *maxsize, gint *align);
+/* accept-caps query */
+GstQuery *      gst_query_new_accept_caps          (GstCaps *caps);
+void            gst_query_parse_accept_caps        (GstQuery *query, GstCaps **caps);
+void            gst_query_set_accept_caps_result   (GstQuery *query, gboolean result);
+void            gst_query_parse_accept_caps_result (GstQuery *query, gboolean *result);
 
 G_END_DECLS