#define GST_VALUE_HOLDS_BUFFER(x) (G_VALUE_HOLDS((x), GST_TYPE_BUFFER))
/**
- * GST_VALUE_HOLDS_FRACTION:
+ * GST_VALUE_HOLDS_SAMPLE:
* @x: the #GValue to check
*
- * Checks if the given #GValue contains a #GST_TYPE_FRACTION value.
+ * Checks if the given #GValue contains a #GST_TYPE_SAMPLE value.
*/
-#define GST_VALUE_HOLDS_FRACTION(x) (G_VALUE_HOLDS((x), gst_fraction_get_type ()))
+#define GST_VALUE_HOLDS_SAMPLE(x) (G_VALUE_HOLDS((x), GST_TYPE_SAMPLE))
/**
- * GST_VALUE_HOLDS_DATE:
+ * GST_VALUE_HOLDS_FRACTION:
* @x: the #GValue to check
*
- * Checks if the given #GValue contains a #GST_TYPE_DATE value.
+ * Checks if the given #GValue contains a #GST_TYPE_FRACTION value.
*/
-#define GST_VALUE_HOLDS_DATE(x) (G_VALUE_HOLDS((x), gst_date_get_type ()))
+#define GST_VALUE_HOLDS_FRACTION(x) (G_VALUE_HOLDS((x), gst_fraction_get_type ()))
/**
* GST_VALUE_HOLDS_DATE_TIME:
#define GST_VALUE_HOLDS_DATE_TIME(x) (G_VALUE_HOLDS((x), gst_date_time_get_type ()))
/**
+ * GST_VALUE_HOLDS_BITMASK:
+ * @x: the #GValue to check
+ *
+ * Checks if the given #GValue contains a #GST_TYPE_BITMASK value.
+ */
+#define GST_VALUE_HOLDS_BITMASK(x) (G_VALUE_HOLDS((x), gst_bitmask_get_type ()))
+
+/**
* GST_TYPE_INT_RANGE:
*
* a #GValue type that represents an integer range
#define GST_TYPE_FRACTION gst_fraction_get_type ()
/**
- * GST_TYPE_DATE:
+ * GST_TYPE_DATE_TIME:
*
- * a boxed #GValue type for #GDate that represents a date.
+ * a boxed #GValue type for #GstDateTime that represents a date and time.
*
- * Returns: the #GType of GstDate
+ * Returns: the #GType of GstDateTime
+ * Since: 0.10.31
*/
-#define GST_TYPE_DATE gst_date_get_type ()
+#define GST_TYPE_DATE_TIME gst_date_time_get_type ()
/**
- * GST_TYPE_DATE_TIME:
+ * GST_TYPE_BITMASK:
*
- * a boxed #GValue type for #GstDateTime that represents a date and time.
+ * a #GValue type that represents a 64-bit bitmask.
*
- * Returns: the #GType of GstDateTime
- * Since: 0.10.31
+ * Returns: the #GType of GstBitmask (which is not explicitly typed)
*/
-#define GST_TYPE_DATE_TIME gst_date_time_get_type ()
+#define GST_TYPE_BITMASK gst_bitmask_get_type ()
/**
* GST_VALUE_LESS_THAN:
typedef gboolean (* GstValueDeserializeFunc) (GValue *dest,
const gchar *s);
-/**
- * GstValueUnionFunc:
- * @dest: a #GValue for the result
- * @value1: a #GValue operand
- * @value2: a #GValue operand
- *
- * Used by gst_value_union() to perform unification for a specific #GValue
- * type. Register a new implementation with gst_value_register_union_func().
- *
- * Returns: %TRUE if a union was successful
- */
-typedef gboolean (* GstValueUnionFunc) (GValue *dest,
- const GValue *value1,
- const GValue *value2);
-
-/**
- * GstValueIntersectFunc:
- * @dest: (out caller-allocates): a #GValue for the result
- * @value1: a #GValue operand
- * @value2: a #GValue operand
- *
- * Used by gst_value_intersect() to perform intersection for a specific #GValue
- * type. If the intersection is non-empty, the result is
- * placed in @dest and TRUE is returned. If the intersection is
- * empty, @dest is unmodified and FALSE is returned.
- * Register a new implementation with gst_value_register_intersect_func().
- *
- * Returns: %TRUE if the values can intersect
- */
-typedef gboolean (* GstValueIntersectFunc) (GValue *dest,
- const GValue *value1,
- const GValue *value2);
-
-/**
- * GstValueSubtractFunc:
- * @dest: (out caller-allocates): a #GValue for the result
- * @minuend: a #GValue operand
- * @subtrahend: a #GValue operand
- *
- * Used by gst_value_subtract() to perform subtraction for a specific #GValue
- * type. Register a new implementation with gst_value_register_subtract_func().
- *
- * Returns: %TRUE if the subtraction is not empty
- */
-typedef gboolean (* GstValueSubtractFunc) (GValue *dest,
- const GValue *minuend,
- const GValue *subtrahend);
-
typedef struct _GstValueTable GstValueTable;
/**
* GstValueTable:
GType gst_fraction_get_type (void);
GType gst_value_list_get_type (void);
GType gst_value_array_get_type (void);
+GType gst_bitmask_get_type (void);
-GType gst_date_get_type (void);
GType gst_date_time_get_type (void);
void gst_value_register (const GstValueTable *table);
void gst_value_set_int_range (GValue *value,
gint start,
gint end);
+void gst_value_set_int_range_step (GValue *value,
+ gint start,
+ gint end,
+ gint step);
gint gst_value_get_int_range_min (const GValue *value);
gint gst_value_get_int_range_max (const GValue *value);
+gint gst_value_get_int_range_step (const GValue *value);
/* int64 range */
void gst_value_set_int64_range (GValue *value,
gint64 start,
gint64 end);
+void gst_value_set_int64_range_step (GValue *value,
+ gint64 start,
+ gint64 end,
+ gint64 step);
gint64 gst_value_get_int64_range_min (const GValue *value);
gint64 gst_value_get_int64_range_max (const GValue *value);
+gint64 gst_value_get_int64_range_step (const GValue *value);
/* double range */
void gst_value_set_double_range (GValue *value,
const GValue *gst_value_get_fraction_range_min (const GValue *value);
const GValue *gst_value_get_fraction_range_max (const GValue *value);
-/* date */
-const GDate * gst_value_get_date (const GValue *value);
-void gst_value_set_date (GValue *value,
- const GDate *date);
+/* bitmask */
+guint64 gst_value_get_bitmask (const GValue *value);
+void gst_value_set_bitmask (GValue *value,
+ guint64 bitmask);
/* compare */
gint gst_value_compare (const GValue *value1,
const GValue *value2);
gboolean gst_value_can_compare (const GValue *value1,
const GValue *value2);
+gboolean gst_value_is_subset (const GValue *value1,
+ const GValue *value2);
+
/* union */
gboolean gst_value_union (GValue *dest,
const GValue *value1,
const GValue *value2);
gboolean gst_value_can_union (const GValue *value1,
const GValue *value2);
-void gst_value_register_union_func (GType type1,
- GType type2,
- GstValueUnionFunc func);
/* intersection */
gboolean gst_value_intersect (GValue *dest,
const GValue *value2);
gboolean gst_value_can_intersect (const GValue *value1,
const GValue *value2);
-void gst_value_register_intersect_func (GType type1,
- GType type2,
- GstValueIntersectFunc func);
/* subtraction */
gboolean gst_value_subtract (GValue *dest,
const GValue *subtrahend);
gboolean gst_value_can_subtract (const GValue *minuend,
const GValue *subtrahend);
-void gst_value_register_subtract_func (GType minuend_type,
- GType subtrahend_type,
- GstValueSubtractFunc func);
/* fixation */
gboolean gst_value_is_fixed (const GValue *value);