gst/: doc updates
authorThomas Vander Stichele <thomas@apestaart.org>
Mon, 10 Oct 2005 09:48:21 +0000 (09:48 +0000)
committerThomas Vander Stichele <thomas@apestaart.org>
Mon, 10 Oct 2005 09:48:21 +0000 (09:48 +0000)
Original commit message from CVS:

* gst/gstcaps.c:
* gst/gstevent.c:
doc updates
* gst/gstvalue.c: (gst_value_deserialize_int_helper):
don't use long long, it's not portable.  Replacing with
gint64 seems to work; let's hope no skeletons fall out of the closet.

ChangeLog
gst/gstcaps.c
gst/gstevent.c
gst/gstvalue.c

index b0f1f60..5c66026 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2005-10-10  Thomas Vander Stichele  <thomas at apestaart dot org>
+
+       * gst/gstcaps.c:
+       * gst/gstevent.c:
+         doc updates
+       * gst/gstvalue.c: (gst_value_deserialize_int_helper):
+         don't use long long, it's not portable.  Replacing with
+         gint64 seems to work; let's hope no skeletons fall out of the closet.
+
 2005-10-10  Andy Wingo  <wingo@pobox.com>
 
        * autogen.sh (CONFIGURE_DEF_OPT): No more --plugin-buiddir, yay
index 02860d1..311a547 100644 (file)
@@ -82,6 +82,7 @@ gst_caps_get_type (void)
  *
  * Creates a new #GstCaps that is empty.  That is, the returned
  * #GstCaps contains no media formats.
+ * Caller is responsible for unreffing the returned caps.
  *
  * Returns: the new #GstCaps
  */
@@ -128,6 +129,7 @@ gst_caps_new_any (void)
  * Creates a new #GstCaps that contains one #GstStructure.  The
  * structure is defined by the arguments, which have the same format
  * as @gst_structure_new().
+ * Caller is responsible for unreffing the returned caps.
  *
  * Returns: the new #GstCaps
  */
index e49eea2..516b99b 100644 (file)
  */
 /**
  * SECTION:gstevent
- * @short_description: Structure describing events that are passed up and down a pipeline
+ * @short_description: Structure describing events that are passed up and down
+ *                     a pipeline
  * @see_also: #GstPad, #GstElement
  *
  * The event classes are used to construct and query events.
  *
- * Events are usually created with gst_event_new_*() which takes the extra event 
- * paramters as arguments. 
+ * Events are usually created with gst_event_new_*() which takes the extra
+ * event parameters as arguments.
  * Events can be parsed with their respective gst_event_parse_*() functions.
- * The event should be unreferenced with gst_event_unref().
+ * The event should be unreffed with gst_event_unref().
  *
- * gst_event_new_seek() is usually used to create a seek event and it takes
+ * gst_event_new_seek() is usually used to create a seek event and it takes
  * the needed parameters for a seek event.
  *
  * gst_event_new_flush() creates a new flush event.
@@ -294,7 +295,7 @@ gst_event_get_structure (GstEvent * event)
  * It marks pads as being in a WRONG_STATE to process more data.
  *
  * Elements unlock and blocking functions and exit their streaming functions
- * as fast as possible. 
+ * as fast as possible.
  *
  * This event is typically generated after a seek to minimize the latency
  * after the seek.
@@ -450,7 +451,7 @@ gst_event_parse_newsegment (GstEvent * event, gdouble * rate,
  * @taglist: metadata list
  *
  * Generates a metadata tag event from the given @taglist.
- * 
+ *
  * Returns: a new #GstEvent
  */
 GstEvent *
@@ -571,7 +572,7 @@ gst_event_parse_buffersize (GstEvent * event, GstFormat * format,
  * datarate, 0.75 means increase datarate by 75%, 1.5 is 150%. Negative
  * values request a slow down, so -0.75 means a decrease by 75%.
  *
- * diff is the difference against the clock in stream time of the last 
+ * diff is the difference against the clock in stream time of the last
  * buffer that caused the element to generate the QOS event.
  *
  * timestamp is the timestamp of the last buffer that cause the element
@@ -628,7 +629,7 @@ gst_event_parse_qos (GstEvent * event, gdouble * proportion,
  * gst_event_new_seek:
  * @rate: The new playback rate
  * @format: The format of the seek values
- * @flags: The optional seek flags.
+ * @flags: The optional seek flags
  * @cur_type: The type and flags for the new current position
  * @cur: The value of the new current position
  * @stop_type: The type and flags for the new stop position
index 813eb3b..af2c4a8 100644 (file)
@@ -1035,17 +1035,17 @@ gst_value_serialize_ ## _type (const GValue * value)                    \
   return (char *) g_value_get_string (&val);                           \
 }
 
-/* deserialize the given s into to as a long long.
+/* deserialize the given s into to as a gint64.
  * check if the result is actually storeable in the given size number of
  * bytes.
  */
 static gboolean
-gst_value_deserialize_int_helper (long long *to, const char *s,
-    long long min, long long max, int size)
+gst_value_deserialize_int_helper (gint64 * to, const char *s,
+    gint64 min, gint64 max, int size)
 {
   gboolean ret = FALSE;
   char *end;
-  long long mask = -1;
+  gint64 mask = -1;
 
   errno = 0;
   *to = g_ascii_strtoull (s, &end, 0);
@@ -1075,7 +1075,7 @@ gst_value_deserialize_int_helper (long long *to, const char *s,
     }
   }
   if (ret) {
-    /* by definition, a long long fits into a long long; so ignore those */
+    /* by definition, a gint64 fits into a gint64; so ignore those */
     if (size != sizeof (mask)) {
       if (*to >= 0) {
         /* for positive numbers, we create a mask of 1's outside of the range
@@ -1103,7 +1103,7 @@ CREATE_SERIALIZATION_START(_type,_macro)                          \
 static gboolean                                                                \
 gst_value_deserialize_ ## _type (GValue * dest, const char *s)         \
 {                                                                      \
-  long long x;                                                         \
+  gint64 x;                                                            \
                                                                        \
   if (gst_value_deserialize_int_helper (&x, s, G_MIN ## _macro,                \
       G_MAX ## _macro, sizeof (g ## _type))) {                         \
@@ -1120,7 +1120,7 @@ CREATE_SERIALIZATION_START(_type,_macro)                          \
 static gboolean                                                                \
 gst_value_deserialize_ ## _type (GValue * dest, const char *s)         \
 {                                                                      \
-  guint64 x;                                                           \
+  gint64 x;                                                            \
   char *end;                                                           \
   gboolean ret = FALSE;                                                        \
                                                                        \
@@ -1174,18 +1174,19 @@ G_STMT_START {                                                          \
   gst_value_register (&gst_value);                                     \
 } G_STMT_END
 
-CREATE_SERIALIZATION (int, INT)
-    CREATE_SERIALIZATION (int64, INT64)
-    CREATE_SERIALIZATION (long, LONG)
-CREATE_USERIALIZATION (uint, UINT)
-CREATE_USERIALIZATION (uint64, UINT64)
-CREATE_USERIALIZATION (ulong, ULONG)
+CREATE_SERIALIZATION (int, INT);
+CREATE_SERIALIZATION (int64, INT64);
+CREATE_SERIALIZATION (long, LONG);
+
+CREATE_USERIALIZATION (uint, UINT);
+CREATE_USERIALIZATION (uint64, UINT64);
+CREATE_USERIALIZATION (ulong, ULONG);
 
 /**********
  * double *
  **********/
-     static int
-         gst_value_compare_double (const GValue * value1, const GValue * value2)
+static int
+gst_value_compare_double (const GValue * value1, const GValue * value2)
 {
   if (value1->data[0].v_double > value2->data[0].v_double)
     return GST_VALUE_GREATER_THAN;