mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-30 05:31:15 +00:00
review of gstbuffer documentation small doc fixes
Original commit message from CVS: * review of gstbuffer documentation * small doc fixes
This commit is contained in:
parent
8e5c223871
commit
d2af387684
6 changed files with 77 additions and 82 deletions
|
@ -65,7 +65,7 @@
|
||||||
|
|
||||||
<para>libgst.la provides all the core GStreamer services,
|
<para>libgst.la provides all the core GStreamer services,
|
||||||
including initialization, plugin management and types, as
|
including initialization, plugin management and types, as
|
||||||
well as the object hiarchy that defines elements and bins, along
|
well as the object hierarchy that defines elements and bins, along
|
||||||
with some more specialized elements.</para>
|
with some more specialized elements.</para>
|
||||||
|
|
||||||
&Gst;
|
&Gst;
|
||||||
|
|
|
@ -240,7 +240,7 @@ GST_BUFFER_COPY_FUNC
|
||||||
GST_BUFFER_FREE_FUNC
|
GST_BUFFER_FREE_FUNC
|
||||||
GstBufferCopyFunc
|
GstBufferCopyFunc
|
||||||
GstBufferFreeFunc
|
GstBufferFreeFunc
|
||||||
GstBufferFlags
|
GstBufferFlag
|
||||||
GstBuffer
|
GstBuffer
|
||||||
gst_buffer_new
|
gst_buffer_new
|
||||||
gst_buffer_new_from_pool
|
gst_buffer_new_from_pool
|
||||||
|
|
|
@ -6,9 +6,9 @@ Data-passing buffer type, supporting sub-buffers and metadata
|
||||||
|
|
||||||
<!-- ##### SECTION Long_Description ##### -->
|
<!-- ##### SECTION Long_Description ##### -->
|
||||||
<para>
|
<para>
|
||||||
Buffers are the basic unit of data transfer in GST. The GstBuffer type
|
Buffers are the basic unit of data transfer in GStreamer. The GstBuffer type
|
||||||
provides all the state necessary to define a region of memory as part of a
|
provides all the state necessary to define a region of memory as part of a
|
||||||
stream. Sub-buffer are also supported, allowing a smaller region of a
|
stream. Sub-buffers are also supported, allowing a smaller region of a
|
||||||
buffer to become its own buffer, with mechanisms in place to ensure that
|
buffer to become its own buffer, with mechanisms in place to ensure that
|
||||||
neither memory space goes away. Metadata is supported as a list of
|
neither memory space goes away. Metadata is supported as a list of
|
||||||
pointers to arbitrary metadata.
|
pointers to arbitrary metadata.
|
||||||
|
@ -27,7 +27,6 @@ buffer data.
|
||||||
GST_BUFFER_SIZE (buffer) = size;
|
GST_BUFFER_SIZE (buffer) = size;
|
||||||
GST_BUFFER_DATA (buffer) = g_alloc (size);
|
GST_BUFFER_DATA (buffer) = g_alloc (size);
|
||||||
...
|
...
|
||||||
|
|
||||||
</programlisting>
|
</programlisting>
|
||||||
</para>
|
</para>
|
||||||
<para>
|
<para>
|
||||||
|
@ -62,197 +61,194 @@ regardless of the refcount (dangerous).
|
||||||
|
|
||||||
<!-- ##### MACRO GST_IS_BUFFER ##### -->
|
<!-- ##### MACRO GST_IS_BUFFER ##### -->
|
||||||
<para>
|
<para>
|
||||||
Check if the object is a buffer.
|
Checks if the object is a buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: The object to check
|
@buf: object to check
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER ##### -->
|
<!-- ##### MACRO GST_BUFFER ##### -->
|
||||||
<para>
|
<para>
|
||||||
Cast an object to a GstBuffer
|
Casts an object to a GstBuffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: The object to cast.
|
@buf: object to cast
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_FLAGS ##### -->
|
<!-- ##### MACRO GST_BUFFER_FLAGS ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the flags from this buffer.
|
Gets the flags from this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to retrieve the flags from
|
@buf: #GstBuffer to retrieve the flags from
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_FLAG_IS_SET ##### -->
|
<!-- ##### MACRO GST_BUFFER_FLAG_IS_SET ##### -->
|
||||||
<para>
|
<para>
|
||||||
Gives the status of a given flag.
|
Gives the status of a given #GstBufferFlag.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to query
|
@buf: #GstBuffer to query
|
||||||
@flag: the flag to check
|
@flag: the #GstBufferFlag to check
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_FLAG_SET ##### -->
|
<!-- ##### MACRO GST_BUFFER_FLAG_SET ##### -->
|
||||||
<para>
|
<para>
|
||||||
Set a flag in a buffer.
|
Sets a buffer flag.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to query
|
@buf: #GstBuffer to modify
|
||||||
@flag: the flag to set
|
@flag: #GstBufferFlag to set
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_FLAG_UNSET ##### -->
|
<!-- ##### MACRO GST_BUFFER_FLAG_UNSET ##### -->
|
||||||
<para>
|
<para>
|
||||||
Clear a flag in a buffer.
|
Clears a buffer flag.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to modify
|
@buf: #GstBuffer to modify
|
||||||
@flag: the flag to clear
|
@flag: #GstBufferFlag to clear
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_DATA ##### -->
|
<!-- ##### MACRO GST_BUFFER_DATA ##### -->
|
||||||
<para>
|
<para>
|
||||||
Retrieves a pointer to the data element of this buffer
|
Retrieves a pointer to the data element of this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get data pointer of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_SIZE ##### -->
|
<!-- ##### MACRO GST_BUFFER_SIZE ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the size of the data in this buffer.
|
Gets the size of the data in this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get data size of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_OFFSET ##### -->
|
<!-- ##### MACRO GST_BUFFER_OFFSET ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the offset in the source file of this buffer.
|
Gets the offset in the source file of this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get offset of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_MAXSIZE ##### -->
|
<!-- ##### MACRO GST_BUFFER_MAXSIZE ##### -->
|
||||||
<para>
|
<para>
|
||||||
Gets the maximun size of this buffer.
|
Gets the maximum size of this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get maximum size of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_TIMESTAMP ##### -->
|
<!-- ##### MACRO GST_BUFFER_TIMESTAMP ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the timestamp for this buffer.
|
Gets the timestamp for this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get timestamp of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_BUFFERPOOL ##### -->
|
<!-- ##### MACRO GST_BUFFER_BUFFERPOOL ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the bufferpool for this buffer.
|
Gets the bufferpool for this buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get bufferpool of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_POOL_PRIVATE ##### -->
|
<!-- ##### MACRO GST_BUFFER_POOL_PRIVATE ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the bufferpool private data.
|
Gets the bufferpool private data.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer
|
@buf: #GstBuffer to get bufferpool's private data of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_LOCK ##### -->
|
<!-- ##### MACRO GST_BUFFER_LOCK ##### -->
|
||||||
<para>
|
<para>
|
||||||
This macro will obtain a lock on the object, making serialization
|
Obtains a lock on the object, making serialization possible.
|
||||||
possible.
|
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to lock
|
@buf: #GstBuffer to lock
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_TRYLOCK ##### -->
|
<!-- ##### MACRO GST_BUFFER_TRYLOCK ##### -->
|
||||||
<para>
|
<para>
|
||||||
This macro will try to obtain a lock on the object, but will return with
|
Tries to obtain a lock on the buffer.
|
||||||
FALSE if it can't get it immediately.
|
If it can't get immediately, will return FALSE.
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to try to lock
|
@buf: #GstBuffer to try to lock
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_UNLOCK ##### -->
|
<!-- ##### MACRO GST_BUFFER_UNLOCK ##### -->
|
||||||
<para>
|
<para>
|
||||||
This macro releases a lock on the object.
|
Releases a lock on the buffer.
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to unlock.
|
@buf: #GstBuffer to unlock
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_PARENT ##### -->
|
<!-- ##### MACRO GST_BUFFER_PARENT ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the parent of this buffer. The parent is set on subbuffers.
|
Gets the parent of this buffer. The parent is set on sub-buffers.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to get the parent of.
|
@buf: #GstBuffer to get parent of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_MAXAGE ##### -->
|
<!-- ##### MACRO GST_BUFFER_MAXAGE ##### -->
|
||||||
<para>
|
<para>
|
||||||
Get the maximun age of a buffer.
|
Gets the maximum age of a buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: GstBuffer to get the maxage of.
|
@buf: #GstBuffer to get maximum age of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_COPY_FUNC ##### -->
|
<!-- ##### MACRO GST_BUFFER_COPY_FUNC ##### -->
|
||||||
<para>
|
<para>
|
||||||
Call the buffer specific copy function on the given buffer.
|
Calls the buffer-specific copy function on the given buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: the buffer to copy.
|
@buf: #GstBuffer to copy
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### MACRO GST_BUFFER_FREE_FUNC ##### -->
|
<!-- ##### MACRO GST_BUFFER_FREE_FUNC ##### -->
|
||||||
<para>
|
<para>
|
||||||
Call the buffer specific free function on the given buffer.
|
Calls the buffer-specific free function on the given buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: the buffer to free.
|
@buf: #GstBuffer to free
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### USER_FUNCTION GstBufferCopyFunc ##### -->
|
<!-- ##### USER_FUNCTION GstBufferCopyFunc ##### -->
|
||||||
<para>
|
<para>
|
||||||
This function is used to copy the buffer contents.
|
This supplied function is used to copy the buffer contents.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@srcbuf: the src buffer
|
@srcbuf: #GstBuffer to copy from
|
||||||
@Returns: The copied buffer
|
@Returns: newly allocated #GstBuffer copy of srcbuf
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### USER_FUNCTION GstBufferFreeFunc ##### -->
|
<!-- ##### USER_FUNCTION GstBufferFreeFunc ##### -->
|
||||||
<para>
|
<para>
|
||||||
The function called when the buffer data has to be freed
|
This supplied function is called when the buffer data has to be freed.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@buf: the buffer to clear the buffer data of.
|
@buf: #GstBuffer to clear the buffer data of
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### ENUM GstBufferFlags ##### -->
|
<!-- ##### ENUM GstBufferFlag ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
This enumeration type describes the flags that can be used for a buffer.
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
@GST_BUFFER_READONLY: the buffer is read only
|
@GST_BUFFER_READONLY: buffer is read-only
|
||||||
@GST_BUFFER_ORIGINAL: this buffer not a copy
|
@GST_BUFFER_ORIGINAL: buffer is not a copy of another buffer
|
||||||
@GST_BUFFER_DONTFREE: do not try to free the data when this buffer is unref-ed
|
@GST_BUFFER_DONTFREE: do not try to free the data when this buffer is unreferenced
|
||||||
|
|
||||||
<!-- ##### STRUCT GstBuffer ##### -->
|
<!-- ##### STRUCT GstBuffer ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
|
|
@ -444,26 +444,6 @@ instead.
|
||||||
@Returns:
|
@Returns:
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### FUNCTION gst_element_get_compatible_static_pad ##### -->
|
|
||||||
<para>
|
|
||||||
|
|
||||||
</para>
|
|
||||||
|
|
||||||
@element:
|
|
||||||
@templ:
|
|
||||||
@Returns:
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### FUNCTION gst_element_get_compatible_request_pad ##### -->
|
|
||||||
<para>
|
|
||||||
|
|
||||||
</para>
|
|
||||||
|
|
||||||
@element:
|
|
||||||
@templ:
|
|
||||||
@Returns:
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### FUNCTION gst_element_get_compatible_pad_filtered ##### -->
|
<!-- ##### FUNCTION gst_element_get_compatible_pad_filtered ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
|
||||||
|
|
|
@ -789,6 +789,7 @@ Destroy the pad.
|
||||||
@sched_private:
|
@sched_private:
|
||||||
@peer:
|
@peer:
|
||||||
@bufpen:
|
@bufpen:
|
||||||
|
@regiontype:
|
||||||
@offset:
|
@offset:
|
||||||
@len:
|
@len:
|
||||||
@chainfunc:
|
@chainfunc:
|
||||||
|
|
|
@ -5441,6 +5441,24 @@ must be defined to activate the tracing functionality.
|
||||||
@parent:
|
@parent:
|
||||||
@Returns:
|
@Returns:
|
||||||
|
|
||||||
|
<!-- ##### FUNCTION gst_element_get_compatible_request_pad ##### -->
|
||||||
|
<para>
|
||||||
|
|
||||||
|
</para>
|
||||||
|
|
||||||
|
@element:
|
||||||
|
@templ:
|
||||||
|
@Returns:
|
||||||
|
|
||||||
|
<!-- ##### FUNCTION gst_element_get_compatible_static_pad ##### -->
|
||||||
|
<para>
|
||||||
|
|
||||||
|
</para>
|
||||||
|
|
||||||
|
@element:
|
||||||
|
@templ:
|
||||||
|
@Returns:
|
||||||
|
|
||||||
<!-- ##### FUNCTION gst_element_get_pad_template_by_name ##### -->
|
<!-- ##### FUNCTION gst_element_get_pad_template_by_name ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue