* Creates a newly allocated buffer without any data.
*
* MT safe.
- * Returns: the new #GstBuffer.
+ *
+ * Returns: (transfer full): the new #GstBuffer.
*/
GstBuffer *
gst_buffer_new (void)
* Note that when @size == 0, the buffer data pointer will be NULL.
*
* MT safe.
- * Returns: the new #GstBuffer.
+ *
+ * Returns: (transfer full): the new #GstBuffer.
*/
GstBuffer *
gst_buffer_new_and_alloc (guint size)
*
* MT safe.
*
- * Returns: a new #GstBuffer, or NULL if the memory couldn't be allocated.
+ * Returns: (transfer full): a new #GstBuffer, or NULL if the memory couldn't
+ * be allocated.
*
* Since: 0.10.13
*/
* Gets the media type of the buffer. This can be NULL if there
* is no media type attached to this buffer.
*
- * Returns: a reference to the #GstCaps. unref after usage.
+ * Returns: (transfer full): a reference to the #GstCaps. unref after usage.
* Returns NULL if there were no caps on this buffer.
*/
/* this is not made atomic because if the buffer were reffed from multiple
/**
* gst_buffer_set_caps:
* @buffer: a #GstBuffer.
- * @caps: a #GstCaps.
+ * @caps: (transfer none): a #GstCaps.
*
* Sets the media type on the buffer. The refcount of the caps will
* be increased and any previous caps on the buffer will be
/**
* gst_buffer_make_metadata_writable:
- * @buf: a #GstBuffer
+ * @buf: (transfer full): a #GstBuffer
*
* Similar to gst_buffer_make_writable, but does not ensure that the buffer
* data array is writable. Instead, this just ensures that the returned buffer
* After calling this function, @buf should not be referenced anymore. The
* result of this function has guaranteed writable metadata.
*
- * Returns: A new #GstBuffer with writable metadata.
+ * Returns: (transfer full): a new #GstBuffer with writable metadata, which
+ * may or may not be the same as @buf.
*/
GstBuffer *
gst_buffer_make_metadata_writable (GstBuffer * buf)
* to #GST_CLOCK_TIME_NONE and #GST_BUFFER_OFFSET_NONE.
*
* MT safe.
- * Returns: the new #GstBuffer.
- * Returns NULL if the arguments were invalid.
+ *
+ * Returns: (transfer full): the new #GstBuffer or NULL if the arguments were
+ * invalid.
*/
GstBuffer *
gst_buffer_create_sub (GstBuffer * buffer, guint offset, guint size)
* gst_buffer_is_span_fast() to determine if a memcpy will be needed.
*
* MT safe.
- * Returns: the new #GstBuffer that spans the two source buffers.
- * Returns NULL if the arguments are invalid.
+ *
+ * Returns: (transfer full): the new #GstBuffer that spans the two source
+ * buffers, or NULL if the arguments are invalid.
*/
GstBuffer *
gst_buffer_span (GstBuffer * buf1, guint32 offset, GstBuffer * buf2,