mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-16 11:15:31 +00:00
Revert again, this time without post-commit reindent hooks to put back the indentation :-)
Original commit message from CVS: Revert again, this time without post-commit reindent hooks to put back the indentation :-)
This commit is contained in:
parent
2143a02a13
commit
ecd88e381d
134 changed files with 4206 additions and 3970 deletions
|
@ -174,6 +174,12 @@ pipeline</ulink> and Microsoft's DirectShow for some background.
|
|||
@use_threads:
|
||||
|
||||
|
||||
<!-- ##### VARIABLE g_log_domain_gstreamer ##### -->
|
||||
<para>
|
||||
The variable that holds the GStreamer log domain
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### MACRO GST_VERSION_MAJOR ##### -->
|
||||
<para>
|
||||
The major version of GStreamer at compile time
|
||||
|
|
|
@ -72,34 +72,6 @@ The GstBin object
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstBin::element-added ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@arg1: the element that was added to the bin
|
||||
|
||||
<!-- ##### SIGNAL GstBin::element-removed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@arg1: the element that was removed from the bin
|
||||
|
||||
<!-- ##### SIGNAL GstBin::iterate ##### -->
|
||||
<para>
|
||||
This signal is emitted when a bin iterates, either automatically or
|
||||
due to a #gst_bin_iterate() call. The return value is used to
|
||||
determine if the object method handler processed any data.
|
||||
In most normal cases, a user-provided signal handler should return
|
||||
FALSE.
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@Returns: TRUE if the state of the bin was advanced.
|
||||
|
||||
<!-- ##### USER_FUNCTION GstBinPrePostIterateFunction ##### -->
|
||||
<para>
|
||||
The signature of the callback for the post and pre iterate function as set with
|
||||
|
@ -252,3 +224,31 @@ gst_bin_set_pre_iterate_function() and gst_bin_set_post_iterate_function().
|
|||
@clock:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstBin::element-added ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@arg1: the element that was added to the bin
|
||||
|
||||
<!-- ##### SIGNAL GstBin::element-removed ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@arg1: the element that was removed from the bin
|
||||
|
||||
<!-- ##### SIGNAL GstBin::iterate ##### -->
|
||||
<para>
|
||||
This signal is emitted when a bin iterates, either automatically or
|
||||
due to a #gst_bin_iterate() call. The return value is used to
|
||||
determine if the object method handler processed any data.
|
||||
In most normal cases, a user-provided signal handler should return
|
||||
FALSE.
|
||||
</para>
|
||||
|
||||
@gstbin: the object which received the signal.
|
||||
@Returns: TRUE if the state of the bin was advanced.
|
||||
|
||||
|
|
|
@ -235,21 +235,6 @@ Get the clock flags
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GstClock:event-diff ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GstClock:max-diff ##### -->
|
||||
<para>
|
||||
Maximum allowed diff for clock sync requests against the real time.
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GstClock:stats ##### -->
|
||||
<para>
|
||||
Boolean property to activate stat generation on the clock.
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gst_clock_set_speed ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -417,3 +402,18 @@ Boolean property to activate stat generation on the clock.
|
|||
@id:
|
||||
|
||||
|
||||
<!-- ##### ARG GstClock:event-diff ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GstClock:max-diff ##### -->
|
||||
<para>
|
||||
Maximum allowed diff for clock sync requests against the real time.
|
||||
</para>
|
||||
|
||||
<!-- ##### ARG GstClock:stats ##### -->
|
||||
<para>
|
||||
Boolean property to activate stat generation on the clock.
|
||||
</para>
|
||||
|
||||
|
|
|
@ -20,6 +20,16 @@ You'll get a bitmask of flags with gst_cpu_get_flags().
|
|||
|
||||
</para>
|
||||
|
||||
<!-- ##### ENUM GstCPUFlags ##### -->
|
||||
<para>
|
||||
Flags that represent cpu capabilities
|
||||
</para>
|
||||
|
||||
@GST_CPU_FLAG_MMX: The cpu is mmx enabled
|
||||
@GST_CPU_FLAG_SSE: The cpu is sse enabled
|
||||
@GST_CPU_FLAG_MMXEXT: The cpu has extended mmx instructions
|
||||
@GST_CPU_FLAG_3DNOW: The cpu is 3DNOW enabled
|
||||
|
||||
<!-- ##### FUNCTION gst_cpu_get_flags ##### -->
|
||||
<para>
|
||||
Request a set of bits specifiying the features of the CPU.
|
||||
|
|
|
@ -71,59 +71,6 @@ The element object
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstElement::eos ##### -->
|
||||
<para>
|
||||
Signal emited when the element goes to PAUSED due to an end-of-stream
|
||||
condition.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::error ##### -->
|
||||
<para>
|
||||
This signal is emitted when an element has encountered an error that caused
|
||||
it to fail performing its function.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the original #GstElement that generated the error.
|
||||
@arg2: a #GError containing the translated error message.
|
||||
@arg3: a debug string providing additional untranslated debug information, or NULL.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::found-tag ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### SIGNAL GstElement::new-pad ##### -->
|
||||
<para>
|
||||
Is triggered whenever a new pad is added to an element.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the new pad that was added
|
||||
|
||||
<!-- ##### SIGNAL GstElement::pad-removed ##### -->
|
||||
<para>
|
||||
Is triggered whenever a pad has been removed from the element.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: The pad that was removed.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::state-change ##### -->
|
||||
<para>
|
||||
Is triggered whenever the state of an element changes.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the new state of the object
|
||||
@arg2:
|
||||
|
||||
<!-- ##### MACRO gst_element_get_name ##### -->
|
||||
<para>
|
||||
Gets the name of the element.
|
||||
|
@ -1019,3 +966,56 @@ Helper macro to create query type functions
|
|||
@...: list of query types.
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstElement::eos ##### -->
|
||||
<para>
|
||||
Signal emited when the element goes to PAUSED due to an end-of-stream
|
||||
condition.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::error ##### -->
|
||||
<para>
|
||||
This signal is emitted when an element has encountered an error that caused
|
||||
it to fail performing its function.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the original #GstElement that generated the error.
|
||||
@arg2: a #GError containing the translated error message.
|
||||
@arg3: a debug string providing additional untranslated debug information, or NULL.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::found-tag ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### SIGNAL GstElement::new-pad ##### -->
|
||||
<para>
|
||||
Is triggered whenever a new pad is added to an element.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the new pad that was added
|
||||
|
||||
<!-- ##### SIGNAL GstElement::pad-removed ##### -->
|
||||
<para>
|
||||
Is triggered whenever a pad has been removed from the element.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: The pad that was removed.
|
||||
|
||||
<!-- ##### SIGNAL GstElement::state-change ##### -->
|
||||
<para>
|
||||
Is triggered whenever the state of an element changes.
|
||||
</para>
|
||||
|
||||
@gstelement: the object which received the signal.
|
||||
@arg1: the new state of the object
|
||||
@arg2:
|
||||
|
||||
|
|
|
@ -15,6 +15,18 @@ formats can be used to perform seeking or conversions/query operations.
|
|||
#GstPad, #GstElement
|
||||
</para>
|
||||
|
||||
<!-- ##### ENUM GstFormat ##### -->
|
||||
<para>
|
||||
Standard predefined formats
|
||||
</para>
|
||||
|
||||
@GST_FORMAT_UNDEFINED: undefined format
|
||||
@GST_FORMAT_DEFAULT: the default format of the pad/element
|
||||
@GST_FORMAT_BYTES: bytes
|
||||
@GST_FORMAT_TIME: time in nanoseconds
|
||||
@GST_FORMAT_BUFFERS: buffers
|
||||
@GST_FORMAT_PERCENT: percentage of stream
|
||||
|
||||
<!-- ##### MACRO GST_FORMAT_PERCENT_MAX ##### -->
|
||||
<para>
|
||||
The PERCENT format is between 0 and this value
|
||||
|
|
|
@ -209,19 +209,6 @@ The GstIndex object
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstIndex::entry-added ##### -->
|
||||
<para>
|
||||
Is emited when a new entry is added to the index.
|
||||
</para>
|
||||
|
||||
@gstindex: the object which received the signal.
|
||||
@arg1: The entry added to the index.
|
||||
|
||||
<!-- ##### ARG GstIndex:resolver ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gst_index_new ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -414,3 +401,16 @@ Is emited when a new entry is added to the index.
|
|||
@id:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstIndex::entry-added ##### -->
|
||||
<para>
|
||||
Is emited when a new entry is added to the index.
|
||||
</para>
|
||||
|
||||
@gstindex: the object which received the signal.
|
||||
@arg1: The entry added to the index.
|
||||
|
||||
<!-- ##### ARG GstIndex:resolver ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
|
|
|
@ -21,6 +21,12 @@ The GstMemChunk is used to allocate critical resources for #GstBuffer and
|
|||
#GstAtomic, #GstBuffer, #GstEvent, #GstData
|
||||
</para>
|
||||
|
||||
<!-- ##### STRUCT GstMemChunk ##### -->
|
||||
<para>
|
||||
The memchunk structure
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gst_mem_chunk_new ##### -->
|
||||
<para>
|
||||
|
||||
|
|
|
@ -40,47 +40,6 @@ The GstObject
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstObject::deep-notify ##### -->
|
||||
<para>
|
||||
The deep notify signal is used to be notified of property changes.
|
||||
it is typically attached to the toplevel bin to receive notifications
|
||||
from all the elements contained in that bin.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the object that originated the signal
|
||||
@arg2: the property that changed
|
||||
|
||||
<!-- ##### SIGNAL GstObject::object-saved ##### -->
|
||||
<para>
|
||||
Is trigered whenever a new object is saved to XML. You can connect to
|
||||
this signal to insert custom XML tags into the core XML.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the xmlNodePtr of the parent node
|
||||
|
||||
<!-- ##### SIGNAL GstObject::parent-set ##### -->
|
||||
<para>
|
||||
Is emitted when the parent of an object is set.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the new parent
|
||||
|
||||
<!-- ##### SIGNAL GstObject::parent-unset ##### -->
|
||||
<para>
|
||||
Is emitted when the parent of an object is unset.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the old parent
|
||||
|
||||
<!-- ##### ARG GstObject:name ##### -->
|
||||
<para>
|
||||
The name of the object
|
||||
</para>
|
||||
|
||||
<!-- ##### MACRO GST_FLAGS ##### -->
|
||||
<para>
|
||||
This macro returns the entire set of flags for the object.
|
||||
|
@ -331,3 +290,44 @@ Check if the object has been destroyed.
|
|||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstObject::deep-notify ##### -->
|
||||
<para>
|
||||
The deep notify signal is used to be notified of property changes.
|
||||
it is typically attached to the toplevel bin to receive notifications
|
||||
from all the elements contained in that bin.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the object that originated the signal
|
||||
@arg2: the property that changed
|
||||
|
||||
<!-- ##### SIGNAL GstObject::object-saved ##### -->
|
||||
<para>
|
||||
Is trigered whenever a new object is saved to XML. You can connect to
|
||||
this signal to insert custom XML tags into the core XML.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the xmlNodePtr of the parent node
|
||||
|
||||
<!-- ##### SIGNAL GstObject::parent-set ##### -->
|
||||
<para>
|
||||
Is emitted when the parent of an object is set.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the new parent
|
||||
|
||||
<!-- ##### SIGNAL GstObject::parent-unset ##### -->
|
||||
<para>
|
||||
Is emitted when the parent of an object is unset.
|
||||
</para>
|
||||
|
||||
@gstobject: the object which received the signal.
|
||||
@arg1: the old parent
|
||||
|
||||
<!-- ##### ARG GstObject:name ##### -->
|
||||
<para>
|
||||
The name of the object
|
||||
</para>
|
||||
|
||||
|
|
|
@ -1193,11 +1193,6 @@ The Ghostpad object
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### ARG GstGhostPad:real-pad ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gst_ghost_pad_new ##### -->
|
||||
<para>
|
||||
|
||||
|
|
|
@ -86,15 +86,6 @@ The padtemplate object.
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstPadTemplate::pad-created ##### -->
|
||||
<para>
|
||||
This signal is fired when an element creates a pad from this
|
||||
template.
|
||||
</para>
|
||||
|
||||
@gstpadtemplate: the object which received the signal.
|
||||
@arg1: The pad that was created.
|
||||
|
||||
<!-- ##### ENUM GstPadTemplateFlags ##### -->
|
||||
<para>
|
||||
Flags for the padtemplate
|
||||
|
@ -176,3 +167,12 @@ Check if the properties of the padtemplate are fixed
|
|||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstPadTemplate::pad-created ##### -->
|
||||
<para>
|
||||
This signal is fired when an element creates a pad from this
|
||||
template.
|
||||
</para>
|
||||
|
||||
@gstpadtemplate: the object which received the signal.
|
||||
@arg1: The pad that was created.
|
||||
|
||||
|
|
|
@ -41,6 +41,14 @@ The error quark
|
|||
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gst_plugin_error_quark ##### -->
|
||||
<para>
|
||||
Get the error quark
|
||||
</para>
|
||||
|
||||
@Returns: The error quark used in GError messages
|
||||
|
||||
|
||||
<!-- ##### ENUM GstPluginError ##### -->
|
||||
<para>
|
||||
The plugin loading errors
|
||||
|
|
|
@ -15,6 +15,20 @@ Query types can be used to perform queries on pads and elements.
|
|||
#GstPad, #GstElement
|
||||
</para>
|
||||
|
||||
<!-- ##### ENUM GstQueryType ##### -->
|
||||
<para>
|
||||
Standard predefined Query types
|
||||
</para>
|
||||
|
||||
@GST_QUERY_NONE: invalid query type
|
||||
@GST_QUERY_TOTAL: total length of stream
|
||||
@GST_QUERY_POSITION: current position in stream
|
||||
@GST_QUERY_LATENCY: latency of stream
|
||||
@GST_QUERY_JITTER: current jitter of stream
|
||||
@GST_QUERY_START: start of configured segment
|
||||
@GST_QUERY_SEGMENT_END: end of configured segment
|
||||
@GST_QUERY_RATE: current rate of the stream
|
||||
|
||||
<!-- ##### MACRO GST_QUERY_TYPE_RATE_DEN ##### -->
|
||||
<para>
|
||||
Rates are relative to this value
|
||||
|
@ -75,10 +89,10 @@ Convenience function to define a function that returns an array of query types.
|
|||
|
||||
</para>
|
||||
|
||||
@Param1:
|
||||
@type:
|
||||
@Returns:
|
||||
<!-- # Unused Parameters # -->
|
||||
@type:
|
||||
@Param1:
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gst_query_type_get_definitions ##### -->
|
||||
|
|
|
@ -4556,16 +4556,6 @@ can perform necessary cleanup.
|
|||
@pool: The pool that is being destroyed
|
||||
@user_data: user data as set on th bufferpool
|
||||
|
||||
<!-- ##### ENUM GstCPUFlags ##### -->
|
||||
<para>
|
||||
Flags that represent cpu capabilities
|
||||
</para>
|
||||
|
||||
@GST_CPU_FLAG_MMX: The cpu is mmx enabled
|
||||
@GST_CPU_FLAG_SSE: The cpu is sse enabled
|
||||
@GST_CPU_FLAG_MMXEXT: The cpu has extended mmx instructions
|
||||
@GST_CPU_FLAG_3DNOW: The cpu is 3DNOW enabled
|
||||
|
||||
<!-- ##### STRUCT GstCacheAssociation ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -5168,17 +5158,11 @@ Indicates the mmapped area should be touched to bring it into memory.
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### ENUM GstFormat ##### -->
|
||||
<!-- ##### ARG GstGhostPad:real-pad ##### -->
|
||||
<para>
|
||||
Standard predefined formats
|
||||
|
||||
</para>
|
||||
|
||||
@GST_FORMAT_UNDEFINED: undefined format
|
||||
@GST_FORMAT_DEFAULT: the default format of the pad/element
|
||||
@GST_FORMAT_BYTES: bytes
|
||||
@GST_FORMAT_TIME: time in nanoseconds
|
||||
@GST_FORMAT_BUFFERS: buffers
|
||||
@GST_FORMAT_PERCENT: percentage of stream
|
||||
|
||||
<!-- ##### STRUCT GstHttpSrc ##### -->
|
||||
<para>
|
||||
|
@ -5297,12 +5281,6 @@ Specify the location of the file. The location must be a fully qualified URL.
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### STRUCT GstMemChunk ##### -->
|
||||
<para>
|
||||
The memchunk structure
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### STRUCT GstMemChunkElement ##### -->
|
||||
<para>
|
||||
An entry in the memchunk area
|
||||
|
@ -5533,20 +5511,6 @@ Sets the command to be executed.
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### ENUM GstQueryType ##### -->
|
||||
<para>
|
||||
Standard predefined Query types
|
||||
</para>
|
||||
|
||||
@GST_QUERY_NONE: invalid query type
|
||||
@GST_QUERY_TOTAL: total length of stream
|
||||
@GST_QUERY_POSITION: current position in stream
|
||||
@GST_QUERY_LATENCY: latency of stream
|
||||
@GST_QUERY_JITTER: current jitter of stream
|
||||
@GST_QUERY_START: start of configured segment
|
||||
@GST_QUERY_SEGMENT_END: end of configured segment
|
||||
@GST_QUERY_RATE: current rate of the stream
|
||||
|
||||
<!-- ##### STRUCT GstQueue ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -5613,17 +5577,6 @@ the region types for #gst_pad_pullregion.
|
|||
@global_reg:
|
||||
@local_reg:
|
||||
|
||||
<!-- ##### ENUM GstRegistryReturn ##### -->
|
||||
<para>
|
||||
The return value of registry operations
|
||||
</para>
|
||||
|
||||
@GST_REGISTRY_OK: The registry reported no error.
|
||||
@GST_REGISTRY_LOAD_ERROR: There was a load error
|
||||
@GST_REGISTRY_SAVE_ERROR: There was an error saving the registry
|
||||
@GST_REGISTRY_PLUGIN_LOAD_ERROR: There was an error loading a plugin
|
||||
@GST_REGISTRY_PLUGIN_SIGNATURE_ERROR: There was an error saving a plugin
|
||||
|
||||
<!-- ##### STRUCT GstRegistryWrite ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -5851,20 +5804,6 @@ Flags for the GstSrc element
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### ENUM GstTagMergeMode ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@GST_TAG_MERGE_UNDEFINED:
|
||||
@GST_TAG_MERGE_REPLACE_ALL:
|
||||
@GST_TAG_MERGE_REPLACE:
|
||||
@GST_TAG_MERGE_APPEND:
|
||||
@GST_TAG_MERGE_PREPEND:
|
||||
@GST_TAG_MERGE_KEEP:
|
||||
@GST_TAG_MERGE_KEEP_ALL:
|
||||
@GST_TAG_MERGE_COUNT:
|
||||
|
||||
<!-- ##### STRUCT GstTee ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -5988,15 +5927,6 @@ Query the element for the current mime type
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstXML::object-loaded ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstxml: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### USER_FUNCTION GstXMLRegistryAddPathList ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -6752,12 +6682,6 @@ must be defined to activate the tracing functionality.
|
|||
@llink:
|
||||
@Returns:
|
||||
|
||||
<!-- ##### VARIABLE g_log_domain_gstreamer ##### -->
|
||||
<para>
|
||||
The variable that holds the GStreamer log domain
|
||||
</para>
|
||||
|
||||
|
||||
<!-- ##### MACRO g_object_class_find_property ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -9643,13 +9567,6 @@ Destroys the pipeline.
|
|||
|
||||
@Returns:
|
||||
|
||||
<!-- ##### FUNCTION gst_plugin_error_quark ##### -->
|
||||
<para>
|
||||
Get the error quark
|
||||
</para>
|
||||
|
||||
@Returns: The error quark used in GError messages
|
||||
|
||||
<!-- ##### FUNCTION gst_plugin_feature_get_type ##### -->
|
||||
<para>
|
||||
|
||||
|
|
|
@ -14,6 +14,17 @@ The registry holds the available plugins in the system.
|
|||
#GstPlugin, #GstPluginFeature
|
||||
</para>
|
||||
|
||||
<!-- ##### ENUM GstRegistryReturn ##### -->
|
||||
<para>
|
||||
The return value of registry operations
|
||||
</para>
|
||||
|
||||
@GST_REGISTRY_OK: The registry reported no error.
|
||||
@GST_REGISTRY_LOAD_ERROR: There was a load error
|
||||
@GST_REGISTRY_SAVE_ERROR: There was an error saving the registry
|
||||
@GST_REGISTRY_PLUGIN_LOAD_ERROR: There was an error loading a plugin
|
||||
@GST_REGISTRY_PLUGIN_SIGNATURE_ERROR: There was an error saving a plugin
|
||||
|
||||
<!-- ##### ENUM GstRegistryFlags ##### -->
|
||||
<para>
|
||||
Flags for the registry
|
||||
|
|
|
@ -14,6 +14,20 @@ GstTag
|
|||
|
||||
</para>
|
||||
|
||||
<!-- ##### ENUM GstTagMergeMode ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@GST_TAG_MERGE_UNDEFINED:
|
||||
@GST_TAG_MERGE_REPLACE_ALL:
|
||||
@GST_TAG_MERGE_REPLACE:
|
||||
@GST_TAG_MERGE_APPEND:
|
||||
@GST_TAG_MERGE_PREPEND:
|
||||
@GST_TAG_MERGE_KEEP:
|
||||
@GST_TAG_MERGE_KEEP_ALL:
|
||||
@GST_TAG_MERGE_COUNT:
|
||||
|
||||
<!-- ##### ENUM GstTagFlag ##### -->
|
||||
<para>
|
||||
|
||||
|
|
|
@ -34,6 +34,15 @@ The GstThread object
|
|||
</para>
|
||||
|
||||
|
||||
<!-- ##### FUNCTION gst_thread_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@name:
|
||||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstThread::shutdown ##### -->
|
||||
<para>
|
||||
|
||||
|
@ -46,12 +55,3 @@ The GstThread object
|
|||
The thread priority
|
||||
</para>
|
||||
|
||||
<!-- ##### FUNCTION gst_thread_new ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@name:
|
||||
@Returns:
|
||||
|
||||
|
||||
|
|
|
@ -105,3 +105,21 @@ All GstElements can be serialized to an XML presentation and subsequently loaded
|
|||
@Returns:
|
||||
|
||||
|
||||
<!-- ##### SIGNAL GstXML::object-loaded ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@gstxml: the object which received the signal.
|
||||
@arg1:
|
||||
@arg2:
|
||||
|
||||
<!-- ##### SIGNAL GstXML::object-loaded ##### -->
|
||||
<para>
|
||||
|
||||
</para>
|
||||
|
||||
@:
|
||||
@:
|
||||
@:
|
||||
|
||||
|
|
|
@ -11,5 +11,4 @@ typedef struct
|
|||
|
||||
char *location;
|
||||
int channel_id;
|
||||
}
|
||||
output_channel_t;
|
||||
} output_channel_t;
|
||||
|
|
|
@ -9,5 +9,4 @@ typedef struct
|
|||
|
||||
char *location;
|
||||
int channel_id;
|
||||
}
|
||||
input_channel_t;
|
||||
} input_channel_t;
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* This is the definition of the element's object structure. */
|
||||
typedef struct _GstExample GstExample;
|
||||
|
||||
|
@ -32,8 +33,7 @@ typedef struct _GstExample GstExample;
|
|||
* the beginning of the object. This allows the element to be cast to
|
||||
* an Element or even an Object.
|
||||
*/
|
||||
struct _GstExample
|
||||
{
|
||||
struct _GstExample {
|
||||
GstElement element;
|
||||
|
||||
/* We need to keep track of our pads, so we do so here. */
|
||||
|
@ -49,8 +49,7 @@ struct _GstExample
|
|||
* structure. */
|
||||
typedef struct _GstExampleClass GstExampleClass;
|
||||
|
||||
struct _GstExampleClass
|
||||
{
|
||||
struct _GstExampleClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -84,4 +83,5 @@ struct _GstExampleClass
|
|||
GType gst_example_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_EXAMPLE_H__ */
|
||||
|
|
|
@ -31,8 +31,7 @@
|
|||
/* struct for a node, in the search tree */
|
||||
typedef struct _GstAutoplugNode GstAutoplugNode;
|
||||
|
||||
struct _GstAutoplugNode
|
||||
{
|
||||
struct _GstAutoplugNode {
|
||||
GstAutoplugNode *prev; /* previous node */
|
||||
GstElementFactory *fac; /* factory of element to connect to */
|
||||
GstPadTemplate *templ; /* template which can connect */
|
||||
|
@ -41,16 +40,11 @@ struct _GstAutoplugNode
|
|||
};
|
||||
|
||||
/* helper functions */
|
||||
gboolean gst_autoplug_caps_intersect (const GstCaps * src,
|
||||
const GstCaps * sink);
|
||||
GstPadTemplate *gst_autoplug_can_connect_src (GstElementFactory * fac,
|
||||
const GstCaps * src);
|
||||
GstPadTemplate *gst_autoplug_can_connect_sink (GstElementFactory * fac,
|
||||
const GstCaps * sink);
|
||||
GstPadTemplate *gst_autoplug_can_match (GstElementFactory * src,
|
||||
GstElementFactory * dest);
|
||||
gboolean gst_autoplug_factory_has_direction (GstElementFactory * fac,
|
||||
GstPadDirection dir);
|
||||
gboolean gst_autoplug_caps_intersect (const GstCaps *src, const GstCaps *sink);
|
||||
GstPadTemplate * gst_autoplug_can_connect_src (GstElementFactory *fac, const GstCaps *src);
|
||||
GstPadTemplate * gst_autoplug_can_connect_sink (GstElementFactory *fac, const GstCaps *sink);
|
||||
GstPadTemplate * gst_autoplug_can_match (GstElementFactory *src, GstElementFactory *dest);
|
||||
gboolean gst_autoplug_factory_has_direction (GstElementFactory *fac, GstPadDirection dir);
|
||||
#define gst_autoplug_factory_has_sink(fac) gst_autoplug_factory_has_direction((fac), GST_PAD_SINK)
|
||||
#define gst_autoplug_factory_has_src(fac) gst_autoplug_factory_has_direction((fac), GST_PAD_SRC)
|
||||
|
||||
|
@ -62,11 +56,9 @@ GList *gst_autoplug_factories_sinks (GList * factories);
|
|||
GList * gst_autoplug_factories_srcs (GList *factories);
|
||||
GList * gst_autoplug_factories_filters (GList *factories);
|
||||
GList * gst_autoplug_factories_filters_with_sink_caps(GList *factories);
|
||||
GList *gst_autoplug_factories_at_most_templates (GList * factories,
|
||||
GstPadDirection dir, guint maxtemplates);
|
||||
GList * gst_autoplug_factories_at_most_templates(GList *factories, GstPadDirection dir, guint maxtemplates);
|
||||
|
||||
/* shortest path algorithm */
|
||||
GList *gst_autoplug_sp (const GstCaps * src_caps, const GstCaps * sink_caps,
|
||||
GList * factories);
|
||||
GList * gst_autoplug_sp (const GstCaps *src_caps, const GstCaps *sink_caps, GList *factories);
|
||||
|
||||
#endif /* __GST_SEARCHFUNCS_H__ */
|
||||
|
|
|
@ -26,8 +26,9 @@
|
|||
#include <gst/gst.h>
|
||||
#include "gstspideridentity.h"
|
||||
|
||||
G_BEGIN_DECLS extern GstElementDetails gst_spider_details;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
extern GstElementDetails gst_spider_details;
|
||||
GST_DEBUG_CATEGORY_EXTERN(gst_spider_debug);
|
||||
|
||||
/*
|
||||
|
@ -45,16 +46,14 @@ GST_DEBUG_CATEGORY_EXTERN (gst_spider_debug);
|
|||
* are refcounted once for every path.
|
||||
* A GstSpider keeps a list of all GstSpiderConnections in it.
|
||||
*/
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
GstSpiderIdentity *src;
|
||||
/* dunno if the path should stay here or if its too much load.
|
||||
* it's at least easier then always searching it */
|
||||
GList *path;
|
||||
GstElement *current;
|
||||
gulong signal_id;
|
||||
}
|
||||
GstSpiderConnection;
|
||||
} GstSpiderConnection;
|
||||
|
||||
#define GST_TYPE_SPIDER \
|
||||
(gst_spider_get_type())
|
||||
|
@ -70,8 +69,7 @@ GstSpiderConnection;
|
|||
typedef struct _GstSpider GstSpider;
|
||||
typedef struct _GstSpiderClass GstSpiderClass;
|
||||
|
||||
struct _GstSpider
|
||||
{
|
||||
struct _GstSpider {
|
||||
GstBin parent;
|
||||
|
||||
GstSpiderIdentity *sink_ident;
|
||||
|
@ -80,8 +78,7 @@ struct _GstSpider
|
|||
GList * links; /* GStSpiderConnection list of all links */
|
||||
};
|
||||
|
||||
struct _GstSpiderClass
|
||||
{
|
||||
struct _GstSpiderClass {
|
||||
GstBinClass parent_class;
|
||||
};
|
||||
|
||||
|
@ -93,4 +90,5 @@ void gst_spider_identity_plug (GstSpiderIdentity * ident);
|
|||
void gst_spider_identity_unplug (GstSpiderIdentity *ident);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SPIDER_H__ */
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_SPIDER_IDENTITY \
|
||||
(gst_spider_identity_get_type())
|
||||
#define GST_SPIDER_IDENTITY(obj) \
|
||||
|
@ -37,11 +38,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SPIDER_IDENTITY))
|
||||
#define GST_IS_SPIDER_IDENTITY_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SPIDER_IDENTITY))
|
||||
|
||||
typedef struct _GstSpiderIdentity GstSpiderIdentity;
|
||||
typedef struct _GstSpiderIdentityClass GstSpiderIdentityClass;
|
||||
|
||||
struct _GstSpiderIdentity
|
||||
{
|
||||
struct _GstSpiderIdentity {
|
||||
GstElement element;
|
||||
|
||||
/* sink and source */
|
||||
|
@ -55,8 +56,7 @@ struct _GstSpiderIdentity
|
|||
GstCaps *caps;
|
||||
};
|
||||
|
||||
struct _GstSpiderIdentityClass
|
||||
{
|
||||
struct _GstSpiderIdentityClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
};
|
||||
|
@ -65,8 +65,8 @@ GType gst_spider_identity_get_type (void);
|
|||
|
||||
GstSpiderIdentity* gst_spider_identity_new_sink (gchar *name);
|
||||
GstSpiderIdentity* gst_spider_identity_new_src (gchar *name);
|
||||
GstPad *gst_spider_identity_request_new_pad (GstElement * element,
|
||||
GstPadTemplate * templ, const gchar * name);
|
||||
GstPad* gst_spider_identity_request_new_pad (GstElement *element, GstPadTemplate *templ, const gchar *name);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SPIDER_IDENTITY_H__ */
|
||||
|
|
|
@ -34,8 +34,7 @@ typedef int (*cothread_func) (int argc, char **argv);
|
|||
#define COTHREAD_STARTED 0x01
|
||||
#define COTHREAD_DESTROYED 0x02
|
||||
|
||||
struct _cothread_state
|
||||
{
|
||||
struct _cothread_state {
|
||||
cothread_context *ctx;
|
||||
int cothreadnum;
|
||||
gpointer priv;
|
||||
|
@ -67,7 +66,8 @@ void cothread_setfunc (cothread_state * cothread, cothread_func func,
|
|||
void cothread_stop (cothread_state *cothread);
|
||||
|
||||
void cothread_switch (cothread_state *cothread);
|
||||
void cothread_set_private (cothread_state * cothread, gpointer data);
|
||||
void cothread_set_private (cothread_state *cothread,
|
||||
gpointer data);
|
||||
gpointer cothread_get_private (cothread_state *cothread);
|
||||
|
||||
void cothread_lock (cothread_state *cothread);
|
||||
|
|
|
@ -26,13 +26,14 @@
|
|||
|
||||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
typedef enum {
|
||||
AGGREGATOR_LOOP = 1,
|
||||
AGGREGATOR_LOOP_SELECT,
|
||||
AGGREGATOR_CHAIN
|
||||
}
|
||||
GstAggregatorSchedType;
|
||||
} GstAggregatorSchedType;
|
||||
|
||||
#define GST_TYPE_AGGREGATOR \
|
||||
(gst_aggregator_get_type())
|
||||
|
@ -48,8 +49,7 @@ GstAggregatorSchedType;
|
|||
typedef struct _GstAggregator GstAggregator;
|
||||
typedef struct _GstAggregatorClass GstAggregatorClass;
|
||||
|
||||
struct _GstAggregator
|
||||
{
|
||||
struct _GstAggregator {
|
||||
GstElement element;
|
||||
|
||||
GstPad *srcpad;
|
||||
|
@ -63,8 +63,7 @@ struct _GstAggregator
|
|||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _GstAggregatorClass
|
||||
{
|
||||
struct _GstAggregatorClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
@ -73,4 +72,5 @@ GType gst_aggregator_get_type (void);
|
|||
gboolean gst_aggregator_factory_init (GstElementFactory *factory);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_AGGREGATOR_H__ */
|
||||
|
|
|
@ -28,29 +28,30 @@
|
|||
#include <gst/gstmarshal.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_BUFFER_STORE (gst_buffer_store_get_type ())
|
||||
#define GST_BUFFER_STORE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_BUFFER_STORE, GstBufferStore))
|
||||
#define GST_IS_BUFFER_STORE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_BUFFER_STORE))
|
||||
#define GST_BUFFER_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_BUFFER_STORE, GstBufferStoreClass))
|
||||
#define GST_IS_BUFFER_STORE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_BUFFER_STORE))
|
||||
#define GST_BUFFER_STORE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_BUFFER_STORE, GstBufferStoreClass))
|
||||
|
||||
typedef struct _GstBufferStore GstBufferStore;
|
||||
typedef struct _GstBufferStoreClass GstBufferStoreClass;
|
||||
|
||||
struct _GstBufferStore
|
||||
{
|
||||
struct _GstBufferStore {
|
||||
GObject object;
|
||||
|
||||
GList * buffers;
|
||||
};
|
||||
|
||||
struct _GstBufferStoreClass
|
||||
{
|
||||
struct _GstBufferStoreClass {
|
||||
GObjectClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (* cleared) (GstBufferStore * store);
|
||||
gboolean (*buffer_added) (GstBufferStore * store, GstBuffer * buffer);
|
||||
gboolean (* buffer_added) (GstBufferStore * store,
|
||||
GstBuffer * buffer);
|
||||
};
|
||||
|
||||
GType gst_buffer_store_get_type (void);
|
||||
|
@ -62,8 +63,11 @@ gboolean gst_buffer_store_add_buffer (GstBufferStore * store,
|
|||
GstBuffer * buffer);
|
||||
|
||||
GstBuffer * gst_buffer_store_get_buffer (GstBufferStore * store,
|
||||
guint64 offset, guint size);
|
||||
guint gst_buffer_store_get_size (GstBufferStore * store, guint64 offset);
|
||||
guint64 offset,
|
||||
guint size);
|
||||
guint gst_buffer_store_get_size (GstBufferStore * store,
|
||||
guint64 offset);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_BUFFER_STORE_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_FAKESINK \
|
||||
(gst_fakesink_get_type())
|
||||
#define GST_FAKESINK(obj) \
|
||||
|
@ -37,8 +39,8 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_FAKESINK))
|
||||
#define GST_IS_FAKESINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FAKESINK))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
FAKESINK_STATE_ERROR_NONE = 0,
|
||||
FAKESINK_STATE_ERROR_NULL_READY,
|
||||
FAKESINK_STATE_ERROR_READY_PAUSED,
|
||||
|
@ -46,14 +48,12 @@ G_BEGIN_DECLS
|
|||
FAKESINK_STATE_ERROR_PLAYING_PAUSED,
|
||||
FAKESINK_STATE_ERROR_PAUSED_READY,
|
||||
FAKESINK_STATE_ERROR_READY_NULL,
|
||||
}
|
||||
GstFakeSinkStateError;
|
||||
} GstFakeSinkStateError;
|
||||
|
||||
typedef struct _GstFakeSink GstFakeSink;
|
||||
typedef struct _GstFakeSinkClass GstFakeSinkClass;
|
||||
|
||||
struct _GstFakeSink
|
||||
{
|
||||
struct _GstFakeSink {
|
||||
GstElement element;
|
||||
|
||||
gboolean silent;
|
||||
|
@ -66,8 +66,7 @@ struct _GstFakeSink
|
|||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _GstFakeSinkClass
|
||||
{
|
||||
struct _GstFakeSinkClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -79,4 +78,5 @@ GType gst_fakesink_get_type (void);
|
|||
gboolean gst_fakesink_factory_init (GstElementFactory *factory);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FAKESINK_H__ */
|
||||
|
|
|
@ -26,8 +26,10 @@
|
|||
|
||||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
typedef enum {
|
||||
FAKESRC_FIRST_LAST_LOOP = 1,
|
||||
FAKESRC_LAST_FIRST_LOOP,
|
||||
FAKESRC_PING_PONG,
|
||||
|
@ -36,33 +38,26 @@ G_BEGIN_DECLS typedef enum
|
|||
FAKESRC_PATTERN_LOOP,
|
||||
FAKESRC_PING_PONG_PATTERN,
|
||||
FAKESRC_GET_ALWAYS_SUCEEDS
|
||||
}
|
||||
GstFakeSrcOutputType;
|
||||
} GstFakeSrcOutputType;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
FAKESRC_DATA_ALLOCATE = 1,
|
||||
FAKESRC_DATA_SUBBUFFER,
|
||||
}
|
||||
GstFakeSrcDataType;
|
||||
} GstFakeSrcDataType;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
FAKESRC_SIZETYPE_NULL = 1,
|
||||
FAKESRC_SIZETYPE_FIXED,
|
||||
FAKESRC_SIZETYPE_RANDOM
|
||||
}
|
||||
GstFakeSrcSizeType;
|
||||
} GstFakeSrcSizeType;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
FAKESRC_FILLTYPE_NOTHING = 1,
|
||||
FAKESRC_FILLTYPE_NULL,
|
||||
FAKESRC_FILLTYPE_RANDOM,
|
||||
FAKESRC_FILLTYPE_PATTERN,
|
||||
FAKESRC_FILLTYPE_PATTERN_CONT
|
||||
}
|
||||
GstFakeSrcFillType;
|
||||
} GstFakeSrcFillType;
|
||||
|
||||
#define GST_TYPE_FAKESRC \
|
||||
(gst_fakesrc_get_type())
|
||||
|
@ -78,8 +73,7 @@ GstFakeSrcFillType;
|
|||
typedef struct _GstFakeSrc GstFakeSrc;
|
||||
typedef struct _GstFakeSrcClass GstFakeSrcClass;
|
||||
|
||||
struct _GstFakeSrc
|
||||
{
|
||||
struct _GstFakeSrc {
|
||||
GstElement element;
|
||||
|
||||
gboolean loop_based;
|
||||
|
@ -112,8 +106,7 @@ struct _GstFakeSrc
|
|||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _GstFakeSrcClass
|
||||
{
|
||||
struct _GstFakeSrcClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -125,4 +118,5 @@ GType gst_fakesrc_get_type (void);
|
|||
gboolean gst_fakesrc_factory_init (GstElementFactory *factory);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FAKESRC_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_FDSINK \
|
||||
(gst_fdsink_get_type())
|
||||
#define GST_FDSINK(obj) \
|
||||
|
@ -37,11 +39,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_FDSINK))
|
||||
#define GST_IS_FDSINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FDSINK))
|
||||
|
||||
typedef struct _GstFdSink GstFdSink;
|
||||
typedef struct _GstFdSinkClass GstFdSinkClass;
|
||||
|
||||
struct _GstFdSink
|
||||
{
|
||||
struct _GstFdSink {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -49,12 +51,12 @@ struct _GstFdSink
|
|||
int fd;
|
||||
};
|
||||
|
||||
struct _GstFdSinkClass
|
||||
{
|
||||
struct _GstFdSinkClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_fdsink_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FDSINK_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_FDSRC \
|
||||
(gst_fdsrc_get_type())
|
||||
#define GST_FDSRC(obj) \
|
||||
|
@ -37,11 +39,12 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_FDSRC))
|
||||
#define GST_IS_FDSRC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FDSRC))
|
||||
|
||||
|
||||
typedef struct _GstFdSrc GstFdSrc;
|
||||
typedef struct _GstFdSrcClass GstFdSrcClass;
|
||||
|
||||
struct _GstFdSrc
|
||||
{
|
||||
struct _GstFdSrc {
|
||||
GstElement element;
|
||||
/* pads */
|
||||
GstPad *srcpad;
|
||||
|
@ -56,8 +59,7 @@ struct _GstFdSrc
|
|||
gulong seq; /* buffer sequence number */
|
||||
};
|
||||
|
||||
struct _GstFdSrcClass
|
||||
{
|
||||
struct _GstFdSrcClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -67,4 +69,5 @@ struct _GstFdSrcClass
|
|||
GType gst_fdsrc_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FDSRC_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_FILESINK \
|
||||
(gst_filesink_get_type())
|
||||
#define GST_FILESINK(obj) \
|
||||
|
@ -37,19 +39,17 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_FILESINK))
|
||||
#define GST_IS_FILESINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FILESINK))
|
||||
|
||||
typedef struct _GstFileSink GstFileSink;
|
||||
typedef struct _GstFileSinkClass GstFileSinkClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_FILESINK_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_FILESINK_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2
|
||||
}
|
||||
GstFileSinkFlags;
|
||||
} GstFileSinkFlags;
|
||||
|
||||
struct _GstFileSink
|
||||
{
|
||||
struct _GstFileSink {
|
||||
GstElement element;
|
||||
|
||||
gchar *filename;
|
||||
|
@ -59,8 +59,7 @@ struct _GstFileSink
|
|||
guint64 data_written;
|
||||
};
|
||||
|
||||
struct _GstFileSinkClass
|
||||
{
|
||||
struct _GstFileSinkClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -70,4 +69,5 @@ struct _GstFileSinkClass
|
|||
GType gst_filesink_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FILESINK_H__ */
|
||||
|
|
|
@ -29,6 +29,8 @@
|
|||
#include <sys/types.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_FILESRC \
|
||||
(gst_filesrc_get_type())
|
||||
#define GST_FILESRC(obj) \
|
||||
|
@ -39,19 +41,17 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_FILESRC))
|
||||
#define GST_IS_FILESRC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_FILESRC))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
GST_FILESRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_FILESRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2
|
||||
}
|
||||
GstFileSrcFlags;
|
||||
} GstFileSrcFlags;
|
||||
|
||||
typedef struct _GstFileSrc GstFileSrc;
|
||||
typedef struct _GstFileSrcClass GstFileSrcClass;
|
||||
|
||||
struct _GstFileSrc
|
||||
{
|
||||
struct _GstFileSrc {
|
||||
GstElement element;
|
||||
GstPad *srcpad;
|
||||
|
||||
|
@ -74,12 +74,12 @@ struct _GstFileSrc
|
|||
gboolean need_flush;
|
||||
};
|
||||
|
||||
struct _GstFileSrcClass
|
||||
{
|
||||
struct _GstFileSrcClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_filesrc_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FILESRC_H__ */
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_IDENTITY \
|
||||
(gst_identity_get_type())
|
||||
#define GST_IDENTITY(obj) \
|
||||
|
@ -38,11 +40,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_IDENTITY))
|
||||
#define GST_IS_IDENTITY_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_IDENTITY))
|
||||
|
||||
typedef struct _GstIdentity GstIdentity;
|
||||
typedef struct _GstIdentityClass GstIdentityClass;
|
||||
|
||||
struct _GstIdentity
|
||||
{
|
||||
struct _GstIdentity {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -59,8 +61,7 @@ struct _GstIdentity
|
|||
GstCaps *srccaps;
|
||||
};
|
||||
|
||||
struct _GstIdentityClass
|
||||
{
|
||||
struct _GstIdentityClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -70,4 +71,5 @@ struct _GstIdentityClass
|
|||
GType gst_identity_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_IDENTITY_H__ */
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_MD5SINK \
|
||||
(gst_md5sink_get_type())
|
||||
#define GST_MD5SINK(obj) \
|
||||
|
@ -38,11 +40,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_MD5SINK))
|
||||
#define GST_IS_MD5SINK_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MD5SINK))
|
||||
|
||||
typedef struct _GstMD5Sink GstMD5Sink;
|
||||
typedef struct _GstMD5SinkClass GstMD5SinkClass;
|
||||
|
||||
struct _GstMD5Sink
|
||||
{
|
||||
struct _GstMD5Sink {
|
||||
GstElement element;
|
||||
|
||||
/* md5 information */
|
||||
|
@ -60,8 +62,7 @@ struct _GstMD5Sink
|
|||
|
||||
};
|
||||
|
||||
struct _GstMD5SinkClass
|
||||
{
|
||||
struct _GstMD5SinkClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
};
|
||||
|
@ -71,4 +72,5 @@ GType gst_md5sink_get_type (void);
|
|||
gboolean gst_md5sink_factory_init (GstElementFactory *factory);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MD5SINK_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_MULTIFILESRC \
|
||||
(gst_multifilesrc_get_type())
|
||||
#define GST_MULTIFILESRC(obj) \
|
||||
|
@ -37,19 +39,17 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_MULTIFILESRC))
|
||||
#define GST_IS_MULTIFILESRC_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_MULTIFILESRC))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
GST_MULTIFILESRC_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_MULTIFILESRC_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2
|
||||
}
|
||||
GstMultiFileSrcFlags;
|
||||
} GstMultiFileSrcFlags;
|
||||
|
||||
typedef struct _GstMultiFileSrc GstMultiFileSrc;
|
||||
typedef struct _GstMultiFileSrcClass GstMultiFileSrcClass;
|
||||
|
||||
struct _GstMultiFileSrc
|
||||
{
|
||||
struct _GstMultiFileSrc {
|
||||
GstElement element;
|
||||
/* pads */
|
||||
GstPad *srcpad;
|
||||
|
@ -66,8 +66,7 @@ struct _GstMultiFileSrc
|
|||
gboolean new_seek;
|
||||
};
|
||||
|
||||
struct _GstMultiFileSrcClass
|
||||
{
|
||||
struct _GstMultiFileSrcClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
void (*new_file) (GstMultiFileSrc *multifilesrc, gchar *newfilename);
|
||||
|
@ -76,4 +75,5 @@ struct _GstMultiFileSrcClass
|
|||
GType gst_multifilesrc_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MULTIFILESRC_H__ */
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_PIPEFILTER \
|
||||
(gst_pipefilter_get_type())
|
||||
#define GST_PIPEFILTER(obj) \
|
||||
|
@ -38,19 +40,17 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_PIPEFILTER))
|
||||
#define GST_IS_PIPEFILTER_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_PIPEFILTER))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
GST_PIPEFILTER_OPEN = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
GST_PIPEFILTER_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 2
|
||||
}
|
||||
GstPipeFilterFlags;
|
||||
} GstPipeFilterFlags;
|
||||
|
||||
typedef struct _GstPipefilter GstPipefilter;
|
||||
typedef struct _GstPipefilterClass GstPipefilterClass;
|
||||
|
||||
struct _GstPipefilter
|
||||
{
|
||||
struct _GstPipefilter {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -70,12 +70,12 @@ struct _GstPipefilter
|
|||
gulong seq; /* buffer sequence number */
|
||||
};
|
||||
|
||||
struct _GstPipefilterClass
|
||||
{
|
||||
struct _GstPipefilterClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
GType gst_pipefilter_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PIPEFILTER_H__ */
|
||||
|
|
|
@ -28,6 +28,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_SHAPER \
|
||||
(gst_shaper_get_type())
|
||||
#define GST_SHAPER(obj) \
|
||||
|
@ -38,18 +40,16 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_SHAPER))
|
||||
#define GST_IS_SHAPER_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_SHAPER))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
SHAPER_POLICY_TIMESTAMPS = 1,
|
||||
SHAPER_POLICY_BUFFERSIZE
|
||||
}
|
||||
GstShaperPolicyType;
|
||||
} GstShaperPolicyType;
|
||||
|
||||
typedef struct _GstShaper GstShaper;
|
||||
typedef struct _GstShaperClass GstShaperClass;
|
||||
|
||||
struct _GstShaper
|
||||
{
|
||||
struct _GstShaper {
|
||||
GstElement element;
|
||||
|
||||
GSList *connections;
|
||||
|
@ -61,8 +61,7 @@ struct _GstShaper
|
|||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _GstShaperClass
|
||||
{
|
||||
struct _GstShaperClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
@ -71,4 +70,5 @@ gboolean gst_shaper_factory_init (GstElementFactory * factory);
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SHAPER_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_STATISTICS \
|
||||
(gst_statistics_get_type())
|
||||
#define GST_STATISTICS(obj) \
|
||||
|
@ -37,20 +39,19 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_STATISTICS))
|
||||
#define GST_IS_STATISTICS_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_STATISTICS))
|
||||
|
||||
typedef struct _GstStatistics GstStatistics;
|
||||
typedef struct _GstStatisticsClass GstStatisticsClass;
|
||||
|
||||
typedef struct _stats stats;
|
||||
|
||||
struct _stats
|
||||
{
|
||||
struct _stats {
|
||||
gint64 buffers;
|
||||
gint64 bytes;
|
||||
gint64 events;
|
||||
};
|
||||
|
||||
struct _GstStatistics
|
||||
{
|
||||
struct _GstStatistics {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -69,8 +70,7 @@ struct _GstStatistics
|
|||
gboolean silent;
|
||||
};
|
||||
|
||||
struct _GstStatisticsClass
|
||||
{
|
||||
struct _GstStatisticsClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -80,4 +80,5 @@ struct _GstStatisticsClass
|
|||
GType gst_statistics_get_type(void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_STATISTICS_H__ */
|
||||
|
|
|
@ -27,6 +27,8 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
#define GST_TYPE_TEE \
|
||||
(gst_tee_get_type())
|
||||
#define GST_TEE(obj) \
|
||||
|
@ -37,11 +39,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_TEE))
|
||||
#define GST_IS_TEE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_TEE))
|
||||
|
||||
typedef struct _GstTee GstTee;
|
||||
typedef struct _GstTeeClass GstTeeClass;
|
||||
|
||||
struct _GstTee
|
||||
{
|
||||
struct _GstTee {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -50,8 +52,7 @@ struct _GstTee
|
|||
gchar *last_message;
|
||||
};
|
||||
|
||||
struct _GstTeeClass
|
||||
{
|
||||
struct _GstTeeClass {
|
||||
GstElementClass parent_class;
|
||||
};
|
||||
|
||||
|
@ -60,4 +61,5 @@ GType gst_tee_get_type (void);
|
|||
gboolean gst_tee_factory_init (GstElementFactory *factory);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TEE_H__ */
|
||||
|
|
|
@ -29,17 +29,20 @@
|
|||
#include "gstbufferstore.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
||||
|
||||
#define GST_TYPE_TYPE_FIND_ELEMENT (gst_type_find_element_get_type ())
|
||||
#define GST_TYPE_FIND_ELEMENT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_TYPE_FIND_ELEMENT, GstTypeFindElement))
|
||||
#define GST_IS_TYPE_FIND_ELEMENT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TYPE_FIND_ELEMENT))
|
||||
#define GST_TYPE_FIND_ELEMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_TYPE_FIND_ELEMENT, GstTypeFindElementClass))
|
||||
#define GST_IS_TYPE_FIND_ELEMENT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TYPE_FIND_ELEMENT))
|
||||
#define GST_TYPE_FIND_ELEMENT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_TYPE_FIND_ELEMENT, GstTypeFindElementClass))
|
||||
|
||||
typedef struct _GstTypeFindElement GstTypeFindElement;
|
||||
typedef struct _GstTypeFindElementClass GstTypeFindElementClass;
|
||||
|
||||
struct _GstTypeFindElement
|
||||
{
|
||||
struct _GstTypeFindElement {
|
||||
GstElement element;
|
||||
|
||||
GstPad * sink;
|
||||
|
@ -57,16 +60,17 @@ struct _GstTypeFindElement
|
|||
GList * possibilities;
|
||||
};
|
||||
|
||||
struct _GstTypeFindElementClass
|
||||
{
|
||||
struct _GstTypeFindElementClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals */
|
||||
void (*have_type) (GstTypeFindElement *element,
|
||||
guint probability, const GstCaps * caps);
|
||||
guint probability,
|
||||
const GstCaps * caps);
|
||||
};
|
||||
|
||||
GType gst_type_find_element_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TYPE_FIND_ELEMENT_H__ */
|
||||
|
|
|
@ -69,6 +69,7 @@
|
|||
#include <gst/gstcompat.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* make our own type for poptOption because the struct poptOption
|
||||
* definition is iffy */
|
||||
typedef struct poptOption GstPoptOption;
|
||||
|
@ -77,9 +78,11 @@ typedef struct poptOption GstPoptOption;
|
|||
void gst_init (int *argc, char **argv[]);
|
||||
gboolean gst_init_check (int *argc, char **argv[]);
|
||||
void gst_init_with_popt_table (int *argc, char **argv[],
|
||||
const GstPoptOption * popt_options);
|
||||
const GstPoptOption
|
||||
*popt_options);
|
||||
gboolean gst_init_check_with_popt_table (int *argc, char **argv[],
|
||||
const GstPoptOption * popt_options);
|
||||
const GstPoptOption
|
||||
*popt_options);
|
||||
|
||||
const GstPoptOption * gst_init_get_popt_table (void);
|
||||
|
||||
|
@ -90,5 +93,7 @@ void gst_main (void);
|
|||
void gst_main_quit (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#include <gst/gstlog.h>
|
||||
|
||||
#endif /* __GST_H__ */
|
||||
|
|
|
@ -53,8 +53,7 @@
|
|||
"mtlr r0\n\t" \
|
||||
"blrl" : : "r"(target) );
|
||||
|
||||
struct minimal_ppc_stackframe
|
||||
{
|
||||
struct minimal_ppc_stackframe {
|
||||
unsigned long back_chain;
|
||||
unsigned long LR_save;
|
||||
unsigned long unused1;
|
||||
|
@ -80,8 +79,7 @@ struct minimal_ppc_stackframe
|
|||
/* Need to get more information about the stackframe format
|
||||
* and get the fields more correct. Check GDB sources maybe?
|
||||
*/
|
||||
struct minimal_stackframe
|
||||
{
|
||||
struct minimal_stackframe {
|
||||
unsigned long back_chain;
|
||||
unsigned long LR_save;
|
||||
unsigned long unused1;
|
||||
|
@ -169,8 +167,7 @@ struct minimal_stackframe
|
|||
#define GST_ARCH_CALL(target) \
|
||||
__asm__( "basr 14,%0" : : "a"(target) );
|
||||
|
||||
struct minimal_s390_stackframe
|
||||
{
|
||||
struct minimal_s390_stackframe {
|
||||
unsigned long back_chain;
|
||||
unsigned long reserved;
|
||||
unsigned long greg[14];
|
||||
|
|
|
@ -22,12 +22,13 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef volatile gint gst_vgint; /* gtk-doc volatile workaround */
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef volatile gint gst_vgint; /* gtk-doc volatile workaround */
|
||||
|
||||
typedef struct _GstAtomicInt GstAtomicInt;
|
||||
|
||||
struct _GstAtomicInt
|
||||
{
|
||||
struct _GstAtomicInt {
|
||||
gst_vgint counter;
|
||||
GMutex *lock; /* for C fallback */
|
||||
};
|
||||
|
@ -43,4 +44,5 @@ gboolean gst_atomic_int_dec_and_test (GstAtomicInt * aint);
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_ATOMIC_H__ */
|
||||
|
|
|
@ -34,45 +34,38 @@
|
|||
#include "gstmacros.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#if defined (GST_CAN_INLINE) || defined (__GST_ATOMIC_C__)
|
||||
|
||||
/***** Intel x86 *****/
|
||||
#if defined (HAVE_CPU_I386) && defined(__GNUC__)
|
||||
|
||||
#ifdef GST_CONFIG_NO_SMP
|
||||
#define SMP_LOCK ""
|
||||
#else
|
||||
#define SMP_LOCK "lock ; "
|
||||
#endif
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_add (GstAtomicInt *aint, gint val)
|
||||
{
|
||||
__asm__ __volatile__ (SMP_LOCK "addl %1,%0":"=m" (aint->counter)
|
||||
__asm__ __volatile__(
|
||||
SMP_LOCK "addl %1,%0"
|
||||
:"=m" (aint->counter)
|
||||
:"ir" (val), "m" (aint->counter));
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_inc (GstAtomicInt *aint)
|
||||
{
|
||||
__asm__ __volatile__ (SMP_LOCK "incl %0":"=m" (aint->counter)
|
||||
__asm__ __volatile__(
|
||||
SMP_LOCK "incl %0"
|
||||
:"=m" (aint->counter)
|
||||
:"m" (aint->counter));
|
||||
}
|
||||
|
||||
|
@ -81,8 +74,9 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
{
|
||||
guchar res;
|
||||
|
||||
__asm__ __volatile__ (SMP_LOCK "decl %0; sete %1":"=m" (aint->counter),
|
||||
"=qm" (res)
|
||||
__asm__ __volatile__(
|
||||
SMP_LOCK "decl %0; sete %1"
|
||||
:"=m" (aint->counter), "=qm" (res)
|
||||
:"m" (aint->counter) : "memory");
|
||||
|
||||
return res != 0;
|
||||
|
@ -90,6 +84,7 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
|
||||
/***** PowerPC *****/
|
||||
#elif defined (HAVE_CPU_PPC) && defined(__GNUC__)
|
||||
|
||||
#ifdef GST_CONFIG_NO_SMP
|
||||
#define SMP_SYNC ""
|
||||
#define SMP_ISYNC
|
||||
|
@ -97,6 +92,7 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
#define SMP_SYNC "\tsync\n"
|
||||
#define SMP_ISYNC "\tisync\n"
|
||||
#endif
|
||||
|
||||
/* Erratum #77 on the 405 means we need a sync or dcbt before every stwcx.
|
||||
* The old ATOMIC_SYNC_FIX covered some but not all of this.
|
||||
*/
|
||||
|
@ -105,35 +101,24 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
#else
|
||||
#define PPC405_ERR77(ra,rb)
|
||||
#endif
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_add (GstAtomicInt *aint, gint val)
|
||||
{
|
||||
int t;
|
||||
|
||||
__asm__ __volatile__ ("1: lwarx %0,0,%3\n"
|
||||
" add %0,%2,%0\n" PPC405_ERR77 (0, %3)
|
||||
__asm__ __volatile__(
|
||||
"1: lwarx %0,0,%3\n"
|
||||
" add %0,%2,%0\n"
|
||||
PPC405_ERR77(0,%3)
|
||||
" stwcx. %0,0,%3 \n"
|
||||
" bne- 1b\n":"=&r" (t), "=m" (aint->counter)
|
||||
" bne- 1b\n"
|
||||
: "=&r" (t), "=m" (aint->counter)
|
||||
: "r" (val), "r" (&aint->counter), "m" (aint->counter)
|
||||
: "cc");
|
||||
}
|
||||
|
@ -143,10 +128,13 @@ gst_atomic_int_inc (GstAtomicInt * aint)
|
|||
{
|
||||
int t;
|
||||
|
||||
__asm__ __volatile__ ("1: lwarx %0,0,%2\n"
|
||||
" addic %0,%0,1\n" PPC405_ERR77 (0, %2)
|
||||
__asm__ __volatile__(
|
||||
"1: lwarx %0,0,%2\n"
|
||||
" addic %0,%0,1\n"
|
||||
PPC405_ERR77(0,%2)
|
||||
" stwcx. %0,0,%2\n"
|
||||
" bne- 1b\n":"=&r" (t), "=m" (aint->counter)
|
||||
" bne- 1b\n"
|
||||
: "=&r" (t), "=m" (aint->counter)
|
||||
: "r" (&aint->counter), "m" (aint->counter)
|
||||
: "cc");
|
||||
}
|
||||
|
@ -156,9 +144,14 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
{
|
||||
int t;
|
||||
|
||||
__asm__ __volatile__ ("1: lwarx %0,0,%1\n"
|
||||
" addic %0,%0,-1\n" PPC405_ERR77 (0, %1)
|
||||
" stwcx. %0,0,%1\n" " bne- 1b\n" SMP_ISYNC:"=&r" (t)
|
||||
__asm__ __volatile__(
|
||||
"1: lwarx %0,0,%1\n"
|
||||
" addic %0,%0,-1\n"
|
||||
PPC405_ERR77(0,%1)
|
||||
" stwcx. %0,0,%1\n"
|
||||
" bne- 1b\n"
|
||||
SMP_ISYNC
|
||||
: "=&r" (t)
|
||||
: "r" (&aint->counter)
|
||||
: "cc", "memory");
|
||||
|
||||
|
@ -167,37 +160,26 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
|
||||
/***** DEC[/Compaq/HP?/Intel?] Alpha *****/
|
||||
#elif defined(HAVE_CPU_ALPHA) && defined(__GNUC__)
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_add (GstAtomicInt *aint, gint val)
|
||||
{
|
||||
unsigned long temp;
|
||||
|
||||
__asm__ __volatile__ ("1: ldl_l %0,%1\n"
|
||||
__asm__ __volatile__(
|
||||
"1: ldl_l %0,%1\n"
|
||||
" addl %0,%2,%0\n"
|
||||
" stl_c %0,%1\n"
|
||||
" beq %0,2f\n"
|
||||
".subsection 2\n"
|
||||
"2: br 1b\n" ".previous":"=&r" (temp), "=m" (aint->counter)
|
||||
"2: br 1b\n"
|
||||
".previous"
|
||||
:"=&r" (temp), "=m" (aint->counter)
|
||||
:"Ir" (val), "m" (aint->counter));
|
||||
}
|
||||
|
||||
|
@ -212,7 +194,8 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
{
|
||||
long temp, result;
|
||||
int val = 1;
|
||||
__asm__ __volatile__ ("1: ldl_l %0,%1\n"
|
||||
__asm__ __volatile__(
|
||||
"1: ldl_l %0,%1\n"
|
||||
" subl %0,%3,%2\n"
|
||||
" subl %0,%3,%0\n"
|
||||
" stl_c %0,%1\n"
|
||||
|
@ -220,7 +203,8 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
" mb\n"
|
||||
".subsection 2\n"
|
||||
"2: br 1b\n"
|
||||
".previous":"=&r" (temp), "=m" (aint->counter), "=&r" (result)
|
||||
".previous"
|
||||
:"=&r" (temp), "=m" (aint->counter), "=&r" (result)
|
||||
:"Ir" (val), "m" (aint->counter) : "memory");
|
||||
|
||||
return result == 0;
|
||||
|
@ -229,38 +213,16 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
/***** Sun SPARC *****/
|
||||
#elif 0 && defined(HAVE_CPU_SPARC) && defined(__GNUC__)
|
||||
/* allegedly broken again */
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
|
||||
#ifdef GST_CONFIG_NO_SMP
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
#else
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = (val << 8);
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = (val << 8);
|
||||
}
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = (val<<8); }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = (val<<8); }
|
||||
|
||||
/*
|
||||
* For SMP the trick is you embed the spin lock byte within
|
||||
|
@ -294,14 +256,27 @@ gst_atomic_int_add (GstAtomicInt * aint, gint val)
|
|||
ptr = &(aint->counter);
|
||||
|
||||
#if __GNUC__ > 3 || (__GNUC__ >=3 && __GNUC_MINOR__ >= 2)
|
||||
__asm__ __volatile__ ("1: ldstub [%[ptr] + 3], %[lock]\n" "\torcc %[lock], 0, %[ignore]\n" "\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%[ptr]], %[inc]\n" "\tsra %[inc], 8, %[inc]\n" "\tadd %[inc], %[val], %[inc]\n" "\tsll %[inc], 8, %[lock]\n" "\tst %[lock],[%[ptr]]\n" /* Release the lock */
|
||||
:[inc] "=&r" (increment),[lock] "=r" (lock),[ignore] "=&r" (ignore)
|
||||
__asm__ __volatile__("1: ldstub [%[ptr] + 3], %[lock]\n"
|
||||
"\torcc %[lock], 0, %[ignore]\n"
|
||||
"\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%[ptr]], %[inc]\n"
|
||||
"\tsra %[inc], 8, %[inc]\n"
|
||||
"\tadd %[inc], %[val], %[inc]\n"
|
||||
"\tsll %[inc], 8, %[lock]\n"
|
||||
"\tst %[lock],[%[ptr]]\n" /* Release the lock */
|
||||
: [inc] "=&r" (increment), [lock] "=r" (lock),
|
||||
[ignore] "=&r" (ignore)
|
||||
: "0" (increment), [ptr] "r" (ptr), [val] "r" (val)
|
||||
);
|
||||
#else
|
||||
__asm__ __volatile__ ("1: ldstub [%4 + 3], %1\n" "\torcc %1, 0, %2\n" "\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%4], %0\n" "\tsra %0, 8, %0\n" "\tadd %0, %5, %0\n" "\tsll %0, 8, %1\n" "\tst %1,[%4]\n" /* Release the lock */
|
||||
__asm__ __volatile__("1: ldstub [%4 + 3], %1\n"
|
||||
"\torcc %1, 0, %2\n"
|
||||
"\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%4], %0\n"
|
||||
"\tsra %0, 8, %0\n"
|
||||
"\tadd %0, %5, %0\n"
|
||||
"\tsll %0, 8, %1\n"
|
||||
"\tst %1,[%4]\n" /* Release the lock */
|
||||
: "=&r" (increment), "=r" (lock), "=&r" (ignore)
|
||||
: "0" (increment), "r" (ptr), "r" (val)
|
||||
);
|
||||
|
@ -324,14 +299,27 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
ptr = &aint->counter;
|
||||
|
||||
#if __GNUC__ > 3 || (__GNUC__ >=3 && __GNUC_MINOR__ >= 2)
|
||||
__asm__ __volatile__ ("1: ldstub [%[ptr] + 3], %[lock]\n" "\torcc %[lock], 0, %[ignore]\n" "\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%[ptr]], %[inc]\n" "\tsra %[inc], 8, %[inc]\n" "\tsub %[inc], 1, %[inc]\n" "\tsll %[inc], 8, %[lock]\n" "\tst %[lock],[%[ptr]]\n" /* Release the lock */
|
||||
:[inc] "=&r" (increment),[lock] "=r" (lock),[ignore] "=&r" (ignore)
|
||||
__asm__ __volatile__("1: ldstub [%[ptr] + 3], %[lock]\n"
|
||||
"\torcc %[lock], 0, %[ignore]\n"
|
||||
"\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%[ptr]], %[inc]\n"
|
||||
"\tsra %[inc], 8, %[inc]\n"
|
||||
"\tsub %[inc], 1, %[inc]\n"
|
||||
"\tsll %[inc], 8, %[lock]\n"
|
||||
"\tst %[lock],[%[ptr]]\n" /* Release the lock */
|
||||
: [inc] "=&r" (increment), [lock] "=r" (lock),
|
||||
[ignore] "=&r" (ignore)
|
||||
: "0" (increment), [ptr] "r" (ptr)
|
||||
);
|
||||
#else
|
||||
__asm__ __volatile__ ("1: ldstub [%4 + 3], %1\n" "\torcc %1, 0, %2\n" "\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%4], %0\n" "\tsra %0, 8, %0\n" "\tsub %0, 1, %0\n" "\tsll %0, 8, %1\n" "\tst %1,[%4]\n" /* Release the lock */
|
||||
__asm__ __volatile__("1: ldstub [%4 + 3], %1\n"
|
||||
"\torcc %1, 0, %2\n"
|
||||
"\tbne 1b\n" /* go back until we have the lock */
|
||||
"\tld [%4], %0\n"
|
||||
"\tsra %0, 8, %0\n"
|
||||
"\tsub %0, 1, %0\n"
|
||||
"\tsll %0, 8, %1\n"
|
||||
"\tst %1,[%4]\n" /* Release the lock */
|
||||
: "=&r" (increment), "=r" (lock), "=&r" (ignore)
|
||||
: "0" (increment), "r" (ptr)
|
||||
);
|
||||
|
@ -344,25 +332,11 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
/* This is disabled because the asm code is broken on most MIPS
|
||||
* processors and doesn't generally compile. */
|
||||
#elif defined(HAVE_CPU_MIPS) && defined(__GNUC__) && 0
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
|
||||
/* this only works on MIPS II and better */
|
||||
GST_INLINE_FUNC void
|
||||
|
@ -370,11 +344,12 @@ gst_atomic_int_add (GstAtomicInt * aint, gint val)
|
|||
{
|
||||
unsigned long temp;
|
||||
|
||||
__asm__ __volatile__ ("1: ll %0, %1 # atomic_add\n"
|
||||
__asm__ __volatile__(
|
||||
"1: ll %0, %1 # atomic_add\n"
|
||||
" addu %0, %2 \n"
|
||||
" sc %0, %1 \n"
|
||||
" beqz %0, 1b \n":"=&r" (temp),
|
||||
"=m" (aint->counter)
|
||||
" beqz %0, 1b \n"
|
||||
: "=&r" (temp), "=m" (aint->counter)
|
||||
: "Ir" (val), "m" (aint->counter));
|
||||
}
|
||||
|
||||
|
@ -390,15 +365,16 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
unsigned long temp, result;
|
||||
int val = 1;
|
||||
|
||||
__asm__ __volatile__ (".set push \n"
|
||||
__asm__ __volatile__(
|
||||
".set push \n"
|
||||
".set noreorder # atomic_sub_return\n"
|
||||
"1: ll %1, %2 \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
" sc %0, %2 \n"
|
||||
" beqz %0, 1b \n"
|
||||
" subu %0, %1, %3 \n"
|
||||
".set pop \n":"=&r" (result),
|
||||
"=&r" (temp), "=m" (aint->counter)
|
||||
".set pop \n"
|
||||
: "=&r" (result), "=&r" (temp), "=m" (aint->counter)
|
||||
: "Ir" (val), "m" (aint->counter)
|
||||
: "memory");
|
||||
|
||||
|
@ -407,31 +383,12 @@ gst_atomic_int_dec_and_test (GstAtomicInt * aint)
|
|||
|
||||
/***** S/390 *****/
|
||||
#elif defined(HAVE_CPU_S390) && defined(__GNUC__)
|
||||
typedef struct
|
||||
{
|
||||
volatile int counter;
|
||||
}
|
||||
atomic_t __attribute__ ((aligned (4)));
|
||||
typedef struct { volatile int counter; } atomic_t __attribute__ ((aligned (4)));
|
||||
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_init (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_destroy (GstAtomicInt * aint)
|
||||
{
|
||||
}
|
||||
GST_INLINE_FUNC void
|
||||
gst_atomic_int_set (GstAtomicInt * aint, gint val)
|
||||
{
|
||||
aint->counter = val;
|
||||
}
|
||||
GST_INLINE_FUNC gint
|
||||
gst_atomic_int_read (GstAtomicInt * aint)
|
||||
{
|
||||
return aint->counter;
|
||||
}
|
||||
GST_INLINE_FUNC void gst_atomic_int_init (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC void gst_atomic_int_destroy (GstAtomicInt *aint) { }
|
||||
GST_INLINE_FUNC void gst_atomic_int_set (GstAtomicInt *aint, gint val) { aint->counter = val; }
|
||||
GST_INLINE_FUNC gint gst_atomic_int_read (GstAtomicInt *aint) { return aint->counter; }
|
||||
|
||||
#define __CS_LOOP(old_val, new_val, ptr, op_val, op_string) \
|
||||
__asm__ __volatile__(" l %0,0(%3)\n" \
|
||||
|
@ -447,7 +404,6 @@ GST_INLINE_FUNC void
|
|||
gst_atomic_int_add (GstAtomicInt *aint, gint val)
|
||||
{
|
||||
int old_val, new_val;
|
||||
|
||||
__CS_LOOP(old_val, new_val, aint, val, "ar");
|
||||
}
|
||||
|
||||
|
@ -455,7 +411,6 @@ GST_INLINE_FUNC void
|
|||
gst_atomic_int_inc (GstAtomicInt *aint)
|
||||
{
|
||||
int old_val, new_val;
|
||||
|
||||
__CS_LOOP(old_val, new_val, aint, 1, "ar");
|
||||
}
|
||||
|
||||
|
@ -463,13 +418,13 @@ GST_INLINE_FUNC gboolean
|
|||
gst_atomic_int_dec_and_test (GstAtomicInt *aint)
|
||||
{
|
||||
int old_val, new_val;
|
||||
|
||||
__CS_LOOP(old_val, new_val, aint, 1, "sr");
|
||||
return new_val == 0;
|
||||
}
|
||||
|
||||
#else
|
||||
#warning consider putting your architecture specific atomic implementations here
|
||||
|
||||
/*
|
||||
* generic implementation
|
||||
*/
|
||||
|
@ -560,4 +515,5 @@ gst_atomic_int_free (GstAtomicInt * aint)
|
|||
#endif /* defined (GST_CAN_INLINE) || defined (__GST_TRASH_STACK_C__)*/
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_ATOMIC_IMPL_H__ */
|
||||
|
|
27
gst/gstbin.h
27
gst/gstbin.h
|
@ -26,7 +26,9 @@
|
|||
|
||||
#include <gst/gstelement.h>
|
||||
|
||||
G_BEGIN_DECLS extern GType _gst_bin_type;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
extern GType _gst_bin_type;
|
||||
|
||||
#define GST_TYPE_BIN (_gst_bin_type)
|
||||
#define GST_IS_BIN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_BIN))
|
||||
|
@ -37,8 +39,7 @@ G_BEGIN_DECLS extern GType _gst_bin_type;
|
|||
|
||||
typedef void (*GstBinPrePostIterateFunction) (GstBin *bin, gpointer user_data);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* this bin is a manager of child elements, i.e. a pipeline or thread */
|
||||
GST_BIN_FLAG_MANAGER = GST_ELEMENT_FLAG_LAST,
|
||||
|
||||
|
@ -52,14 +53,12 @@ typedef enum
|
|||
|
||||
/* padding */
|
||||
GST_BIN_FLAG_LAST = GST_ELEMENT_FLAG_LAST + 5
|
||||
}
|
||||
GstBinFlags;
|
||||
} GstBinFlags;
|
||||
|
||||
/*typedef struct _GstBin GstBin; */
|
||||
/*typedef struct _GstBinClass GstBinClass; */
|
||||
|
||||
struct _GstBin
|
||||
{
|
||||
struct _GstBin {
|
||||
GstElement element;
|
||||
|
||||
/* our children */
|
||||
|
@ -71,8 +70,7 @@ struct _GstBin
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstBinClass
|
||||
{
|
||||
struct _GstBinClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* vtable */
|
||||
|
@ -103,7 +101,8 @@ void gst_bin_remove_many (GstBin * bin, GstElement * element_1, ...);
|
|||
/* retrieve a single element or the list of children */
|
||||
GstElement* gst_bin_get_by_name (GstBin *bin, const gchar *name);
|
||||
GstElement* gst_bin_get_by_name_recurse_up (GstBin *bin, const gchar *name);
|
||||
G_CONST_RETURN GList *gst_bin_get_list (GstBin * bin);
|
||||
G_CONST_RETURN GList*
|
||||
gst_bin_get_list (GstBin *bin);
|
||||
GstElement* gst_bin_get_by_interface (GstBin *bin, GType interface);
|
||||
GList * gst_bin_get_all_by_interface (GstBin *bin, GType interface);
|
||||
|
||||
|
@ -121,9 +120,13 @@ void gst_bin_child_state_change (GstBin * bin, GstElementState oldstate,
|
|||
GstElementState newstate, GstElement *child);
|
||||
|
||||
void gst_bin_set_pre_iterate_function (GstBin *bin,
|
||||
GstBinPrePostIterateFunction func, gpointer user_data);
|
||||
GstBinPrePostIterateFunction func,
|
||||
gpointer user_data);
|
||||
void gst_bin_set_post_iterate_function (GstBin *bin,
|
||||
GstBinPrePostIterateFunction func, gpointer user_data);
|
||||
GstBinPrePostIterateFunction func,
|
||||
gpointer user_data);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_BIN_H__ */
|
||||
|
|
|
@ -27,7 +27,9 @@
|
|||
#include <gst/gstdata.h>
|
||||
#include <gst/gstclock.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstBuffer GstBuffer;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstBuffer GstBuffer;
|
||||
|
||||
typedef void (*GstBufferFreeDataFunc) (GstBuffer *buffer);
|
||||
|
||||
|
@ -72,8 +74,7 @@ extern GType _gst_buffer_type;
|
|||
#define GST_BUFFER_OFFSET_END_IS_VALID(buffer) (GST_BUFFER_OFFSET_END (buffer) != GST_BUFFER_OFFSET_NONE)
|
||||
#define GST_BUFFER_MAXSIZE_IS_VALID(buffer) (GST_BUFFER_MAXSIZE (buffer) != GST_BUFFER_MAXSIZE_NONE)
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_BUFFER_READONLY = GST_DATA_READONLY,
|
||||
GST_BUFFER_SUBBUFFER = GST_DATA_FLAG_LAST,
|
||||
GST_BUFFER_ORIGINAL,
|
||||
|
@ -81,11 +82,9 @@ typedef enum
|
|||
GST_BUFFER_KEY_UNIT,
|
||||
GST_BUFFER_DONTKEEP,
|
||||
GST_BUFFER_FLAG_LAST = GST_DATA_FLAG_LAST + 8
|
||||
}
|
||||
GstBufferFlag;
|
||||
} GstBufferFlag;
|
||||
|
||||
struct _GstBuffer
|
||||
{
|
||||
struct _GstBuffer {
|
||||
GstData data_type;
|
||||
|
||||
/* pointer to data and its size */
|
||||
|
@ -130,7 +129,6 @@ G_STMT_START { \
|
|||
#define gst_buffer_unref(buf) gst_data_unref (GST_DATA (buf))
|
||||
/* copy buffer */
|
||||
void gst_buffer_stamp (GstBuffer *dest, const GstBuffer *src);
|
||||
|
||||
#define gst_buffer_copy(buf) GST_BUFFER (gst_data_copy (GST_DATA (buf)))
|
||||
#define gst_buffer_is_writable(buf) gst_data_is_writable (GST_DATA (buf))
|
||||
#define gst_buffer_copy_on_write(buf) GST_BUFFER (gst_data_copy_on_write (GST_DATA (buf)))
|
||||
|
@ -141,8 +139,7 @@ GstBuffer *gst_buffer_create_sub (GstBuffer * parent, guint offset, guint size);
|
|||
/* merge, span, or append two buffers, intelligently */
|
||||
GstBuffer* gst_buffer_merge (GstBuffer *buf1, GstBuffer *buf2);
|
||||
gboolean gst_buffer_is_span_fast (GstBuffer *buf1, GstBuffer *buf2);
|
||||
GstBuffer *gst_buffer_span (GstBuffer * buf1, guint32 offset, GstBuffer * buf2,
|
||||
guint32 len);
|
||||
GstBuffer* gst_buffer_span (GstBuffer *buf1, guint32 offset, GstBuffer *buf2, guint32 len);
|
||||
|
||||
/* --- private --- */
|
||||
void _gst_buffer_initialize (void);
|
||||
|
@ -151,4 +148,5 @@ void gst_buffer_default_free (GstBuffer * buffer);
|
|||
GstBuffer* gst_buffer_default_copy (GstBuffer *buffer);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_BUFFER_H__ */
|
||||
|
|
|
@ -24,50 +24,56 @@
|
|||
#include <gst/gststructure.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_CAPS gst_caps_get_type()
|
||||
#define GST_CAPS(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GST_TYPE_CAPS, GstCaps))
|
||||
#define GST_IS_CAPS(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GST_TYPE_CAPS))
|
||||
|
||||
#define GST_CAPS_FLAGS_ANY (1 << 0)
|
||||
|
||||
#define GST_CAPS_ANY gst_caps_new_any()
|
||||
#define GST_CAPS_NONE gst_caps_new_empty()
|
||||
|
||||
#define GST_STATIC_CAPS_ANY GST_STATIC_CAPS("ANY")
|
||||
#define GST_STATIC_CAPS_NONE GST_STATIC_CAPS("NONE")
|
||||
|
||||
#define GST_CAPS_IS_SIMPLE(caps) (gst_caps_get_size(caps) == 1)
|
||||
#define gst_caps_is_simple(caps) GST_CAPS_IS_SIMPLE(caps)
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
#define GST_DEBUG_CAPS(string, caps) \
|
||||
GST_DEBUG ( string "%s: " GST_PTR_FORMAT, caps)
|
||||
#endif
|
||||
|
||||
#define GST_STATIC_CAPS(string) \
|
||||
{ \
|
||||
/* caps */ { 0 }, \
|
||||
/* string */ string, \
|
||||
}
|
||||
|
||||
typedef struct _GstCaps GstCaps;
|
||||
typedef struct _GstStaticCaps GstStaticCaps;
|
||||
|
||||
struct _GstCaps
|
||||
{
|
||||
struct _GstCaps {
|
||||
GType type;
|
||||
|
||||
guint16 flags;
|
||||
GPtrArray *structs;
|
||||
};
|
||||
|
||||
struct _GstStaticCaps
|
||||
{
|
||||
struct _GstStaticCaps {
|
||||
GstCaps caps;
|
||||
const char *string;
|
||||
};
|
||||
|
||||
GType
|
||||
gst_caps_get_type (void)
|
||||
G_GNUC_CONST;
|
||||
GType gst_caps_get_type (void) G_GNUC_CONST;
|
||||
GstCaps * gst_caps_new_empty (void);
|
||||
GstCaps * gst_caps_new_any (void);
|
||||
GstCaps * gst_caps_new_simple (const char *media_type,
|
||||
const char *fieldname, ...);
|
||||
GstCaps *gst_caps_new_full (GstStructure * struct1, ...);
|
||||
const char *fieldname,
|
||||
...);
|
||||
GstCaps * gst_caps_new_full (GstStructure *struct1,
|
||||
...);
|
||||
GstCaps * gst_caps_new_full_valist (GstStructure *structure,
|
||||
va_list var_args);
|
||||
GstCaps * gst_caps_copy (const GstCaps *caps);
|
||||
|
@ -75,23 +81,26 @@ gst_caps_get_type (void)
|
|||
G_CONST_RETURN GstCaps * gst_static_caps_get (GstStaticCaps *caps);
|
||||
|
||||
/* manipulation */
|
||||
void gst_caps_append (GstCaps * caps1, GstCaps * caps2);
|
||||
void gst_caps_append_structure (GstCaps * caps1, GstStructure * structure);
|
||||
void gst_caps_append (GstCaps *caps1,
|
||||
GstCaps *caps2);
|
||||
void gst_caps_append_structure (GstCaps *caps1,
|
||||
GstStructure *structure);
|
||||
GstCaps * gst_caps_split_one (GstCaps *caps);
|
||||
int gst_caps_get_size (const GstCaps *caps);
|
||||
GstStructure *gst_caps_get_structure (const GstCaps * caps, int index);
|
||||
|
||||
GstStructure * gst_caps_get_structure (const GstCaps *caps,
|
||||
int index);
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
GstCaps * gst_caps_copy_1 (const GstCaps *caps);
|
||||
#endif
|
||||
void gst_caps_set_simple (GstCaps * caps, char *field, ...);
|
||||
void gst_caps_set_simple (GstCaps *caps,
|
||||
char *field, ...);
|
||||
void gst_caps_set_simple_valist (GstCaps *caps,
|
||||
char *field, va_list varargs);
|
||||
char *field,
|
||||
va_list varargs);
|
||||
|
||||
/* tests */
|
||||
gboolean gst_caps_is_any (const GstCaps *caps);
|
||||
gboolean gst_caps_is_empty (const GstCaps *caps);
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_caps_is_chained (const GstCaps *caps);
|
||||
#endif
|
||||
|
@ -102,25 +111,32 @@ gst_caps_get_type (void)
|
|||
const GstCaps *caps2);
|
||||
|
||||
/* operations */
|
||||
GstCaps *gst_caps_intersect (const GstCaps * caps1, const GstCaps * caps2);
|
||||
GstCaps *gst_caps_union (const GstCaps * caps1, const GstCaps * caps2);
|
||||
GstCaps * gst_caps_intersect (const GstCaps *caps1,
|
||||
const GstCaps *caps2);
|
||||
GstCaps * gst_caps_union (const GstCaps *caps1,
|
||||
const GstCaps *caps2);
|
||||
GstCaps * gst_caps_normalize (const GstCaps *caps);
|
||||
GstCaps * gst_caps_simplify (const GstCaps *caps);
|
||||
|
||||
#ifndef GST_DISABLE_LOADSAVE
|
||||
xmlNodePtr gst_caps_save_thyself (const GstCaps * caps, xmlNodePtr parent);
|
||||
xmlNodePtr gst_caps_save_thyself (const GstCaps *caps,
|
||||
xmlNodePtr parent);
|
||||
GstCaps * gst_caps_load_thyself (xmlNodePtr parent);
|
||||
#endif
|
||||
|
||||
/* utility */
|
||||
void gst_caps_replace (GstCaps ** caps, GstCaps * newcaps);
|
||||
void gst_caps_replace (GstCaps **caps,
|
||||
GstCaps *newcaps);
|
||||
gchar * gst_caps_to_string (const GstCaps *caps);
|
||||
GstCaps * gst_caps_from_string (const gchar *string);
|
||||
|
||||
gboolean gst_caps_structure_fixate_field_nearest_int (GstStructure *
|
||||
structure, const char *field_name, int target);
|
||||
gboolean gst_caps_structure_fixate_field_nearest_double (GstStructure *
|
||||
structure, const char *field_name, double target);
|
||||
gboolean gst_caps_structure_fixate_field_nearest_int (GstStructure *structure,
|
||||
const char *field_name,
|
||||
int target);
|
||||
gboolean gst_caps_structure_fixate_field_nearest_double (GstStructure *structure,
|
||||
const char *field_name,
|
||||
double target);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_CAPS_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <gst/gstobject.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* --- standard type macros --- */
|
||||
#define GST_TYPE_CLOCK (gst_clock_get_type ())
|
||||
#define GST_CLOCK(clock) (G_TYPE_CHECK_INSTANCE_CAST ((clock), GST_TYPE_CLOCK, GstClock))
|
||||
|
@ -33,6 +34,7 @@ G_BEGIN_DECLS
|
|||
#define GST_CLOCK_CLASS(cclass) (G_TYPE_CHECK_CLASS_CAST ((cclass), GST_TYPE_CLOCK, GstClockClass))
|
||||
#define GST_IS_CLOCK_CLASS(cclass) (G_TYPE_CHECK_CLASS_TYPE ((cclass), GST_TYPE_CLOCK))
|
||||
#define GST_CLOCK_GET_CLASS(clock) (G_TYPE_INSTANCE_GET_CLASS ((clock), GST_TYPE_CLOCK, GstClockClass))
|
||||
|
||||
typedef guint64 GstClockTime;
|
||||
typedef gint64 GstClockTimeDiff;
|
||||
typedef gpointer GstClockID;
|
||||
|
@ -63,22 +65,18 @@ typedef struct _GstClockClass GstClockClass;
|
|||
typedef gboolean (*GstClockCallback) (GstClock *clock, GstClockTime time,
|
||||
GstClockID id, gpointer user_data);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* --- protected --- */
|
||||
GST_CLOCK_ENTRY_OK,
|
||||
GST_CLOCK_ENTRY_EARLY,
|
||||
GST_CLOCK_ENTRY_RESTART
|
||||
}
|
||||
GstClockEntryStatus;
|
||||
} GstClockEntryStatus;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* --- protected --- */
|
||||
GST_CLOCK_ENTRY_SINGLE,
|
||||
GST_CLOCK_ENTRY_PERIODIC
|
||||
}
|
||||
GstClockEntryType;
|
||||
} GstClockEntryType;
|
||||
|
||||
#define GST_CLOCK_ENTRY(entry) ((GstClockEntry *)(entry))
|
||||
#define GST_CLOCK_ENTRY_CLOCK(entry) ((entry)->clock)
|
||||
|
@ -87,8 +85,7 @@ GstClockEntryType;
|
|||
#define GST_CLOCK_ENTRY_INTERVAL(entry) ((entry)->interval)
|
||||
#define GST_CLOCK_ENTRY_STATUS(entry) ((entry)->status)
|
||||
|
||||
struct _GstClockEntry
|
||||
{
|
||||
struct _GstClockEntry {
|
||||
/* --- protected --- */
|
||||
GstClock *clock;
|
||||
GstClockEntryType type;
|
||||
|
@ -106,8 +103,7 @@ typedef enum
|
|||
GST_CLOCK_EARLY = 2,
|
||||
GST_CLOCK_ERROR = 3,
|
||||
GST_CLOCK_UNSUPPORTED = 4
|
||||
}
|
||||
GstClockReturn;
|
||||
} GstClockReturn;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
|
@ -117,13 +113,11 @@ typedef enum
|
|||
GST_CLOCK_FLAG_CAN_DO_PERIODIC_ASYNC = (1 << 4),
|
||||
GST_CLOCK_FLAG_CAN_SET_RESOLUTION = (1 << 5),
|
||||
GST_CLOCK_FLAG_CAN_SET_SPEED = (1 << 6)
|
||||
}
|
||||
GstClockFlags;
|
||||
} GstClockFlags;
|
||||
|
||||
#define GST_CLOCK_FLAGS(clock) (GST_CLOCK(clock)->flags)
|
||||
|
||||
struct _GstClock
|
||||
{
|
||||
struct _GstClock {
|
||||
GstObject object;
|
||||
|
||||
GstClockFlags flags;
|
||||
|
@ -146,8 +140,7 @@ struct _GstClock
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstClockClass
|
||||
{
|
||||
struct _GstClockClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* vtable */
|
||||
|
@ -188,19 +181,24 @@ GstClockTime gst_clock_get_event_time (GstClock * clock);
|
|||
GstClockID gst_clock_get_next_id (GstClock *clock);
|
||||
|
||||
/* creating IDs that can be used to get notifications */
|
||||
GstClockID gst_clock_new_single_shot_id (GstClock * clock, GstClockTime time);
|
||||
GstClockID gst_clock_new_single_shot_id (GstClock *clock,
|
||||
GstClockTime time);
|
||||
GstClockID gst_clock_new_periodic_id (GstClock *clock,
|
||||
GstClockTime start_time, GstClockTime interval);
|
||||
GstClockTime start_time,
|
||||
GstClockTime interval);
|
||||
|
||||
/* operations on IDs */
|
||||
GstClockTime gst_clock_id_get_time (GstClockID id);
|
||||
GstClockReturn gst_clock_id_wait (GstClockID id, GstClockTimeDiff * jitter);
|
||||
GstClockReturn gst_clock_id_wait (GstClockID id,
|
||||
GstClockTimeDiff *jitter);
|
||||
GstClockReturn gst_clock_id_wait_async (GstClockID id,
|
||||
GstClockCallback func, gpointer user_data);
|
||||
GstClockCallback func,
|
||||
gpointer user_data);
|
||||
void gst_clock_id_unschedule (GstClockID id);
|
||||
void gst_clock_id_unlock (GstClockID id);
|
||||
void gst_clock_id_free (GstClockID id);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_CLOCK_H__ */
|
||||
|
|
|
@ -26,8 +26,10 @@
|
|||
#define __GSTCOMPAT_H__
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
/* 0.5.2 changes */
|
||||
|
||||
/* element functions */
|
||||
#define gst_element_connect(a,b) gst_element_link(a,b)
|
||||
#define gst_element_connect_pads(a,b,c,d) \
|
||||
|
@ -41,6 +43,7 @@ G_BEGIN_DECLS
|
|||
#define gst_element_connect_filtered(a,b,c) \
|
||||
gst_element_link_filtered(a,b,c)
|
||||
#define gst_element_disconnect(a,b) gst_element_unlink(a,b)
|
||||
|
||||
/* pad functions */
|
||||
#define gst_pad_connect(a,b) gst_pad_link(a,b)
|
||||
#define gst_pad_connect_filtered(a,b,c) gst_pad_link_filtered(a,b,c)
|
||||
|
@ -48,8 +51,10 @@ G_BEGIN_DECLS
|
|||
#define gst_pad_proxy_connect(a,b) gst_pad_proxy_link(a,b)
|
||||
#define gst_pad_set_connect_function(a,b) \
|
||||
gst_pad_set_link_function(a,b)
|
||||
|
||||
/* pad macros */
|
||||
#define GST_PAD_IS_CONNECTED(a) GST_PAD_IS_LINKED(a)
|
||||
|
||||
/* pad enums */
|
||||
#define GST_PAD_CONNECT_REFUSED GST_PAD_LINK_REFUSED
|
||||
#define GST_PAD_CONNECT_DELAYED GST_PAD_LINK_DELAYED
|
||||
|
@ -67,4 +72,5 @@ typedef GstPadLinkFunction GstPadConnectFunction;
|
|||
#endif /* not GST_DISABLE_DEPRECATED */
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GSTCOMPAT_H__ */
|
||||
|
|
|
@ -24,18 +24,19 @@
|
|||
#ifndef __GST_CPU_H__
|
||||
#define __GST_CPU_H__
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_CPU_FLAG_MMX = (1<<0),
|
||||
GST_CPU_FLAG_SSE = (1<<1),
|
||||
GST_CPU_FLAG_MMXEXT = (1<<2),
|
||||
GST_CPU_FLAG_3DNOW = (1<<3)
|
||||
}
|
||||
GstCPUFlags;
|
||||
} GstCPUFlags;
|
||||
|
||||
void _gst_cpu_initialize (gboolean useopt);
|
||||
|
||||
GstCPUFlags gst_cpu_get_flags (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_CPU_H__ */
|
||||
|
|
|
@ -29,17 +29,21 @@
|
|||
#include <gst/gsttypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* type */
|
||||
#define GST_DATA(data) ((GstData*)(data))
|
||||
#define GST_DATA_TYPE(data) (GST_DATA(data)->type)
|
||||
|
||||
/* flags */
|
||||
#define GST_DATA_FLAGS(data) (GST_DATA(data)->flags)
|
||||
#define GST_DATA_FLAG_SHIFT(flag) (1<<(flag))
|
||||
#define GST_DATA_FLAG_IS_SET(data,flag) (GST_DATA_FLAGS(data) & (1<<(flag)))
|
||||
#define GST_DATA_FLAG_SET(data,flag) G_STMT_START{ (GST_DATA_FLAGS(data) |= (1<<(flag))); }G_STMT_END
|
||||
#define GST_DATA_FLAG_UNSET(data,flag) G_STMT_START{ (GST_DATA_FLAGS(data) &= ~(1<<(flag))); }G_STMT_END
|
||||
|
||||
/* Macros for the GType */
|
||||
#define GST_TYPE_DATA (gst_data_get_type ())
|
||||
|
||||
typedef struct _GstData GstData;
|
||||
|
||||
typedef void (*GstDataFreeFunction) (GstData *data);
|
||||
|
@ -51,8 +55,7 @@ typedef enum
|
|||
|
||||
/* insert more */
|
||||
GST_DATA_FLAG_LAST = 8
|
||||
}
|
||||
GstDataFlags;
|
||||
} GstDataFlags;
|
||||
|
||||
/* refcount */
|
||||
#define GST_DATA_REFCOUNT(data) ((GST_DATA(data))->refcount)
|
||||
|
@ -63,8 +66,7 @@ GstDataFlags;
|
|||
#define GST_DATA_FREE_FUNC(data) (GST_DATA(data)->free)
|
||||
|
||||
|
||||
struct _GstData
|
||||
{
|
||||
struct _GstData {
|
||||
GType type;
|
||||
|
||||
/* refcounting */
|
||||
|
@ -81,7 +83,8 @@ struct _GstData
|
|||
|
||||
/* function used by subclasses only */
|
||||
void gst_data_init (GstData *data, GType type, guint16 flags,
|
||||
GstDataFreeFunction free, GstDataCopyFunction copy);
|
||||
GstDataFreeFunction free,
|
||||
GstDataCopyFunction copy);
|
||||
void gst_data_dispose (GstData *data);
|
||||
void gst_data_copy_into (const GstData *data, GstData *target);
|
||||
|
||||
|
@ -96,9 +99,8 @@ GstData *gst_data_ref_by_count (GstData * data, gint count);
|
|||
void gst_data_unref (GstData* data);
|
||||
|
||||
/* GType for GstData */
|
||||
GType
|
||||
gst_data_get_type (void)
|
||||
G_GNUC_CONST;
|
||||
GType gst_data_get_type (void) G_GNUC_CONST;
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_DATA_H__ */
|
||||
|
|
|
@ -35,3 +35,4 @@ G_STMT_START { \
|
|||
G_STMT_START { \
|
||||
gst_atomic_int_destroy (&(data)->refcount); \
|
||||
} G_STMT_END;
|
||||
|
||||
|
|
142
gst/gstelement.h
142
gst/gstelement.h
|
@ -34,11 +34,12 @@
|
|||
#include <gst/gstindex.h>
|
||||
#include <gst/gsttag.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstElementDetails GstElementDetails;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstElementDetails GstElementDetails;
|
||||
|
||||
/* FIXME: need translatable stuff in here (how handle in registry)? */
|
||||
struct _GstElementDetails
|
||||
{
|
||||
struct _GstElementDetails {
|
||||
gchar *longname; /* long, english name */
|
||||
gchar *klass; /* type of element, as hierarchy */
|
||||
gchar *description; /* insights of one form or another */
|
||||
|
@ -46,7 +47,6 @@ struct _GstElementDetails
|
|||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
#define GST_ELEMENT_DETAILS(longname,klass,description,author) \
|
||||
{ longname, klass, description, author, GST_PADDING_INIT }
|
||||
#define GST_IS_ELEMENT_DETAILS(details) ( \
|
||||
|
@ -98,8 +98,7 @@ extern GType _gst_element_type;
|
|||
#endif
|
||||
#endif
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* element is complex (for some def.) and generally require a cothread */
|
||||
GST_ELEMENT_COMPLEX = GST_OBJECT_FLAG_LAST,
|
||||
/* input and output pads aren't directly coupled to each other
|
||||
|
@ -129,8 +128,7 @@ typedef enum
|
|||
|
||||
/* use some padding for future expansion */
|
||||
GST_ELEMENT_FLAG_LAST = GST_OBJECT_FLAG_LAST + 16
|
||||
}
|
||||
GstElementFlags;
|
||||
} GstElementFlags;
|
||||
|
||||
#define GST_ELEMENT_IS_THREAD_SUGGESTED(obj) (GST_FLAG_IS_SET(obj,GST_ELEMENT_THREAD_SUGGESTED))
|
||||
#define GST_ELEMENT_IS_EVENT_AWARE(obj) (GST_FLAG_IS_SET(obj,GST_ELEMENT_EVENT_AWARE))
|
||||
|
@ -160,8 +158,7 @@ typedef void (*GstElementLoopFunction) (GstElement * element);
|
|||
typedef void (*GstElementPreRunFunction) (GstElement *element);
|
||||
typedef void (*GstElementPostRunFunction) (GstElement *element);
|
||||
|
||||
struct _GstElement
|
||||
{
|
||||
struct _GstElement {
|
||||
GstObject object;
|
||||
|
||||
/* element state and scheduling */
|
||||
|
@ -193,8 +190,7 @@ struct _GstElement
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstElementClass
|
||||
{
|
||||
struct _GstElementClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* the element details */
|
||||
|
@ -208,21 +204,16 @@ struct _GstElementClass
|
|||
gint numpadtemplates;
|
||||
|
||||
/* signal callbacks */
|
||||
void (*state_change) (GstElement * element, GstElementState old,
|
||||
GstElementState state);
|
||||
void (*state_change) (GstElement *element, GstElementState old, GstElementState state);
|
||||
void (*new_pad) (GstElement *element, GstPad *pad);
|
||||
void (*pad_removed) (GstElement *element, GstPad *pad);
|
||||
void (*error) (GstElement * element, GstElement * source, GError * error,
|
||||
gchar * debug);
|
||||
void (*error) (GstElement *element, GstElement *source, GError *error, gchar *debug);
|
||||
void (*eos) (GstElement *element);
|
||||
void (*found_tag) (GstElement * element, GstElement * source,
|
||||
const GstTagList * tag_list);
|
||||
void (*found_tag) (GstElement *element, GstElement *source, const GstTagList *tag_list);
|
||||
|
||||
/* local pointers for get/set */
|
||||
void (*set_property) (GObject * object, guint prop_id, const GValue * value,
|
||||
GParamSpec * pspec);
|
||||
void (*get_property) (GObject * object, guint prop_id, GValue * value,
|
||||
GParamSpec * pspec);
|
||||
void (*set_property) (GObject *object, guint prop_id, const GValue *value, GParamSpec *pspec);
|
||||
void (*get_property) (GObject *object, guint prop_id, GValue *value, GParamSpec *pspec);
|
||||
|
||||
/* vtable*/
|
||||
gboolean (*release_locks) (GstElement *element);
|
||||
|
@ -242,8 +233,7 @@ struct _GstElementClass
|
|||
GstElementStateReturn (*change_state) (GstElement *element);
|
||||
|
||||
/* request/release pads */
|
||||
GstPad *(*request_new_pad) (GstElement * element, GstPadTemplate * templ,
|
||||
const gchar * name);
|
||||
GstPad* (*request_new_pad) (GstElement *element, GstPadTemplate *templ, const gchar* name);
|
||||
void (*release_pad) (GstElement *element, GstPad *pad);
|
||||
|
||||
/* set/get clocks */
|
||||
|
@ -254,13 +244,11 @@ struct _GstElementClass
|
|||
GstIndex* (*get_index) (GstElement *element);
|
||||
void (*set_index) (GstElement *element, GstIndex *index);
|
||||
|
||||
GstElementStateReturn (*set_state) (GstElement * element,
|
||||
GstElementState state);
|
||||
GstElementStateReturn (*set_state) (GstElement *element, GstElementState state);
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
void gst_element_class_add_pad_template (GstElementClass * klass,
|
||||
GstPadTemplate * templ);
|
||||
void gst_element_class_add_pad_template (GstElementClass *klass, GstPadTemplate *templ);
|
||||
void gst_element_class_install_std_props (GstElementClass *klass,
|
||||
const gchar *first_name, ...);
|
||||
void gst_element_class_set_details (GstElementClass *klass,
|
||||
|
@ -268,8 +256,7 @@ void gst_element_class_set_details (GstElementClass * klass,
|
|||
|
||||
#define gst_element_default_deep_notify gst_object_default_deep_notify
|
||||
|
||||
void gst_element_default_error (GObject * object, GstObject * orig,
|
||||
GError * error, gchar * debug);
|
||||
void gst_element_default_error (GObject *object, GstObject *orig, GError *error, gchar *debug);
|
||||
|
||||
GType gst_element_get_type (void);
|
||||
void gst_element_set_loop_function (GstElement *element,
|
||||
|
@ -281,18 +268,16 @@ void gst_element_set_loop_function (GstElement * element,
|
|||
#define gst_element_set_parent(elem,parent) gst_object_set_parent(GST_OBJECT(elem),parent)
|
||||
|
||||
/* threadsafe versions of their g_object_* counterparts */
|
||||
void gst_element_set (GstElement * element, const gchar * first_property_name,
|
||||
...);
|
||||
void gst_element_get (GstElement * element, const gchar * first_property_name,
|
||||
...);
|
||||
void gst_element_set_valist (GstElement * element,
|
||||
const gchar * first_property_name, va_list var_args);
|
||||
void gst_element_get_valist (GstElement * element,
|
||||
const gchar * first_property_name, va_list var_args);
|
||||
void gst_element_set_property (GstElement * element,
|
||||
const gchar * property_name, const GValue * value);
|
||||
void gst_element_get_property (GstElement * element,
|
||||
const gchar * property_name, GValue * value);
|
||||
void gst_element_set (GstElement *element, const gchar *first_property_name, ...);
|
||||
void gst_element_get (GstElement *element, const gchar *first_property_name, ...);
|
||||
void gst_element_set_valist (GstElement *element, const gchar *first_property_name,
|
||||
va_list var_args);
|
||||
void gst_element_get_valist (GstElement *element, const gchar *first_property_name,
|
||||
va_list var_args);
|
||||
void gst_element_set_property (GstElement *element, const gchar *property_name,
|
||||
const GValue *value);
|
||||
void gst_element_get_property (GstElement *element, const gchar *property_name,
|
||||
GValue *value);
|
||||
|
||||
void gst_element_enable_threadsafe_properties (GstElement *element);
|
||||
void gst_element_disable_threadsafe_properties (GstElement *element);
|
||||
|
@ -325,8 +310,7 @@ GstScheduler *gst_element_get_scheduler (GstElement * element);
|
|||
|
||||
void gst_element_add_pad (GstElement *element, GstPad *pad);
|
||||
void gst_element_remove_pad (GstElement *element, GstPad *pad);
|
||||
GstPad *gst_element_add_ghost_pad (GstElement * element, GstPad * pad,
|
||||
const gchar * name);
|
||||
GstPad * gst_element_add_ghost_pad (GstElement *element, GstPad *pad, const gchar *name);
|
||||
void gst_element_remove_ghost_pad (GstElement *element, GstPad *pad);
|
||||
|
||||
GstPad* gst_element_get_pad (GstElement *element, const gchar *name);
|
||||
|
@ -334,20 +318,17 @@ GstPad *gst_element_get_static_pad (GstElement * element, const gchar * name);
|
|||
GstPad* gst_element_get_request_pad (GstElement *element, const gchar *name);
|
||||
void gst_element_release_request_pad (GstElement *element, GstPad *pad);
|
||||
|
||||
G_CONST_RETURN GList *gst_element_get_pad_list (GstElement * element);
|
||||
G_CONST_RETURN GList*
|
||||
gst_element_get_pad_list (GstElement *element);
|
||||
GstPad* gst_element_get_compatible_pad (GstElement *element, GstPad *pad);
|
||||
GstPad *gst_element_get_compatible_pad_filtered (GstElement * element,
|
||||
GstPad * pad, const GstCaps * filtercaps);
|
||||
GstPad* gst_element_get_compatible_pad_filtered (GstElement *element, GstPad *pad,
|
||||
const GstCaps *filtercaps);
|
||||
|
||||
GstPadTemplate *gst_element_class_get_pad_template (GstElementClass *
|
||||
element_class, const gchar * name);
|
||||
GList *gst_element_class_get_pad_template_list (GstElementClass *
|
||||
element_class);
|
||||
GstPadTemplate *gst_element_get_pad_template (GstElement * element,
|
||||
const gchar * name);
|
||||
GstPadTemplate* gst_element_class_get_pad_template (GstElementClass *element_class, const gchar *name);
|
||||
GList* gst_element_class_get_pad_template_list (GstElementClass *element_class);
|
||||
GstPadTemplate* gst_element_get_pad_template (GstElement *element, const gchar *name);
|
||||
GList* gst_element_get_pad_template_list (GstElement *element);
|
||||
GstPadTemplate *gst_element_get_compatible_pad_template (GstElement * element,
|
||||
GstPadTemplate * compattempl);
|
||||
GstPadTemplate* gst_element_get_compatible_pad_template (GstElement *element, GstPadTemplate *compattempl);
|
||||
|
||||
gboolean gst_element_link (GstElement *src, GstElement *dest);
|
||||
gboolean gst_element_link_many (GstElement *element_1,
|
||||
|
@ -360,27 +341,30 @@ void gst_element_unlink_many (GstElement * element_1,
|
|||
|
||||
gboolean gst_element_link_pads (GstElement *src, const gchar *srcpadname,
|
||||
GstElement *dest, const gchar *destpadname);
|
||||
gboolean gst_element_link_pads_filtered (GstElement * src,
|
||||
const gchar * srcpadname, GstElement * dest, const gchar * destpadname,
|
||||
gboolean gst_element_link_pads_filtered (GstElement *src, const gchar *srcpadname,
|
||||
GstElement *dest, const gchar *destpadname,
|
||||
const GstCaps *filtercaps);
|
||||
void gst_element_unlink_pads (GstElement *src, const gchar *srcpadname,
|
||||
GstElement *dest, const gchar *destpadname);
|
||||
|
||||
G_CONST_RETURN GstEventMask *gst_element_get_event_masks (GstElement * element);
|
||||
G_CONST_RETURN GstEventMask*
|
||||
gst_element_get_event_masks (GstElement *element);
|
||||
gboolean gst_element_send_event (GstElement *element, GstEvent *event);
|
||||
gboolean gst_element_seek (GstElement *element, GstSeekType seek_type,
|
||||
guint64 offset);
|
||||
G_CONST_RETURN GstQueryType *gst_element_get_query_types (GstElement * element);
|
||||
G_CONST_RETURN GstQueryType*
|
||||
gst_element_get_query_types (GstElement *element);
|
||||
gboolean gst_element_query (GstElement *element, GstQueryType type,
|
||||
GstFormat *format, gint64 *value);
|
||||
G_CONST_RETURN GstFormat *gst_element_get_formats (GstElement * element);
|
||||
G_CONST_RETURN GstFormat*
|
||||
gst_element_get_formats (GstElement *element);
|
||||
gboolean gst_element_convert (GstElement *element,
|
||||
GstFormat src_format, gint64 src_value,
|
||||
GstFormat *dest_format, gint64 *dest_value);
|
||||
|
||||
void gst_element_found_tags (GstElement *element, const GstTagList *tag_list);
|
||||
void gst_element_found_tags_for_pad (GstElement * element, GstPad * pad,
|
||||
GstClockTime timestamp, GstTagList * list);
|
||||
void gst_element_found_tags_for_pad (GstElement *element, GstPad *pad, GstClockTime timestamp,
|
||||
GstTagList *list);
|
||||
|
||||
void gst_element_set_eos (GstElement *element);
|
||||
|
||||
|
@ -394,8 +378,7 @@ void gst_element_set_locked_state (GstElement * element, gboolean locked_state);
|
|||
gboolean gst_element_sync_state_with_parent (GstElement *element);
|
||||
|
||||
GstElementState gst_element_get_state (GstElement *element);
|
||||
GstElementStateReturn gst_element_set_state (GstElement * element,
|
||||
GstElementState state);
|
||||
GstElementStateReturn gst_element_set_state (GstElement *element, GstElementState state);
|
||||
|
||||
void gst_element_wait_state_change (GstElement *element);
|
||||
|
||||
|
@ -420,8 +403,7 @@ GstBin *gst_element_get_managing_bin (GstElement * element);
|
|||
#define GST_IS_ELEMENT_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_ELEMENT_FACTORY))
|
||||
#define GST_IS_ELEMENT_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_ELEMENT_FACTORY))
|
||||
|
||||
struct _GstElementFactory
|
||||
{
|
||||
struct _GstElementFactory {
|
||||
GstPluginFeature parent;
|
||||
|
||||
GType type; /* unique GType of element or 0 if not loaded */
|
||||
|
@ -440,8 +422,7 @@ struct _GstElementFactory
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstElementFactoryClass
|
||||
{
|
||||
struct _GstElementFactoryClass {
|
||||
GstPluginFeatureClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -450,28 +431,24 @@ struct _GstElementFactoryClass
|
|||
GType gst_element_factory_get_type (void);
|
||||
|
||||
gboolean gst_element_register (GstPlugin *plugin,
|
||||
const gchar * elementname, guint rank, GType type);
|
||||
const gchar *elementname,
|
||||
guint rank,
|
||||
GType type);
|
||||
|
||||
GstElementFactory * gst_element_factory_find (const gchar *name);
|
||||
GType gst_element_factory_get_element_type (GstElementFactory *factory);
|
||||
G_CONST_RETURN gchar *gst_element_factory_get_longname (GstElementFactory *
|
||||
factory);
|
||||
G_CONST_RETURN gchar *gst_element_factory_get_klass (GstElementFactory *
|
||||
factory);
|
||||
G_CONST_RETURN gchar *gst_element_factory_get_description (GstElementFactory *
|
||||
factory);
|
||||
G_CONST_RETURN gchar *gst_element_factory_get_author (GstElementFactory *
|
||||
factory);
|
||||
G_CONST_RETURN gchar * gst_element_factory_get_longname (GstElementFactory *factory);
|
||||
G_CONST_RETURN gchar * gst_element_factory_get_klass (GstElementFactory *factory);
|
||||
G_CONST_RETURN gchar * gst_element_factory_get_description (GstElementFactory *factory);
|
||||
G_CONST_RETURN gchar * gst_element_factory_get_author (GstElementFactory *factory);
|
||||
guint gst_element_factory_get_num_pad_templates (GstElementFactory *factory);
|
||||
G_CONST_RETURN GList *gst_element_factory_get_pad_templates (GstElementFactory *
|
||||
factory);
|
||||
G_CONST_RETURN GList * gst_element_factory_get_pad_templates (GstElementFactory *factory);
|
||||
guint gst_element_factory_get_uri_type (GstElementFactory *factory);
|
||||
gchar ** gst_element_factory_get_uri_protocols (GstElementFactory *factory);
|
||||
|
||||
GstElement* gst_element_factory_create (GstElementFactory *factory,
|
||||
const gchar *name);
|
||||
GstElement *gst_element_factory_make (const gchar * factoryname,
|
||||
const gchar * name);
|
||||
GstElement* gst_element_factory_make (const gchar *factoryname, const gchar *name);
|
||||
|
||||
gboolean gst_element_factory_can_src_caps (GstElementFactory *factory,
|
||||
const GstCaps *caps);
|
||||
|
@ -485,4 +462,7 @@ void __gst_element_factory_add_interface (GstElementFactory * elementfactory,
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_ELEMENT_H__ */
|
||||
|
||||
|
|
|
@ -21,6 +21,7 @@
|
|||
#define __GST_ERROR_H__
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/*
|
||||
* we define FIXME error domains:
|
||||
* GST_CORE_ERROR
|
||||
|
@ -30,12 +31,12 @@ G_BEGIN_DECLS
|
|||
*
|
||||
* Check GError API docs for rationale for naming.
|
||||
*/
|
||||
|
||||
/* Core errors are anything that can go wrong in or using
|
||||
* the core GStreamer library */
|
||||
/* FIXME: should we divide in numerical blocks so we can easily add
|
||||
for example PAD errors later ? */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_CORE_ERROR_FAILED = 1,
|
||||
GST_CORE_ERROR_TOO_LAZY,
|
||||
GST_CORE_ERROR_NOT_IMPLEMENTED,
|
||||
|
@ -54,8 +55,7 @@ GstCoreError;
|
|||
|
||||
/* Library errors are for errors from the library being used by elements
|
||||
initializing, closing, ... */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_LIBRARY_ERROR_FAILED = 1,
|
||||
GST_LIBRARY_ERROR_TOO_LAZY,
|
||||
GST_LIBRARY_ERROR_INIT,
|
||||
|
@ -69,8 +69,7 @@ GstLibraryError;
|
|||
/* Resource errors are for anything external used by an element:
|
||||
memory, files, network connections, process space, ...
|
||||
They're typically used by source and sink elements */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_RESOURCE_ERROR_FAILED = 1,
|
||||
GST_RESOURCE_ERROR_TOO_LAZY,
|
||||
GST_RESOURCE_ERROR_NOT_FOUND,
|
||||
|
@ -91,8 +90,7 @@ GstResourceError;
|
|||
/* Stream errors are for anything related to the stream being processed:
|
||||
format errors, media type errors, ...
|
||||
They're typically used by decoders, demuxers, converters, ... */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_STREAM_ERROR_FAILED = 1,
|
||||
GST_STREAM_ERROR_TOO_LAZY,
|
||||
GST_STREAM_ERROR_NOT_IMPLEMENTED,
|
||||
|
@ -126,4 +124,7 @@ GQuark gst_resource_error_quark (void);
|
|||
GQuark gst_library_error_quark (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_ERROR_H__ */
|
||||
|
||||
|
||||
|
|
|
@ -30,10 +30,11 @@
|
|||
#include <gst/gstobject.h>
|
||||
#include <gst/gststructure.h>
|
||||
|
||||
G_BEGIN_DECLS extern GType _gst_event_type;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum
|
||||
{
|
||||
extern GType _gst_event_type;
|
||||
|
||||
typedef enum {
|
||||
GST_EVENT_UNKNOWN = 0,
|
||||
GST_EVENT_EOS = 1,
|
||||
GST_EVENT_FLUSH = 2,
|
||||
|
@ -51,8 +52,7 @@ typedef enum
|
|||
GST_EVENT_INTERRUPT = 14,
|
||||
GST_EVENT_NAVIGATION = 15,
|
||||
GST_EVENT_TAG = 16
|
||||
}
|
||||
GstEventType;
|
||||
} GstEventType;
|
||||
|
||||
#define GST_EVENT_TRACE_NAME "GstEvent"
|
||||
|
||||
|
@ -73,21 +73,18 @@ GstEventType;
|
|||
#define GST_SEEK_METHOD_MASK 0x000f0000
|
||||
#define GST_SEEK_FLAGS_MASK 0xfff00000
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_EVENT_FLAG_NONE = 0,
|
||||
|
||||
/* indicates negative rates are supported */
|
||||
GST_RATE_FLAG_NEGATIVE = (1 << 1)
|
||||
}
|
||||
GstEventFlag;
|
||||
} GstEventFlag;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
GstEventType type;
|
||||
GstEventFlag flags;
|
||||
}
|
||||
GstEventMask;
|
||||
} GstEventMask;
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
#ifdef G_HAVE_ISO_VARARGS
|
||||
|
@ -116,8 +113,7 @@ functionname (type pad) \
|
|||
#endif
|
||||
|
||||
/* seek events, extends GstEventFlag */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* | with some format */
|
||||
/* | with one of these */
|
||||
GST_SEEK_METHOD_CUR = (1 << (GST_SEEK_METHOD_SHIFT + 0)),
|
||||
|
@ -131,22 +127,18 @@ typedef enum
|
|||
GST_SEEK_FLAG_KEY_UNIT = (1 << (GST_SEEK_FLAGS_SHIFT + 2)),
|
||||
GST_SEEK_FLAG_SEGMENT_LOOP = (1 << (GST_SEEK_FLAGS_SHIFT + 3))
|
||||
|
||||
}
|
||||
GstSeekType;
|
||||
} GstSeekType;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_SEEK_CERTAIN,
|
||||
GST_SEEK_FUZZY
|
||||
}
|
||||
GstSeekAccuracy;
|
||||
} GstSeekAccuracy;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
GstFormat format;
|
||||
gint64 value;
|
||||
}
|
||||
GstFormatValue;
|
||||
} GstFormatValue;
|
||||
|
||||
#define GST_EVENT_SEEK_TYPE(event) (GST_EVENT(event)->event_data.seek.type)
|
||||
#define GST_EVENT_SEEK_FORMAT(event) (GST_EVENT_SEEK_TYPE(event) & GST_SEEK_FORMAT_MASK)
|
||||
|
@ -165,49 +157,36 @@ GstFormatValue;
|
|||
|
||||
#define GST_EVENT_RATE_VALUE(event) (GST_EVENT(event)->event_data.rate.value)
|
||||
|
||||
struct _GstEvent
|
||||
{
|
||||
struct _GstEvent {
|
||||
GstData data;
|
||||
|
||||
GstEventType type;
|
||||
guint64 timestamp;
|
||||
GstObject *src;
|
||||
|
||||
union
|
||||
{
|
||||
struct
|
||||
{
|
||||
union {
|
||||
struct {
|
||||
GstSeekType type;
|
||||
gint64 offset;
|
||||
gint64 endoffset;
|
||||
GstSeekAccuracy accuracy;
|
||||
}
|
||||
seek;
|
||||
struct
|
||||
{
|
||||
} seek;
|
||||
struct {
|
||||
GstFormatValue offsets[8];
|
||||
gint noffsets;
|
||||
gboolean new_media;
|
||||
}
|
||||
discont;
|
||||
struct
|
||||
{
|
||||
} discont;
|
||||
struct {
|
||||
GstFormat format;
|
||||
gint64 value;
|
||||
}
|
||||
size;
|
||||
struct
|
||||
{
|
||||
} size;
|
||||
struct {
|
||||
gdouble value;
|
||||
}
|
||||
rate;
|
||||
struct
|
||||
{
|
||||
} rate;
|
||||
struct {
|
||||
GstStructure *structure;
|
||||
}
|
||||
structure;
|
||||
}
|
||||
event_data;
|
||||
} structure;
|
||||
} event_data;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
@ -224,14 +203,12 @@ GstEvent *gst_event_new (GstEventType type);
|
|||
/* copy buffer */
|
||||
#define gst_event_copy(ev) GST_EVENT (gst_data_copy (GST_DATA (ev)))
|
||||
|
||||
gboolean gst_event_masks_contains (const GstEventMask * masks,
|
||||
GstEventMask * mask);
|
||||
gboolean gst_event_masks_contains (const GstEventMask *masks, GstEventMask *mask);
|
||||
|
||||
/* seek event */
|
||||
GstEvent* gst_event_new_seek (GstSeekType type, gint64 offset);
|
||||
|
||||
GstEvent *gst_event_new_segment_seek (GstSeekType type, gint64 start,
|
||||
gint64 stop);
|
||||
GstEvent* gst_event_new_segment_seek (GstSeekType type, gint64 start, gint64 stop);
|
||||
|
||||
|
||||
/* size events */
|
||||
|
@ -241,9 +218,9 @@ GstEvent *gst_event_new_size (GstFormat format, gint64 value);
|
|||
GstEvent* gst_event_new_discontinuous (gboolean new_media,
|
||||
GstFormat format1, ...);
|
||||
GstEvent* gst_event_new_discontinuous_valist (gboolean new_media,
|
||||
GstFormat format1, va_list var_args);
|
||||
gboolean gst_event_discont_get_value (GstEvent * event, GstFormat format,
|
||||
gint64 * value);
|
||||
GstFormat format1,
|
||||
va_list var_args);
|
||||
gboolean gst_event_discont_get_value (GstEvent *event, GstFormat format, gint64 *value);
|
||||
|
||||
#define gst_event_new_filler() gst_event_new(GST_EVENT_FILLER)
|
||||
|
||||
|
@ -251,4 +228,5 @@ gboolean gst_event_discont_get_value (GstEvent * event, GstFormat format,
|
|||
#define gst_event_new_flush() gst_event_new(GST_EVENT_FLUSH)
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_EVENT_H__ */
|
||||
|
|
|
@ -23,10 +23,11 @@
|
|||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef gboolean (*GstFilterFunc) (gpointer obj, gpointer user_data);
|
||||
|
||||
GList *gst_filter_run (const GList * list, GstFilterFunc func, gboolean first,
|
||||
gpointer user_data);
|
||||
GList* gst_filter_run (const GList *list, GstFilterFunc func, gboolean first, gpointer user_data);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FILTER_H_ */
|
||||
|
|
|
@ -27,16 +27,16 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_FORMAT_UNDEFINED = 0, /* must be first in list */
|
||||
GST_FORMAT_DEFAULT = 1, /* samples for audio, frames/fields for video */
|
||||
GST_FORMAT_BYTES = 2,
|
||||
GST_FORMAT_TIME = 3,
|
||||
GST_FORMAT_BUFFERS = 4,
|
||||
GST_FORMAT_PERCENT = 5
|
||||
}
|
||||
GstFormat;
|
||||
} GstFormat;
|
||||
|
||||
/* a percentage is always relative to 1000000 */
|
||||
#define GST_FORMAT_PERCENT_MAX G_GINT64_CONSTANT (1000000)
|
||||
|
@ -78,15 +78,19 @@ functionname (type object) \
|
|||
void _gst_format_initialize (void);
|
||||
|
||||
/* register a new format */
|
||||
GstFormat gst_format_register (const gchar * nick, const gchar * description);
|
||||
GstFormat gst_format_register (const gchar *nick,
|
||||
const gchar *description);
|
||||
GstFormat gst_format_get_by_nick (const gchar *nick);
|
||||
|
||||
/* check if a format is in an array of formats */
|
||||
gboolean gst_formats_contains (const GstFormat *formats, GstFormat format);
|
||||
|
||||
/* query for format details */
|
||||
G_CONST_RETURN GstFormatDefinition *gst_format_get_details (GstFormat format);
|
||||
G_CONST_RETURN GList *gst_format_get_definitions (void);
|
||||
G_CONST_RETURN GstFormatDefinition*
|
||||
gst_format_get_details (GstFormat format);
|
||||
G_CONST_RETURN GList*
|
||||
gst_format_get_definitions (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_FORMAT_H__ */
|
||||
|
|
124
gst/gstindex.h
124
gst/gstindex.h
|
@ -29,42 +29,39 @@
|
|||
#include <gst/gstpluginfeature.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_INDEX (gst_index_get_type ())
|
||||
#define GST_INDEX(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_INDEX, GstIndex))
|
||||
#define GST_IS_INDEX(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_INDEX))
|
||||
#define GST_INDEX_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_INDEX, GstIndexClass))
|
||||
#define GST_IS_INDEX_CLASS(klass) (GST_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_INDEX))
|
||||
#define GST_INDEX_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_INDEX, GstIndexClass))
|
||||
|
||||
#define GST_TYPE_INDEX_ENTRY (gst_index_entry_get_type())
|
||||
|
||||
typedef struct _GstIndexEntry GstIndexEntry;
|
||||
typedef struct _GstIndexGroup GstIndexGroup;
|
||||
typedef struct _GstIndex GstIndex;
|
||||
typedef struct _GstIndexClass GstIndexClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_INDEX_UNKNOWN,
|
||||
GST_INDEX_CERTAIN,
|
||||
GST_INDEX_FUZZY
|
||||
}
|
||||
GstIndexCertainty;
|
||||
} GstIndexCertainty;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_INDEX_ENTRY_ID,
|
||||
GST_INDEX_ENTRY_ASSOCIATION,
|
||||
GST_INDEX_ENTRY_OBJECT,
|
||||
GST_INDEX_ENTRY_FORMAT
|
||||
}
|
||||
GstIndexEntryType;
|
||||
} GstIndexEntryType;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_INDEX_LOOKUP_EXACT,
|
||||
GST_INDEX_LOOKUP_BEFORE,
|
||||
GST_INDEX_LOOKUP_AFTER
|
||||
}
|
||||
GstIndexLookupMethod;
|
||||
} GstIndexLookupMethod;
|
||||
|
||||
#define GST_INDEX_NASSOCS(entry) ((entry)->data.assoc.nassocs)
|
||||
#define GST_INDEX_ASSOC_FLAGS(entry) ((entry)->data.assoc.flags)
|
||||
|
@ -73,21 +70,18 @@ GstIndexLookupMethod;
|
|||
|
||||
typedef struct _GstIndexAssociation GstIndexAssociation;
|
||||
|
||||
struct _GstIndexAssociation
|
||||
{
|
||||
struct _GstIndexAssociation {
|
||||
GstFormat format;
|
||||
gint64 value;
|
||||
};
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_ASSOCIATION_FLAG_NONE = 0,
|
||||
GST_ASSOCIATION_FLAG_KEY_UNIT = (1 << 0),
|
||||
|
||||
/* new flags should start here */
|
||||
GST_ASSOCIATION_FLAG_LAST = (1 << 8)
|
||||
}
|
||||
GstAssocFlags;
|
||||
} GstAssocFlags;
|
||||
|
||||
#define GST_INDEX_FORMAT_FORMAT(entry) ((entry)->data.format.format)
|
||||
#define GST_INDEX_FORMAT_KEY(entry) ((entry)->data.format.key)
|
||||
|
@ -96,44 +90,33 @@ GstAssocFlags;
|
|||
|
||||
#define GST_INDEX_ID_DESCRIPTION(entry) ((entry)->data.id.description)
|
||||
|
||||
struct _GstIndexEntry
|
||||
{
|
||||
struct _GstIndexEntry {
|
||||
GstIndexEntryType type;
|
||||
gint id;
|
||||
|
||||
union
|
||||
{
|
||||
struct
|
||||
{
|
||||
union {
|
||||
struct {
|
||||
gchar *description;
|
||||
}
|
||||
id;
|
||||
struct
|
||||
{
|
||||
} id;
|
||||
struct {
|
||||
gint nassocs;
|
||||
GstIndexAssociation * assocs;
|
||||
GstIndexAssociation
|
||||
*assocs;
|
||||
GstAssocFlags flags;
|
||||
}
|
||||
assoc;
|
||||
struct
|
||||
{
|
||||
} assoc;
|
||||
struct {
|
||||
gchar *key;
|
||||
GType type;
|
||||
gpointer object;
|
||||
}
|
||||
object;
|
||||
struct
|
||||
{
|
||||
} object;
|
||||
struct {
|
||||
GstFormat format;
|
||||
gchar *key;
|
||||
}
|
||||
format;
|
||||
}
|
||||
data;
|
||||
} format;
|
||||
} data;
|
||||
};
|
||||
|
||||
struct _GstIndexGroup
|
||||
{
|
||||
struct _GstIndexGroup {
|
||||
/* unique ID of group in index */
|
||||
gint groupnum;
|
||||
|
||||
|
@ -147,32 +130,30 @@ struct _GstIndexGroup
|
|||
gint peergroup;
|
||||
};
|
||||
|
||||
typedef gboolean (*GstIndexFilter) (GstIndex * index, GstIndexEntry * entry);
|
||||
typedef gboolean (*GstIndexFilter) (GstIndex *index,
|
||||
GstIndexEntry *entry);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_INDEX_RESOLVER_CUSTOM,
|
||||
GST_INDEX_RESOLVER_GTYPE,
|
||||
GST_INDEX_RESOLVER_PATH
|
||||
}
|
||||
GstIndexResolverMethod;
|
||||
} GstIndexResolverMethod;
|
||||
|
||||
typedef gboolean (*GstIndexResolver) (GstIndex *index,
|
||||
GstObject * writer, gchar ** writer_string, gpointer user_data);
|
||||
typedef enum
|
||||
{
|
||||
GstObject *writer,
|
||||
gchar **writer_string,
|
||||
gpointer user_data);
|
||||
typedef enum {
|
||||
GST_INDEX_WRITABLE = GST_OBJECT_FLAG_LAST,
|
||||
GST_INDEX_READABLE,
|
||||
|
||||
GST_INDEX_FLAG_LAST = GST_OBJECT_FLAG_LAST + 8
|
||||
}
|
||||
GstIndexFlags;
|
||||
} GstIndexFlags;
|
||||
|
||||
#define GST_INDEX_IS_READABLE(obj) (GST_FLAG_IS_SET (obj, GST_INDEX_READABLE))
|
||||
#define GST_INDEX_IS_WRITABLE(obj) (GST_FLAG_IS_SET (obj, GST_INDEX_WRITABLE))
|
||||
|
||||
struct _GstIndex
|
||||
{
|
||||
struct _GstIndex {
|
||||
GstObject object;
|
||||
|
||||
GList *groups;
|
||||
|
@ -192,12 +173,10 @@ struct _GstIndex
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstIndexClass
|
||||
{
|
||||
struct _GstIndexClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
gboolean (*get_writer_id) (GstIndex * index, gint * writer_id,
|
||||
gchar * writer_string);
|
||||
gboolean (*get_writer_id) (GstIndex *index, gint *writer_id, gchar *writer_string);
|
||||
|
||||
void (*commit) (GstIndex *index, gint id);
|
||||
|
||||
|
@ -207,7 +186,8 @@ struct _GstIndexClass
|
|||
GstIndexEntry* (*get_assoc_entry) (GstIndex *index, gint id,
|
||||
GstIndexLookupMethod method, GstAssocFlags flags,
|
||||
GstFormat format, gint64 value,
|
||||
GCompareDataFunc func, gpointer user_data);
|
||||
GCompareDataFunc func,
|
||||
gpointer user_data);
|
||||
/* signals */
|
||||
void (*entry_added) (GstIndex *index, GstIndexEntry *entry);
|
||||
|
||||
|
@ -222,7 +202,8 @@ gint gst_index_get_group (GstIndex * index);
|
|||
gint gst_index_new_group (GstIndex *index);
|
||||
gboolean gst_index_set_group (GstIndex *index, gint groupnum);
|
||||
|
||||
void gst_index_set_certainty (GstIndex * index, GstIndexCertainty certainty);
|
||||
void gst_index_set_certainty (GstIndex *index,
|
||||
GstIndexCertainty certainty);
|
||||
GstIndexCertainty gst_index_get_certainty (GstIndex *index);
|
||||
|
||||
void gst_index_set_filter (GstIndex *index,
|
||||
|
@ -230,13 +211,11 @@ void gst_index_set_filter (GstIndex * index,
|
|||
void gst_index_set_resolver (GstIndex *index,
|
||||
GstIndexResolver resolver, gpointer user_data);
|
||||
|
||||
gboolean gst_index_get_writer_id (GstIndex * index, GstObject * writer,
|
||||
gint * id);
|
||||
gboolean gst_index_get_writer_id (GstIndex *index, GstObject *writer, gint *id);
|
||||
|
||||
GstIndexEntry *gst_index_add_format (GstIndex * index, gint id,
|
||||
GstFormat format);
|
||||
GstIndexEntry *gst_index_add_association (GstIndex * index, gint id,
|
||||
GstAssocFlags flags, GstFormat format, gint64 value, ...);
|
||||
GstIndexEntry* gst_index_add_format (GstIndex *index, gint id, GstFormat format);
|
||||
GstIndexEntry* gst_index_add_association (GstIndex *index, gint id, GstAssocFlags flags,
|
||||
GstFormat format, gint64 value, ...);
|
||||
GstIndexEntry* gst_index_add_object (GstIndex *index, gint id, gchar *key,
|
||||
GType type, gpointer object);
|
||||
GstIndexEntry* gst_index_add_id (GstIndex *index, gint id,
|
||||
|
@ -247,7 +226,9 @@ GstIndexEntry *gst_index_get_assoc_entry (GstIndex * index, gint id,
|
|||
GstFormat format, gint64 value);
|
||||
GstIndexEntry* gst_index_get_assoc_entry_full (GstIndex *index, gint id,
|
||||
GstIndexLookupMethod method, GstAssocFlags flags,
|
||||
GstFormat format, gint64 value, GCompareDataFunc func, gpointer user_data);
|
||||
GstFormat format, gint64 value,
|
||||
GCompareDataFunc func,
|
||||
gpointer user_data);
|
||||
|
||||
/* working with index entries */
|
||||
GType gst_index_entry_get_type (void);
|
||||
|
@ -269,8 +250,7 @@ gboolean gst_index_entry_assoc_map (GstIndexEntry * entry,
|
|||
typedef struct _GstIndexFactory GstIndexFactory;
|
||||
typedef struct _GstIndexFactoryClass GstIndexFactoryClass;
|
||||
|
||||
struct _GstIndexFactory
|
||||
{
|
||||
struct _GstIndexFactory {
|
||||
GstPluginFeature feature;
|
||||
|
||||
gchar *longdesc; /* long description of the index (well, don't overdo it..) */
|
||||
|
@ -279,8 +259,7 @@ struct _GstIndexFactory
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstIndexFactoryClass
|
||||
{
|
||||
struct _GstIndexFactoryClass {
|
||||
GstPluginFeatureClass parent;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -298,4 +277,5 @@ GstIndex *gst_index_factory_create (GstIndexFactory * factory);
|
|||
GstIndex* gst_index_factory_make (const gchar *name);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_INDEX_H__ */
|
||||
|
|
|
@ -31,15 +31,16 @@
|
|||
#include <gst/gstconfig.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/*
|
||||
* GStreamer's debugging subsystem is an easy way to get information about what
|
||||
* the application is doing.
|
||||
* It is not meant for programming errors. Use GLibs methods (g_warning and so
|
||||
* on for that.
|
||||
*/
|
||||
|
||||
/* log levels */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_LEVEL_NONE = 0,
|
||||
GST_LEVEL_ERROR,
|
||||
GST_LEVEL_WARNING,
|
||||
|
@ -48,8 +49,7 @@ G_BEGIN_DECLS
|
|||
GST_LEVEL_LOG,
|
||||
/* add more */
|
||||
GST_LEVEL_COUNT
|
||||
}
|
||||
GstDebugLevel;
|
||||
} GstDebugLevel;
|
||||
|
||||
/* we can now override this to be more general in maintainer builds or cvs checkouts */
|
||||
#ifndef GST_LEVEL_DEFAULT
|
||||
|
@ -64,8 +64,7 @@ GstDebugLevel;
|
|||
* Background color codes:
|
||||
* 40=black 41=red 42=green 43=yellow 44=blue 45=magenta 46=cyan 47=white
|
||||
*/
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
/* colors */
|
||||
GST_DEBUG_FG_BLACK = 0x0000,
|
||||
GST_DEBUG_FG_RED = 0x0001,
|
||||
|
@ -87,16 +86,14 @@ typedef enum
|
|||
/* other formats */
|
||||
GST_DEBUG_BOLD = 0x0100,
|
||||
GST_DEBUG_UNDERLINE = 0x0200
|
||||
}
|
||||
GstDebugColorFlags;
|
||||
} GstDebugColorFlags;
|
||||
|
||||
#define GST_DEBUG_FG_MASK (0x000F)
|
||||
#define GST_DEBUG_BG_MASK (0x00F0)
|
||||
#define GST_DEBUG_FORMAT_MASK (0xFF00)
|
||||
|
||||
typedef struct _GstDebugCategory GstDebugCategory;
|
||||
struct _GstDebugCategory
|
||||
{
|
||||
struct _GstDebugCategory {
|
||||
/*< private >*/
|
||||
GstAtomicInt * threshold;
|
||||
guint color; /* see defines above */
|
||||
|
@ -134,7 +131,10 @@ typedef void (*GstLogFunction) (GstDebugCategory * category,
|
|||
GstDebugLevel level,
|
||||
const gchar * file,
|
||||
const gchar * function,
|
||||
gint line, GObject * object, GstDebugMessage * message, gpointer data);
|
||||
gint line,
|
||||
GObject * object,
|
||||
GstDebugMessage * message,
|
||||
gpointer data);
|
||||
|
||||
/* Disable this subsystem if no varargs macro can be found.
|
||||
Use a trick so the core builds the functions nonetheless if it wasn't
|
||||
|
@ -154,19 +154,22 @@ void _gst_debug_init (void);
|
|||
|
||||
/* note we can't use G_GNUC_PRINTF (7, 8) because gcc chokes on %P, which
|
||||
* we use for GST_PTR_FORMAT. */
|
||||
void
|
||||
gst_debug_log (GstDebugCategory * category,
|
||||
void gst_debug_log (GstDebugCategory * category,
|
||||
GstDebugLevel level,
|
||||
const gchar * file,
|
||||
const gchar * function,
|
||||
gint line, GObject * object, const gchar * format, ...)
|
||||
G_GNUC_NO_INSTRUMENT;
|
||||
gint line,
|
||||
GObject * object,
|
||||
const gchar * format,
|
||||
...) G_GNUC_NO_INSTRUMENT;
|
||||
void gst_debug_log_valist (GstDebugCategory * category,
|
||||
GstDebugLevel level,
|
||||
const gchar * file,
|
||||
const gchar * function,
|
||||
gint line,
|
||||
GObject * object, const gchar * format, va_list args) G_GNUC_NO_INSTRUMENT;
|
||||
GObject * object,
|
||||
const gchar * format,
|
||||
va_list args) G_GNUC_NO_INSTRUMENT;
|
||||
|
||||
const gchar * gst_debug_message_get (GstDebugMessage * message);
|
||||
|
||||
|
@ -176,11 +179,14 @@ gst_debug_log (GstDebugCategory * category,
|
|||
const gchar * function,
|
||||
gint line,
|
||||
GObject * object,
|
||||
GstDebugMessage * message, gpointer unused) G_GNUC_NO_INSTRUMENT;
|
||||
GstDebugMessage * message,
|
||||
gpointer unused) G_GNUC_NO_INSTRUMENT;
|
||||
|
||||
G_CONST_RETURN gchar *gst_debug_level_get_name (GstDebugLevel level);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_debug_level_get_name (GstDebugLevel level);
|
||||
|
||||
void gst_debug_add_log_function (GstLogFunction func, gpointer data);
|
||||
void gst_debug_add_log_function (GstLogFunction func,
|
||||
gpointer data);
|
||||
guint gst_debug_remove_log_function (GstLogFunction func);
|
||||
guint gst_debug_remove_log_function_by_data (gpointer data);
|
||||
|
||||
|
@ -222,7 +228,8 @@ gst_debug_log (GstDebugCategory * category,
|
|||
#define GST_DEBUG_CATEGORY_STATIC(cat) static GstDebugCategory *cat = NULL
|
||||
/* do not use this function, use the macros below */
|
||||
GstDebugCategory *_gst_debug_category_new (gchar * name,
|
||||
guint color, gchar * description);
|
||||
guint color,
|
||||
gchar * description);
|
||||
/**
|
||||
* GST_DEBUG_CATEGORY_INIT:
|
||||
* @cat: the category to initialize.
|
||||
|
@ -267,23 +274,20 @@ gst_debug_log (GstDebugCategory * category,
|
|||
void gst_debug_category_set_threshold (GstDebugCategory * category,
|
||||
GstDebugLevel level);
|
||||
void gst_debug_category_reset_threshold (GstDebugCategory * category);
|
||||
GstDebugLevel gst_debug_category_get_threshold (GstDebugCategory *
|
||||
category);
|
||||
G_CONST_RETURN gchar *gst_debug_category_get_name (GstDebugCategory *
|
||||
category);
|
||||
GstDebugLevel gst_debug_category_get_threshold (GstDebugCategory * category);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_debug_category_get_name (GstDebugCategory * category);
|
||||
guint gst_debug_category_get_color (GstDebugCategory * category);
|
||||
G_CONST_RETURN gchar *gst_debug_category_get_description (GstDebugCategory
|
||||
* category);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_debug_category_get_description (GstDebugCategory * category);
|
||||
GSList * gst_debug_get_all_categories (void);
|
||||
|
||||
gchar * gst_debug_construct_term_color (guint colorinfo);
|
||||
|
||||
|
||||
extern GstDebugCategory * GST_CAT_DEFAULT;
|
||||
|
||||
/* this symbol may not be used */
|
||||
extern gboolean __gst_debug_enabled;
|
||||
|
||||
#ifdef G_HAVE_ISO_VARARGS
|
||||
#define GST_CAT_LEVEL_LOG(cat,level,object,...) G_STMT_START{ \
|
||||
if (__gst_debug_enabled) { \
|
||||
|
@ -382,8 +386,10 @@ gst_debug_log (GstDebugCategory * category,
|
|||
|
||||
|
||||
/********** function pointer stuff **********/
|
||||
void *_gst_debug_register_funcptr (void *ptr, gchar * ptrname);
|
||||
G_CONST_RETURN gchar *_gst_debug_nameof_funcptr (void *ptr);
|
||||
void* _gst_debug_register_funcptr (void * ptr,
|
||||
gchar * ptrname);
|
||||
G_CONST_RETURN gchar*
|
||||
_gst_debug_nameof_funcptr (void * ptr);
|
||||
|
||||
#define GST_DEBUG_FUNCPTR(ptr) (_gst_debug_register_funcptr((void *)(ptr), #ptr) , ptr)
|
||||
#define GST_DEBUG_FUNCPTR_NAME(ptr) _gst_debug_nameof_funcptr((void *)ptr)
|
||||
|
@ -517,4 +523,5 @@ gst_debug_log (GstDebugCategory * category,
|
|||
void gst_debug_print_stack_trace (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GSTINFO_H__ */
|
||||
|
|
|
@ -26,6 +26,7 @@
|
|||
#include <gst/gstelement.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_IMPLEMENTS_INTERFACE \
|
||||
(gst_implements_interface_get_type ())
|
||||
#define GST_IMPLEMENTS_INTERFACE(obj) \
|
||||
|
@ -41,22 +42,22 @@ G_BEGIN_DECLS
|
|||
#define GST_IMPLEMENTS_INTERFACE_GET_CLASS(inst) \
|
||||
(G_TYPE_INSTANCE_GET_INTERFACE ((inst), GST_TYPE_IMPLEMENTS_INTERFACE, \
|
||||
GstImplementsInterfaceClass))
|
||||
|
||||
typedef struct _GstImplementsInterface GstImplementsInterface;
|
||||
|
||||
/* This small extra virtual function is here to provide an
|
||||
* interface functionality on a per-instance basis rather
|
||||
* than a per-class basis, which is the case for glib.
|
||||
*/
|
||||
typedef struct _GstImplementsInterfaceClass
|
||||
{
|
||||
typedef struct _GstImplementsInterfaceClass {
|
||||
GTypeInterface parent;
|
||||
|
||||
/* virtual functions */
|
||||
gboolean (*supported) (GstImplementsInterface * iface, GType iface_type);
|
||||
gboolean (* supported) (GstImplementsInterface *iface,
|
||||
GType iface_type);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
}
|
||||
GstImplementsInterfaceClass;
|
||||
} GstImplementsInterfaceClass;
|
||||
|
||||
#define GST_IMPLEMENTS_INTERFACE_CHECK_INSTANCE_CAST(obj, type, cast_t) \
|
||||
((cast_t *) gst_implements_interface_cast ((obj), (type)))
|
||||
|
@ -68,8 +69,11 @@ GType gst_implements_interface_get_type (void);
|
|||
/* wrapper functions to check for functionality implementation */
|
||||
gboolean gst_element_implements_interface (GstElement *element,
|
||||
GType iface_type);
|
||||
gpointer gst_implements_interface_cast (gpointer from, GType type);
|
||||
gboolean gst_implements_interface_check (gpointer from, GType type);
|
||||
gpointer gst_implements_interface_cast (gpointer from,
|
||||
GType type);
|
||||
gboolean gst_implements_interface_check (gpointer from,
|
||||
GType type);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_IMPLEMENTS_INTERFACE_H__ */
|
||||
|
|
|
@ -25,7 +25,9 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS extern const char *g_log_domain_gstreamer;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
extern const char *g_log_domain_gstreamer;
|
||||
|
||||
#ifdef G_HAVE_ISO_VARARGS
|
||||
|
||||
|
@ -49,4 +51,5 @@ G_BEGIN_DECLS extern const char *g_log_domain_gstreamer;
|
|||
#endif
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_LOG_H__ */
|
||||
|
|
|
@ -21,12 +21,14 @@
|
|||
#define __GST_MACROS_H__
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ > 4)
|
||||
# define GST_GNUC_CONSTRUCTOR \
|
||||
__attribute__ ((constructor))
|
||||
#else /* !__GNUC__ */
|
||||
# define GST_GNUC_CONSTRUCTOR
|
||||
#endif /* !__GNUC__ */
|
||||
|
||||
#if defined (__GNUC__) && !defined (GST_IMPLEMENT_INLINES)
|
||||
# define GST_INLINE_FUNC extern __inline__
|
||||
# define GST_CAN_INLINE 1
|
||||
|
@ -34,5 +36,9 @@ G_BEGIN_DECLS
|
|||
# define GST_INLINE_FUNC extern
|
||||
# undef GST_CAN_INLINE
|
||||
#endif
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MACROS_H__ */
|
||||
|
||||
|
||||
|
|
|
@ -22,16 +22,22 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstMemChunk GstMemChunk;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstMemChunk GstMemChunk;
|
||||
|
||||
GstMemChunk* gst_mem_chunk_new (gchar *name,
|
||||
gint atom_size, gulong area_size, gint type);
|
||||
gint atom_size,
|
||||
gulong area_size,
|
||||
gint type);
|
||||
|
||||
void gst_mem_chunk_destroy (GstMemChunk *mem_chunk);
|
||||
|
||||
gpointer gst_mem_chunk_alloc (GstMemChunk *mem_chunk);
|
||||
gpointer gst_mem_chunk_alloc0 (GstMemChunk *mem_chunk);
|
||||
void gst_mem_chunk_free (GstMemChunk * mem_chunk, gpointer mem);
|
||||
void gst_mem_chunk_free (GstMemChunk *mem_chunk,
|
||||
gpointer mem);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_MEM_CHUNK_H__ */
|
||||
|
|
|
@ -30,7 +30,9 @@
|
|||
|
||||
#include <gst/gsttypes.h>
|
||||
|
||||
G_BEGIN_DECLS extern GType _gst_object_type;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
extern GType _gst_object_type;
|
||||
|
||||
#define GST_TYPE_OBJECT (_gst_object_type)
|
||||
#define GST_IS_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_OBJECT))
|
||||
|
@ -51,11 +53,9 @@ typedef enum
|
|||
GST_FLOATING,
|
||||
|
||||
GST_OBJECT_FLAG_LAST = 4
|
||||
}
|
||||
GstObjectFlags;
|
||||
} GstObjectFlags;
|
||||
|
||||
struct _GstObject
|
||||
{
|
||||
struct _GstObject {
|
||||
GObject object;
|
||||
|
||||
gchar *name;
|
||||
|
@ -71,8 +71,7 @@ struct _GstObject
|
|||
};
|
||||
|
||||
/* signal_object is used to signal to the whole class */
|
||||
struct _GstObjectClass
|
||||
{
|
||||
struct _GstObjectClass {
|
||||
GObjectClass parent_class;
|
||||
|
||||
gchar *path_string_separator;
|
||||
|
@ -82,8 +81,7 @@ struct _GstObjectClass
|
|||
void (*parent_set) (GstObject *object, GstObject *parent);
|
||||
void (*parent_unset) (GstObject *object, GstObject *parent);
|
||||
void (*object_saved) (GstObject *object, xmlNodePtr parent);
|
||||
void (*deep_notify) (GstObject * object, GstObject * orig,
|
||||
GParamSpec * pspec);
|
||||
void (*deep_notify) (GstObject *object, GstObject *orig, GParamSpec *pspec);
|
||||
|
||||
/* functions go here */
|
||||
void (*destroy) (GstObject *object);
|
||||
|
@ -117,7 +115,8 @@ GType gst_object_get_type (void);
|
|||
|
||||
/* name routines */
|
||||
void gst_object_set_name (GstObject *object, const gchar *name);
|
||||
G_CONST_RETURN gchar *gst_object_get_name (GstObject * object);
|
||||
G_CONST_RETURN gchar*
|
||||
gst_object_get_name (GstObject *object);
|
||||
|
||||
/* parentage routines */
|
||||
void gst_object_set_parent (GstObject *object, GstObject *parent);
|
||||
|
@ -149,15 +148,20 @@ void gst_object_replace (GstObject ** oldobj, GstObject * newobj);
|
|||
gchar * gst_object_get_path_string (GstObject *object);
|
||||
|
||||
guint gst_class_signal_connect (GstObjectClass *klass,
|
||||
const gchar * name, gpointer func, gpointer func_data);
|
||||
const gchar *name,
|
||||
gpointer func,
|
||||
gpointer func_data);
|
||||
|
||||
#ifndef GST_DISABLE_LOADSAVE_REGISTRY
|
||||
void gst_class_signal_emit_by_name (GstObject *object,
|
||||
const gchar * name, xmlNodePtr self);
|
||||
const gchar *name,
|
||||
xmlNodePtr self);
|
||||
#else
|
||||
#pragma GCC poison gst_class_signal_emit_by_name
|
||||
#endif
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_OBJECT_H__ */
|
||||
|
||||
|
|
134
gst/gstpad.h
134
gst/gstpad.h
|
@ -34,7 +34,9 @@
|
|||
#include <gst/gstquery.h>
|
||||
|
||||
|
||||
G_BEGIN_DECLS extern GType _gst_pad_type;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
extern GType _gst_pad_type;
|
||||
extern GType _gst_real_pad_type;
|
||||
extern GType _gst_ghost_pad_type;
|
||||
|
||||
|
@ -76,20 +78,17 @@ typedef struct _GstRealPad GstRealPad;
|
|||
typedef struct _GstRealPadClass GstRealPadClass;
|
||||
typedef struct _GstGhostPad GstGhostPad;
|
||||
typedef struct _GstGhostPadClass GstGhostPadClass;
|
||||
|
||||
/*typedef struct _GstPadTemplate GstPadTemplate;*/
|
||||
/*typedef struct _GstPadTemplateClass GstPadTemplateClass;*/
|
||||
typedef struct _GstStaticPadTemplate GstStaticPadTemplate;
|
||||
typedef struct _GstPadLink GstPadLink;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_PAD_LINK_REFUSED = -1,
|
||||
GST_PAD_LINK_DELAYED = 0,
|
||||
GST_PAD_LINK_OK = 1,
|
||||
GST_PAD_LINK_DONE = 2
|
||||
}
|
||||
GstPadLinkReturn;
|
||||
} GstPadLinkReturn;
|
||||
|
||||
#define GST_PAD_LINK_FAILED(ret) (ret < GST_PAD_LINK_OK)
|
||||
#define GST_PAD_LINK_SUCCESSFUL(ret) (ret >= GST_PAD_LINK_OK)
|
||||
|
@ -124,35 +123,28 @@ typedef const GstFormat *(*GstPadFormatsFunction) (GstPad * pad);
|
|||
typedef const GstEventMask* (*GstPadEventMaskFunction) (GstPad *pad);
|
||||
typedef const GstQueryType* (*GstPadQueryTypeFunction) (GstPad *pad);
|
||||
|
||||
typedef GstPadLinkReturn (*GstPadLinkFunction) (GstPad * pad,
|
||||
const GstCaps * caps);
|
||||
typedef GstPadLinkReturn (*GstPadLinkFunction) (GstPad *pad, const GstCaps *caps);
|
||||
typedef void (*GstPadUnlinkFunction) (GstPad *pad);
|
||||
typedef GstCaps* (*GstPadGetCapsFunction) (GstPad *pad);
|
||||
typedef GstCaps* (*GstPadFixateFunction) (GstPad *pad, const GstCaps *caps);
|
||||
typedef GstBuffer *(*GstPadBufferAllocFunction) (GstPad * pad, guint64 offset,
|
||||
guint size);
|
||||
typedef GstBuffer* (*GstPadBufferAllocFunction) (GstPad *pad, guint64 offset, guint size);
|
||||
|
||||
typedef gboolean (*GstPadDispatcherFunction) (GstPad *pad, gpointer data);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_PAD_UNKNOWN,
|
||||
GST_PAD_SRC,
|
||||
GST_PAD_SINK
|
||||
}
|
||||
GstPadDirection;
|
||||
} GstPadDirection;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_PAD_DISABLED = GST_OBJECT_FLAG_LAST,
|
||||
GST_PAD_NEGOTIATING,
|
||||
|
||||
GST_PAD_FLAG_LAST = GST_OBJECT_FLAG_LAST + 4
|
||||
}
|
||||
GstPadFlags;
|
||||
} GstPadFlags;
|
||||
|
||||
struct _GstPad
|
||||
{
|
||||
struct _GstPad {
|
||||
GstObject object;
|
||||
|
||||
gpointer element_private;
|
||||
|
@ -162,15 +154,13 @@ struct _GstPad
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstPadClass
|
||||
{
|
||||
struct _GstPadClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstRealPad
|
||||
{
|
||||
struct _GstRealPad {
|
||||
GstPad pad;
|
||||
|
||||
/* the pad capabilities */
|
||||
|
@ -216,8 +206,7 @@ struct _GstRealPad
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstRealPadClass
|
||||
{
|
||||
struct _GstRealPadClass {
|
||||
GstPadClass parent_class;
|
||||
|
||||
/* signal callbacks */
|
||||
|
@ -230,8 +219,7 @@ struct _GstRealPadClass
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstGhostPad
|
||||
{
|
||||
struct _GstGhostPad {
|
||||
GstPad pad;
|
||||
|
||||
GstRealPad *realpad;
|
||||
|
@ -239,8 +227,7 @@ struct _GstGhostPad
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstGhostPadClass
|
||||
{
|
||||
struct _GstGhostPadClass {
|
||||
GstPadClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -306,31 +293,26 @@ struct _GstGhostPadClass
|
|||
#define GST_IS_PAD_TEMPLATE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_PAD_TEMPLATE))
|
||||
#define GST_IS_PAD_TEMPLATE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_PAD_TEMPLATE))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_PAD_ALWAYS,
|
||||
GST_PAD_SOMETIMES,
|
||||
GST_PAD_REQUEST
|
||||
}
|
||||
GstPadPresence;
|
||||
} GstPadPresence;
|
||||
|
||||
#define GST_PAD_TEMPLATE_NAME_TEMPLATE(templ) (((GstPadTemplate *)(templ))->name_template)
|
||||
#define GST_PAD_TEMPLATE_DIRECTION(templ) (((GstPadTemplate *)(templ))->direction)
|
||||
#define GST_PAD_TEMPLATE_PRESENCE(templ) (((GstPadTemplate *)(templ))->presence)
|
||||
#define GST_PAD_TEMPLATE_CAPS(templ) (((GstPadTemplate *)(templ))->caps)
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_PAD_TEMPLATE_FIXED = GST_OBJECT_FLAG_LAST,
|
||||
|
||||
GST_PAD_TEMPLATE_FLAG_LAST = GST_OBJECT_FLAG_LAST + 4
|
||||
}
|
||||
GstPadTemplateFlags;
|
||||
} GstPadTemplateFlags;
|
||||
|
||||
#define GST_PAD_TEMPLATE_IS_FIXED(templ) (GST_FLAG_IS_SET(templ, GST_PAD_TEMPLATE_FIXED))
|
||||
|
||||
struct _GstPadTemplate
|
||||
{
|
||||
struct _GstPadTemplate {
|
||||
GstObject object;
|
||||
|
||||
gchar *name_template;
|
||||
|
@ -341,8 +323,7 @@ struct _GstPadTemplate
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstPadTemplateClass
|
||||
{
|
||||
struct _GstPadTemplateClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* signal callbacks */
|
||||
|
@ -351,8 +332,7 @@ struct _GstPadTemplateClass
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstStaticPadTemplate
|
||||
{
|
||||
struct _GstStaticPadTemplate {
|
||||
gchar *name_template;
|
||||
GstPadDirection direction;
|
||||
GstPadPresence presence;
|
||||
|
@ -375,10 +355,8 @@ GType gst_ghost_pad_get_type (void);
|
|||
/* creating pads */
|
||||
GstPad* gst_pad_new (const gchar *name, GstPadDirection direction);
|
||||
GstPad* gst_pad_new_from_template (GstPadTemplate *templ, const gchar *name);
|
||||
GstPad *gst_pad_custom_new (GType type, const gchar * name,
|
||||
GstPadDirection direction);
|
||||
GstPad *gst_pad_custom_new_from_template (GType type, GstPadTemplate * templ,
|
||||
const gchar * name);
|
||||
GstPad* gst_pad_custom_new (GType type, const gchar *name, GstPadDirection direction);
|
||||
GstPad* gst_pad_custom_new_from_template (GType type, GstPadTemplate *templ, const gchar *name);
|
||||
|
||||
void gst_pad_set_name (GstPad *pad, const gchar *name);
|
||||
G_CONST_RETURN gchar* gst_pad_get_name (GstPad *pad);
|
||||
|
@ -403,29 +381,27 @@ GList *gst_pad_get_ghost_pad_list (GstPad * pad);
|
|||
|
||||
GstPadTemplate* gst_pad_get_pad_template (GstPad *pad);
|
||||
|
||||
void gst_pad_set_bufferalloc_function (GstPad * pad,
|
||||
GstPadBufferAllocFunction bufferalloc);
|
||||
void gst_pad_set_bufferalloc_function (GstPad *pad, GstPadBufferAllocFunction bufferalloc);
|
||||
GstBuffer* gst_pad_alloc_buffer (GstPad *pad, guint64 offset, gint size);
|
||||
|
||||
/* data passing setup functions */
|
||||
void gst_pad_set_chain_function (GstPad *pad, GstPadChainFunction chain);
|
||||
void gst_pad_set_get_function (GstPad *pad, GstPadGetFunction get);
|
||||
void gst_pad_set_event_function (GstPad *pad, GstPadEventFunction event);
|
||||
void gst_pad_set_event_mask_function (GstPad * pad,
|
||||
GstPadEventMaskFunction mask_func);
|
||||
G_CONST_RETURN GstEventMask *gst_pad_get_event_masks (GstPad * pad);
|
||||
G_CONST_RETURN GstEventMask *gst_pad_get_event_masks_default (GstPad * pad);
|
||||
void gst_pad_set_event_mask_function (GstPad *pad, GstPadEventMaskFunction mask_func);
|
||||
G_CONST_RETURN GstEventMask*
|
||||
gst_pad_get_event_masks (GstPad *pad);
|
||||
G_CONST_RETURN GstEventMask*
|
||||
gst_pad_get_event_masks_default (GstPad *pad);
|
||||
|
||||
/* pad links */
|
||||
void gst_pad_set_link_function (GstPad *pad, GstPadLinkFunction link);
|
||||
gboolean gst_pad_can_link (GstPad *srcpad, GstPad *sinkpad);
|
||||
gboolean gst_pad_can_link_filtered (GstPad * srcpad, GstPad * sinkpad,
|
||||
const GstCaps * filtercaps);
|
||||
gboolean gst_pad_can_link_filtered (GstPad *srcpad, GstPad *sinkpad, const GstCaps *filtercaps);
|
||||
void gst_pad_set_unlink_function (GstPad *pad, GstPadUnlinkFunction unlink);
|
||||
|
||||
gboolean gst_pad_link (GstPad *srcpad, GstPad *sinkpad);
|
||||
gboolean gst_pad_link_filtered (GstPad * srcpad, GstPad * sinkpad,
|
||||
const GstCaps * filtercaps);
|
||||
gboolean gst_pad_link_filtered (GstPad *srcpad, GstPad *sinkpad, const GstCaps *filtercaps);
|
||||
void gst_pad_unlink (GstPad *srcpad, GstPad *sinkpad);
|
||||
gboolean gst_pad_is_linked (GstPad *pad);
|
||||
|
||||
|
@ -437,8 +413,7 @@ gboolean gst_pad_is_negotiated (GstPad * pad);
|
|||
GstCaps* gst_pad_get_caps (GstPad *pad);
|
||||
G_CONST_RETURN GstCaps* gst_pad_get_pad_template_caps (GstPad *pad);
|
||||
GstPadLinkReturn gst_pad_try_set_caps (GstPad *pad, const GstCaps *caps);
|
||||
GstPadLinkReturn gst_pad_try_set_caps_nonfixed (GstPad * pad,
|
||||
const GstCaps * caps);
|
||||
GstPadLinkReturn gst_pad_try_set_caps_nonfixed (GstPad *pad, const GstCaps *caps);
|
||||
gboolean gst_pad_check_compatibility (GstPad *srcpad, GstPad *sinkpad);
|
||||
|
||||
void gst_pad_set_getcaps_function (GstPad *pad, GstPadGetCapsFunction getcaps);
|
||||
|
@ -446,21 +421,18 @@ void gst_pad_set_fixate_function (GstPad * pad, GstPadFixateFunction fixate);
|
|||
GstCaps * gst_pad_proxy_getcaps (GstPad *pad);
|
||||
GstPadLinkReturn gst_pad_proxy_pad_link (GstPad *pad, const GstCaps *caps);
|
||||
GstCaps * gst_pad_proxy_fixate (GstPad *pad, const GstCaps *caps);
|
||||
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
GstPadLinkReturn gst_pad_proxy_link (GstPad *pad, const GstCaps *caps);
|
||||
#endif
|
||||
gboolean gst_pad_set_explicit_caps (GstPad *pad, const GstCaps *caps);
|
||||
void gst_pad_use_explicit_caps (GstPad *pad);
|
||||
gboolean gst_pad_relink_filtered (GstPad * srcpad, GstPad * sinkpad,
|
||||
const GstCaps * filtercaps);
|
||||
gboolean gst_pad_relink_filtered (GstPad *srcpad, GstPad *sinkpad, const GstCaps *filtercaps);
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_pad_perform_negotiate (GstPad *srcpad, GstPad *sinkpad);
|
||||
#endif
|
||||
GstPadLinkReturn gst_pad_renegotiate (GstPad *pad);
|
||||
void gst_pad_unnegotiate (GstPad *pad);
|
||||
gboolean gst_pad_try_relink_filtered (GstPad * srcpad, GstPad * sinkpad,
|
||||
const GstCaps * filtercaps);
|
||||
gboolean gst_pad_try_relink_filtered (GstPad *srcpad, GstPad *sinkpad, const GstCaps *filtercaps);
|
||||
GstCaps* gst_pad_get_allowed_caps (GstPad *pad);
|
||||
void gst_pad_caps_change_notify (GstPad *pad);
|
||||
|
||||
|
@ -477,9 +449,12 @@ GstPad *gst_pad_select_valist (GstPad * pad, va_list varargs);
|
|||
|
||||
|
||||
/* convert/query/format functions */
|
||||
void gst_pad_set_formats_function (GstPad * pad, GstPadFormatsFunction formats);
|
||||
G_CONST_RETURN GstFormat *gst_pad_get_formats (GstPad * pad);
|
||||
G_CONST_RETURN GstFormat *gst_pad_get_formats_default (GstPad * pad);
|
||||
void gst_pad_set_formats_function (GstPad *pad,
|
||||
GstPadFormatsFunction formats);
|
||||
G_CONST_RETURN GstFormat*
|
||||
gst_pad_get_formats (GstPad *pad);
|
||||
G_CONST_RETURN GstFormat*
|
||||
gst_pad_get_formats_default (GstPad *pad);
|
||||
|
||||
void gst_pad_set_convert_function (GstPad *pad, GstPadConvertFunction convert);
|
||||
gboolean gst_pad_convert (GstPad *pad,
|
||||
|
@ -490,17 +465,17 @@ gboolean gst_pad_convert_default (GstPad * pad,
|
|||
GstFormat *dest_format, gint64 *dest_value);
|
||||
|
||||
void gst_pad_set_query_function (GstPad *pad, GstPadQueryFunction query);
|
||||
void gst_pad_set_query_type_function (GstPad * pad,
|
||||
GstPadQueryTypeFunction type_func);
|
||||
G_CONST_RETURN GstQueryType *gst_pad_get_query_types (GstPad * pad);
|
||||
G_CONST_RETURN GstQueryType *gst_pad_get_query_types_default (GstPad * pad);
|
||||
void gst_pad_set_query_type_function (GstPad *pad, GstPadQueryTypeFunction type_func);
|
||||
G_CONST_RETURN GstQueryType*
|
||||
gst_pad_get_query_types (GstPad *pad);
|
||||
G_CONST_RETURN GstQueryType*
|
||||
gst_pad_get_query_types_default (GstPad *pad);
|
||||
gboolean gst_pad_query (GstPad *pad, GstQueryType type,
|
||||
GstFormat *format, gint64 *value);
|
||||
gboolean gst_pad_query_default (GstPad *pad, GstQueryType type,
|
||||
GstFormat *format, gint64 *value);
|
||||
|
||||
void gst_pad_set_internal_link_function (GstPad * pad,
|
||||
GstPadIntLinkFunction intlink);
|
||||
void gst_pad_set_internal_link_function (GstPad *pad, GstPadIntLinkFunction intlink);
|
||||
GList* gst_pad_get_internal_links (GstPad *pad);
|
||||
GList* gst_pad_get_internal_links_default (GstPad *pad);
|
||||
|
||||
|
@ -526,16 +501,19 @@ GstPad *gst_ghost_pad_new (const gchar * name, GstPad * pad);
|
|||
GType gst_pad_template_get_type (void);
|
||||
|
||||
GstPadTemplate* gst_pad_template_new (const gchar *name_template,
|
||||
GstPadDirection direction, GstPadPresence presence, GstCaps * caps);
|
||||
GstPadDirection direction, GstPadPresence presence,
|
||||
GstCaps *caps);
|
||||
|
||||
GstPadTemplate * gst_static_pad_template_get (GstStaticPadTemplate *templ);
|
||||
const GstCaps* gst_pad_template_get_caps (GstPadTemplate *templ);
|
||||
const GstCaps *gst_pad_template_get_caps_by_name (GstPadTemplate * templ,
|
||||
const gchar * name);
|
||||
const GstCaps* gst_pad_template_get_caps_by_name (GstPadTemplate *templ, const gchar *name);
|
||||
|
||||
#ifndef GST_DISABLE_LOADSAVE
|
||||
xmlNodePtr gst_ghost_pad_save_thyself (GstPad * pad, xmlNodePtr parent);
|
||||
xmlNodePtr gst_ghost_pad_save_thyself (GstPad *pad,
|
||||
xmlNodePtr parent);
|
||||
#endif
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_PAD_H__ */
|
||||
|
|
|
@ -26,9 +26,10 @@
|
|||
#include <gst/gstbin.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
#ifndef GST_DISABLE_PARSE
|
||||
GQuark gst_parse_error_quark (void);
|
||||
|
||||
#ifndef GST_DISABLE_PARSE
|
||||
|
||||
GQuark gst_parse_error_quark (void);
|
||||
#define GST_PARSE_ERROR gst_parse_error_quark ()
|
||||
|
||||
typedef enum
|
||||
|
@ -40,17 +41,19 @@ typedef enum
|
|||
GST_PARSE_ERROR_COULD_NOT_SET_PROPERTY,
|
||||
GST_PARSE_ERROR_EMPTY_BIN,
|
||||
GST_PARSE_ERROR_EMPTY
|
||||
}
|
||||
GstParseError;
|
||||
} GstParseError;
|
||||
|
||||
|
||||
GstElement *gst_parse_launch (const gchar * pipeline_description,
|
||||
GError ** error);
|
||||
GstElement* gst_parse_launch (const gchar *pipeline_description, GError **error);
|
||||
GstElement* gst_parse_launchv (const gchar **argv, GError **error);
|
||||
|
||||
#else /* GST_DISABLE_PARSE */
|
||||
|
||||
#pragma GCC poison gst_parse_launch
|
||||
#pragma GCC poison gst_parse_launchv
|
||||
|
||||
#endif /* GST_DISABLE_PARSE */
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PARSE_H__ */
|
||||
|
|
|
@ -27,24 +27,24 @@
|
|||
#include <gst/gstbin.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_PIPELINE (gst_pipeline_get_type ())
|
||||
#define GST_PIPELINE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_PIPELINE, GstPipeline))
|
||||
#define GST_IS_PIPELINE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_PIPELINE))
|
||||
#define GST_PIPELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_PIPELINE, GstPipelineClass))
|
||||
#define GST_IS_PIPELINE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_PIPELINE))
|
||||
#define GST_PIPELINE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_PIPELINE, GstPipelineClass))
|
||||
|
||||
typedef struct _GstPipeline GstPipeline;
|
||||
typedef struct _GstPipelineClass GstPipelineClass;
|
||||
|
||||
struct _GstPipeline
|
||||
{
|
||||
struct _GstPipeline {
|
||||
GstBin bin;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstPipelineClass
|
||||
{
|
||||
struct _GstPipelineClass {
|
||||
GstBinClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -55,4 +55,6 @@ GstElement *gst_pipeline_new (const gchar * name);
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PIPELINE_H__ */
|
||||
|
||||
|
|
|
@ -30,8 +30,9 @@
|
|||
#include <gst/gstpluginfeature.h>
|
||||
#include <gst/gstmacros.h>
|
||||
|
||||
G_BEGIN_DECLS GQuark gst_plugin_error_quark (void);
|
||||
G_BEGIN_DECLS
|
||||
|
||||
GQuark gst_plugin_error_quark (void);
|
||||
#define GST_PLUGIN_ERROR gst_plugin_error_quark ()
|
||||
|
||||
typedef enum
|
||||
|
@ -39,8 +40,7 @@ typedef enum
|
|||
GST_PLUGIN_ERROR_MODULE,
|
||||
GST_PLUGIN_ERROR_DEPENDENCIES,
|
||||
GST_PLUGIN_ERROR_NAME_MISMATCH
|
||||
}
|
||||
GstPluginError;
|
||||
} GstPluginError;
|
||||
|
||||
#define GST_PLUGIN(plugin) ((GstPlugin *) (plugin))
|
||||
|
||||
|
@ -49,12 +49,10 @@ typedef struct _GstPluginDesc GstPluginDesc;
|
|||
|
||||
/* Initialiser function: returns TRUE if plugin initialised successfully */
|
||||
typedef gboolean (*GstPluginInitFunc) (GstPlugin *plugin);
|
||||
|
||||
/* exiting function when plugin is unloaded */
|
||||
typedef void (*GstPluginExitFunc) (GstPlugin *plugin);
|
||||
|
||||
struct _GstPluginDesc
|
||||
{
|
||||
struct _GstPluginDesc {
|
||||
gint major_version; /* major version of core that plugin was compiled for */
|
||||
gint minor_version; /* minor version of core that plugin was compiled for */
|
||||
gchar *name; /* unique name of plugin */
|
||||
|
@ -69,8 +67,7 @@ struct _GstPluginDesc
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstPlugin
|
||||
{
|
||||
struct _GstPlugin {
|
||||
GstPluginDesc desc;
|
||||
|
||||
gchar * filename;
|
||||
|
@ -122,7 +119,8 @@ _gst_plugin_static_init__ ##init (void) \
|
|||
|
||||
|
||||
/* function for filters */
|
||||
typedef gboolean (*GstPluginFilter) (GstPlugin * plugin, gpointer user_data);
|
||||
typedef gboolean (*GstPluginFilter) (GstPlugin *plugin,
|
||||
gpointer user_data);
|
||||
|
||||
#define GST_TYPE_PLUGIN (gst_plugin_get_type())
|
||||
GType gst_plugin_get_type (void);
|
||||
|
@ -139,14 +137,17 @@ GModule *gst_plugin_get_module (GstPlugin * plugin);
|
|||
gboolean gst_plugin_is_loaded (GstPlugin *plugin);
|
||||
|
||||
GList* gst_plugin_feature_filter (GstPlugin *plugin,
|
||||
GstPluginFeatureFilter filter, gboolean first, gpointer user_data);
|
||||
GstPluginFeatureFilter filter,
|
||||
gboolean first,
|
||||
gpointer user_data);
|
||||
GList* gst_plugin_list_feature_filter (GList *list,
|
||||
GstPluginFeatureFilter filter, gboolean first, gpointer user_data);
|
||||
GstPluginFeatureFilter filter,
|
||||
gboolean first,
|
||||
gpointer user_data);
|
||||
gboolean gst_plugin_name_filter (GstPlugin *plugin, const gchar *name);
|
||||
|
||||
GList* gst_plugin_get_feature_list (GstPlugin *plugin);
|
||||
GstPluginFeature *gst_plugin_find_feature (GstPlugin * plugin,
|
||||
const gchar * name, GType type);
|
||||
GstPluginFeature* gst_plugin_find_feature (GstPlugin *plugin, const gchar *name, GType type);
|
||||
|
||||
GstPlugin * gst_plugin_load_file (const gchar *filename, GError** error);
|
||||
gboolean gst_plugin_unload_plugin (GstPlugin *plugin);
|
||||
|
@ -158,4 +159,5 @@ gboolean gst_plugin_load (const gchar * name);
|
|||
gboolean gst_library_load (const gchar *name);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_PLUGIN_H__ */
|
||||
|
|
|
@ -28,18 +28,20 @@
|
|||
#include <gst/gsttypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_PLUGIN_FEATURE (gst_plugin_feature_get_type())
|
||||
#define GST_PLUGIN_FEATURE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_PLUGIN_FEATURE, GstPluginFeature))
|
||||
#define GST_IS_PLUGIN_FEATURE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_PLUGIN_FEATURE))
|
||||
#define GST_PLUGIN_FEATURE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_PLUGIN_FEATURE, GstPluginFeatureClass))
|
||||
#define GST_IS_PLUGIN_FEATURE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_PLUGIN_FEATURE))
|
||||
#define GST_PLUGIN_FEATURE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_PLUGIN_FEATURE, GstPluginFeatureClass))
|
||||
|
||||
#define GST_PLUGIN_FEATURE_NAME(feature) (GST_PLUGIN_FEATURE (feature)->name)
|
||||
|
||||
typedef struct _GstPluginFeature GstPluginFeature;
|
||||
typedef struct _GstPluginFeatureClass GstPluginFeatureClass;
|
||||
|
||||
struct _GstPluginFeature
|
||||
{
|
||||
struct _GstPluginFeature {
|
||||
GObject object;
|
||||
|
||||
/*< private >*/
|
||||
|
@ -51,8 +53,7 @@ struct _GstPluginFeature
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstPluginFeatureClass
|
||||
{
|
||||
struct _GstPluginFeatureClass {
|
||||
GObjectClass parent_class;
|
||||
|
||||
void (*unload_thyself) (GstPluginFeature *feature);
|
||||
|
@ -60,12 +61,10 @@ struct _GstPluginFeatureClass
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
const gchar *name;
|
||||
GType type;
|
||||
}
|
||||
GstTypeNameData;
|
||||
} GstTypeNameData;
|
||||
|
||||
/* filter */
|
||||
typedef gboolean (*GstPluginFeatureFilter) (GstPluginFeature *feature,
|
||||
|
@ -81,10 +80,12 @@ gboolean gst_plugin_feature_type_name_filter (GstPluginFeature * feature,
|
|||
GstTypeNameData *data);
|
||||
|
||||
void gst_plugin_feature_set_rank (GstPluginFeature *feature, guint rank);
|
||||
void gst_plugin_feature_set_name (GstPluginFeature * feature,
|
||||
const gchar * name);
|
||||
void gst_plugin_feature_set_name (GstPluginFeature *feature, const gchar *name);
|
||||
guint gst_plugin_feature_get_rank (GstPluginFeature *feature);
|
||||
G_CONST_RETURN gchar *gst_plugin_feature_get_name (GstPluginFeature *feature);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_PLUGIN_FEATURE_H__ */
|
||||
|
||||
|
|
|
@ -27,14 +27,16 @@
|
|||
#include <glib.h>
|
||||
#include <gst/gstdata.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstProbe GstProbe;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstProbe GstProbe;
|
||||
|
||||
/* the callback should return FALSE if the data should be discarded */
|
||||
typedef gboolean (*GstProbeCallback) (GstProbe *probe,
|
||||
GstData ** data, gpointer user_data);
|
||||
GstData **data,
|
||||
gpointer user_data);
|
||||
|
||||
struct _GstProbe
|
||||
{
|
||||
struct _GstProbe {
|
||||
gboolean single_shot;
|
||||
|
||||
GstProbeCallback callback;
|
||||
|
@ -43,15 +45,15 @@ struct _GstProbe
|
|||
|
||||
|
||||
GstProbe* gst_probe_new (gboolean single_shot,
|
||||
GstProbeCallback callback, gpointer user_data);
|
||||
GstProbeCallback callback,
|
||||
gpointer user_data);
|
||||
void gst_probe_destroy (GstProbe *probe);
|
||||
|
||||
gboolean gst_probe_perform (GstProbe *probe, GstData **data);
|
||||
|
||||
typedef struct _GstProbeDispatcher GstProbeDispatcher;
|
||||
|
||||
struct _GstProbeDispatcher
|
||||
{
|
||||
struct _GstProbeDispatcher {
|
||||
gboolean active;
|
||||
|
||||
GSList *probes;
|
||||
|
@ -61,15 +63,14 @@ GstProbeDispatcher *gst_probe_dispatcher_new (void);
|
|||
void gst_probe_dispatcher_destroy (GstProbeDispatcher *disp);
|
||||
void gst_probe_dispatcher_init (GstProbeDispatcher *disp);
|
||||
|
||||
void gst_probe_dispatcher_set_active (GstProbeDispatcher * disp,
|
||||
gboolean active);
|
||||
void gst_probe_dispatcher_add_probe (GstProbeDispatcher * disp,
|
||||
GstProbe * probe);
|
||||
void gst_probe_dispatcher_remove_probe (GstProbeDispatcher * disp,
|
||||
GstProbe * probe);
|
||||
void gst_probe_dispatcher_set_active (GstProbeDispatcher *disp, gboolean active);
|
||||
void gst_probe_dispatcher_add_probe (GstProbeDispatcher *disp, GstProbe *probe);
|
||||
void gst_probe_dispatcher_remove_probe (GstProbeDispatcher *disp, GstProbe *probe);
|
||||
|
||||
gboolean gst_probe_dispatcher_dispatch (GstProbeDispatcher * disp,
|
||||
GstData ** data);
|
||||
gboolean gst_probe_dispatcher_dispatch (GstProbeDispatcher *disp, GstData **data);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_PAD_H__ */
|
||||
|
||||
|
|
|
@ -26,8 +26,9 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_QUERY_NONE = 0,
|
||||
GST_QUERY_TOTAL,
|
||||
GST_QUERY_POSITION,
|
||||
|
@ -36,8 +37,7 @@ G_BEGIN_DECLS typedef enum
|
|||
GST_QUERY_START,
|
||||
GST_QUERY_SEGMENT_END,
|
||||
GST_QUERY_RATE
|
||||
}
|
||||
GstQueryType;
|
||||
} GstQueryType;
|
||||
|
||||
/* rate is relative to 1000000 */
|
||||
#define GST_QUERY_TYPE_RATE_DEN G_GINT64_CONSTANT (1000000)
|
||||
|
@ -83,13 +83,14 @@ GstQueryType gst_query_type_register (const gchar * nick,
|
|||
GstQueryType gst_query_type_get_by_nick (const gchar *nick);
|
||||
|
||||
/* check if a query is in an array of querys */
|
||||
gboolean gst_query_types_contains (const GstQueryType * types,
|
||||
GstQueryType type);
|
||||
gboolean gst_query_types_contains (const GstQueryType *types, GstQueryType type);
|
||||
|
||||
/* query for query details */
|
||||
G_CONST_RETURN GstQueryTypeDefinition *gst_query_type_get_details (GstQueryType
|
||||
type);
|
||||
G_CONST_RETURN GstQueryTypeDefinition*
|
||||
gst_query_type_get_details (GstQueryType type);
|
||||
G_CONST_RETURN GList* gst_query_type_get_definitions (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_QUERY_H__ */
|
||||
|
||||
|
|
|
@ -29,6 +29,7 @@
|
|||
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_QUEUE \
|
||||
(gst_queue_get_type())
|
||||
#define GST_QUEUE(obj) \
|
||||
|
@ -39,8 +40,8 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_QUEUE))
|
||||
#define GST_IS_QUEUE_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_QUEUE))
|
||||
enum
|
||||
{
|
||||
|
||||
enum {
|
||||
GST_QUEUE_NO_LEAK = 0,
|
||||
GST_QUEUE_LEAK_UPSTREAM = 1,
|
||||
GST_QUEUE_LEAK_DOWNSTREAM = 2
|
||||
|
@ -49,8 +50,7 @@ G_BEGIN_DECLS
|
|||
typedef struct _GstQueue GstQueue;
|
||||
typedef struct _GstQueueClass GstQueueClass;
|
||||
|
||||
struct _GstQueue
|
||||
{
|
||||
struct _GstQueue {
|
||||
GstElement element;
|
||||
|
||||
GstPad *sinkpad;
|
||||
|
@ -59,13 +59,11 @@ struct _GstQueue
|
|||
/* the queue of data we're keeping our grubby hands on */
|
||||
GQueue *queue;
|
||||
|
||||
struct
|
||||
{
|
||||
struct {
|
||||
guint buffers; /* no. of buffers */
|
||||
guint bytes; /* no. of bytes */
|
||||
guint64 time; /* amount of time */
|
||||
}
|
||||
cur_level, /* currently in the queue */
|
||||
} cur_level, /* currently in the queue */
|
||||
max_size, /* max. amount of data allowed in the queue */
|
||||
min_threshold; /* min. amount of data required to wake reader */
|
||||
|
||||
|
@ -95,8 +93,7 @@ struct _GstQueue
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstQueueClass
|
||||
{
|
||||
struct _GstQueueClass {
|
||||
GstElementClass parent_class;
|
||||
|
||||
/* signals - 'running' is called from both sides
|
||||
|
@ -111,4 +108,6 @@ struct _GstQueueClass
|
|||
GType gst_queue_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_QUEUE_H__ */
|
||||
|
|
|
@ -43,25 +43,23 @@
|
|||
S_IRGRP | S_IWGRP | \
|
||||
S_IROTH | S_IWOTH)
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_REGISTRY_OK = (0),
|
||||
GST_REGISTRY_LOAD_ERROR = (1 << 1),
|
||||
GST_REGISTRY_SAVE_ERROR = (1 << 2),
|
||||
GST_REGISTRY_PLUGIN_LOAD_ERROR = (1 << 3),
|
||||
GST_REGISTRY_PLUGIN_SIGNATURE_ERROR = (1 << 4)
|
||||
}
|
||||
GstRegistryReturn;
|
||||
} GstRegistryReturn;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_REGISTRY_READABLE = (1 << 1),
|
||||
GST_REGISTRY_WRITABLE = (1 << 2),
|
||||
GST_REGISTRY_EXISTS = (1 << 3),
|
||||
GST_REGISTRY_REMOTE = (1 << 4),
|
||||
GST_REGISTRY_DELAYED_LOADING = (1 << 5)
|
||||
}
|
||||
GstRegistryFlags;
|
||||
} GstRegistryFlags;
|
||||
|
||||
|
||||
#define GST_TYPE_REGISTRY (gst_registry_get_type ())
|
||||
|
@ -74,8 +72,7 @@ GstRegistryFlags;
|
|||
typedef struct _GstRegistry GstRegistry;
|
||||
typedef struct _GstRegistryClass GstRegistryClass;
|
||||
|
||||
struct _GstRegistry
|
||||
{
|
||||
struct _GstRegistry {
|
||||
GObject object;
|
||||
|
||||
gint priority;
|
||||
|
@ -92,8 +89,7 @@ struct _GstRegistry
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstRegistryClass
|
||||
{
|
||||
struct _GstRegistryClass {
|
||||
GObjectClass parent_class;
|
||||
|
||||
/* vtable */
|
||||
|
@ -102,12 +98,9 @@ struct _GstRegistryClass
|
|||
gboolean (*rebuild) (GstRegistry *registry);
|
||||
gboolean (*unload) (GstRegistry *registry);
|
||||
|
||||
GstRegistryReturn (*load_plugin) (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn (*unload_plugin) (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn (*update_plugin) (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn (*load_plugin) (GstRegistry *registry, GstPlugin *plugin);
|
||||
GstRegistryReturn (*unload_plugin) (GstRegistry *registry, GstPlugin *plugin);
|
||||
GstRegistryReturn (*update_plugin) (GstRegistry *registry, GstPlugin *plugin);
|
||||
|
||||
/* signals */
|
||||
void (*plugin_added) (GstRegistry *registry, GstPlugin *plugin);
|
||||
|
@ -133,21 +126,21 @@ gboolean gst_registry_add_plugin (GstRegistry * registry, GstPlugin * plugin);
|
|||
void gst_registry_remove_plugin (GstRegistry *registry, GstPlugin *plugin);
|
||||
|
||||
GList* gst_registry_plugin_filter (GstRegistry *registry,
|
||||
GstPluginFilter filter, gboolean first, gpointer user_data);
|
||||
GstPluginFilter filter,
|
||||
gboolean first,
|
||||
gpointer user_data);
|
||||
GList* gst_registry_feature_filter (GstRegistry *registry,
|
||||
GstPluginFeatureFilter filter, gboolean first, gpointer user_data);
|
||||
GstPluginFeatureFilter filter,
|
||||
gboolean first,
|
||||
gpointer user_data);
|
||||
|
||||
GstPlugin *gst_registry_find_plugin (GstRegistry * registry,
|
||||
const gchar * name);
|
||||
GstPluginFeature *gst_registry_find_feature (GstRegistry * registry,
|
||||
const gchar * name, GType type);
|
||||
GstPlugin* gst_registry_find_plugin (GstRegistry *registry, const gchar *name);
|
||||
GstPluginFeature* gst_registry_find_feature (GstRegistry *registry, const gchar *name, GType type);
|
||||
|
||||
GstRegistryReturn gst_registry_load_plugin (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn gst_registry_unload_plugin (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn gst_registry_update_plugin (GstRegistry * registry,
|
||||
GstPlugin * plugin);
|
||||
GstRegistryReturn gst_registry_load_plugin (GstRegistry *registry, GstPlugin *plugin);
|
||||
GstRegistryReturn gst_registry_unload_plugin (GstRegistry *registry, GstPlugin *plugin);
|
||||
GstRegistryReturn gst_registry_update_plugin (GstRegistry *registry, GstPlugin *plugin);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_REGISTRY_H__ */
|
||||
|
|
|
@ -25,8 +25,10 @@
|
|||
#define __GST_REGISTRY_POOL_H__
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#include <gst/gstplugin.h>
|
||||
#include <gst/gstregistry.h>
|
||||
|
||||
/* the pool of registries */
|
||||
GList* gst_registry_pool_list (void);
|
||||
|
||||
|
@ -48,10 +50,10 @@ GList *gst_registry_pool_plugin_list (void);
|
|||
GList* gst_registry_pool_feature_list (GType type);
|
||||
|
||||
GstPlugin* gst_registry_pool_find_plugin (const gchar *name);
|
||||
GstPluginFeature *gst_registry_pool_find_feature (const gchar * name,
|
||||
GType type);
|
||||
GstPluginFeature* gst_registry_pool_find_feature (const gchar *name, GType type);
|
||||
|
||||
GstRegistry* gst_registry_pool_get_prefered (GstRegistryFlags flags);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_REGISTRY_POOL_H__ */
|
||||
|
|
|
@ -29,38 +29,35 @@
|
|||
#include <gst/gstbin.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_SCHEDULER (gst_scheduler_get_type ())
|
||||
#define GST_SCHEDULER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_SCHEDULER, GstScheduler))
|
||||
#define GST_IS_SCHEDULER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_SCHEDULER))
|
||||
#define GST_SCHEDULER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_SCHEDULER,GstSchedulerClass))
|
||||
#define GST_IS_SCHEDULER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_SCHEDULER))
|
||||
#define GST_SCHEDULER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_SCHEDULER, GstSchedulerClass))
|
||||
typedef enum
|
||||
{
|
||||
|
||||
typedef enum {
|
||||
/* this scheduler works with a fixed clock */
|
||||
GST_SCHEDULER_FLAG_FIXED_CLOCK = GST_OBJECT_FLAG_LAST,
|
||||
|
||||
/* padding */
|
||||
GST_SCHEDULER_FLAG_LAST = GST_OBJECT_FLAG_LAST + 4
|
||||
}
|
||||
GstSchedulerFlags;
|
||||
} GstSchedulerFlags;
|
||||
|
||||
#define GST_SCHEDULER_PARENT(sched) ((sched)->parent)
|
||||
#define GST_SCHEDULER_STATE(sched) ((sched)->state)
|
||||
|
||||
/*typedef struct _GstScheduler GstScheduler; */
|
||||
/*typedef struct _GstSchedulerClass GstSchedulerClass; */
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_SCHEDULER_STATE_NONE,
|
||||
GST_SCHEDULER_STATE_RUNNING,
|
||||
GST_SCHEDULER_STATE_STOPPED,
|
||||
GST_SCHEDULER_STATE_ERROR
|
||||
}
|
||||
GstSchedulerState;
|
||||
} GstSchedulerState;
|
||||
|
||||
struct _GstScheduler
|
||||
{
|
||||
struct _GstScheduler {
|
||||
GstObject object;
|
||||
|
||||
GstElement *parent;
|
||||
|
@ -78,8 +75,7 @@ struct _GstScheduler
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstSchedulerClass
|
||||
{
|
||||
struct _GstSchedulerClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* virtual methods */
|
||||
|
@ -89,8 +85,7 @@ struct _GstSchedulerClass
|
|||
void (*remove_element) (GstScheduler *sched, GstElement *element);
|
||||
void (*add_scheduler) (GstScheduler *sched, GstScheduler *sched2);
|
||||
void (*remove_scheduler) (GstScheduler *sched, GstScheduler *sched2);
|
||||
GstElementStateReturn (*state_transition) (GstScheduler * sched,
|
||||
GstElement * element, gint transition);
|
||||
GstElementStateReturn (*state_transition) (GstScheduler *sched, GstElement *element, gint transition);
|
||||
void (*scheduling_change) (GstScheduler *sched, GstElement *element);
|
||||
void (*lock_element) (GstScheduler *sched, GstElement *element);
|
||||
void (*unlock_element) (GstScheduler *sched, GstElement *element);
|
||||
|
@ -107,8 +102,8 @@ struct _GstSchedulerClass
|
|||
void (*show) (GstScheduler *sched);
|
||||
|
||||
/* signals */
|
||||
void (*object_sync) (GstScheduler * sched, GstClock * clock,
|
||||
GstObject * object, GstClockID id);
|
||||
void (*object_sync) (GstScheduler *sched, GstClock *clock, GstObject *object,
|
||||
GstClockID id);
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
@ -121,24 +116,19 @@ void gst_scheduler_reset (GstScheduler * sched);
|
|||
void gst_scheduler_add_element (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_remove_element (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_add_scheduler (GstScheduler *sched, GstScheduler *sched2);
|
||||
void gst_scheduler_remove_scheduler (GstScheduler * sched,
|
||||
GstScheduler * sched2);
|
||||
GstElementStateReturn gst_scheduler_state_transition (GstScheduler * sched,
|
||||
GstElement * element, gint transition);
|
||||
void gst_scheduler_scheduling_change (GstScheduler * sched,
|
||||
GstElement * element);
|
||||
void gst_scheduler_remove_scheduler (GstScheduler *sched, GstScheduler *sched2);
|
||||
GstElementStateReturn gst_scheduler_state_transition (GstScheduler *sched, GstElement *element, gint transition);
|
||||
void gst_scheduler_scheduling_change (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_lock_element (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_unlock_element (GstScheduler *sched, GstElement *element);
|
||||
gboolean gst_scheduler_yield (GstScheduler *sched, GstElement *element);
|
||||
gboolean gst_scheduler_interrupt (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_error (GstScheduler *sched, GstElement *element);
|
||||
void gst_scheduler_pad_link (GstScheduler * sched, GstPad * srcpad,
|
||||
GstPad * sinkpad);
|
||||
void gst_scheduler_pad_unlink (GstScheduler * sched, GstPad * srcpad,
|
||||
GstPad * sinkpad);
|
||||
void gst_scheduler_pad_link (GstScheduler *sched, GstPad *srcpad, GstPad *sinkpad);
|
||||
void gst_scheduler_pad_unlink (GstScheduler *sched, GstPad *srcpad, GstPad *sinkpad);
|
||||
GstPad* gst_scheduler_pad_select (GstScheduler *sched, GList *padlist);
|
||||
GstClockReturn gst_scheduler_clock_wait (GstScheduler * sched,
|
||||
GstElement * element, GstClockID id, GstClockTimeDiff * jitter);
|
||||
GstClockReturn gst_scheduler_clock_wait (GstScheduler *sched, GstElement *element,
|
||||
GstClockID id, GstClockTimeDiff *jitter);
|
||||
gboolean gst_scheduler_iterate (GstScheduler *sched);
|
||||
|
||||
void gst_scheduler_use_clock (GstScheduler *sched, GstClock *clock);
|
||||
|
@ -165,8 +155,7 @@ void gst_scheduler_show (GstScheduler * sched);
|
|||
typedef struct _GstSchedulerFactory GstSchedulerFactory;
|
||||
typedef struct _GstSchedulerFactoryClass GstSchedulerFactoryClass;
|
||||
|
||||
struct _GstSchedulerFactory
|
||||
{
|
||||
struct _GstSchedulerFactory {
|
||||
GstPluginFeature feature;
|
||||
|
||||
gchar *longdesc; /* long description of the scheduler (well, don't overdo it..) */
|
||||
|
@ -175,8 +164,7 @@ struct _GstSchedulerFactory
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstSchedulerFactoryClass
|
||||
{
|
||||
struct _GstSchedulerFactoryClass {
|
||||
GstPluginFeatureClass parent;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -184,20 +172,18 @@ struct _GstSchedulerFactoryClass
|
|||
|
||||
GType gst_scheduler_factory_get_type (void);
|
||||
|
||||
GstSchedulerFactory *gst_scheduler_factory_new (const gchar * name,
|
||||
const gchar * longdesc, GType type);
|
||||
GstSchedulerFactory* gst_scheduler_factory_new (const gchar *name, const gchar *longdesc, GType type);
|
||||
void gst_scheduler_factory_destroy (GstSchedulerFactory *factory);
|
||||
|
||||
GstSchedulerFactory* gst_scheduler_factory_find (const gchar *name);
|
||||
|
||||
GstScheduler *gst_scheduler_factory_create (GstSchedulerFactory * factory,
|
||||
GstElement * parent);
|
||||
GstScheduler *gst_scheduler_factory_make (const gchar * name,
|
||||
GstElement * parent);
|
||||
GstScheduler* gst_scheduler_factory_create (GstSchedulerFactory *factory, GstElement *parent);
|
||||
GstScheduler* gst_scheduler_factory_make (const gchar *name, GstElement *parent);
|
||||
|
||||
void gst_scheduler_factory_set_default_name (const gchar* name);
|
||||
G_CONST_RETURN gchar* gst_scheduler_factory_get_default_name (void);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SCHEDULER_H__ */
|
||||
|
|
|
@ -24,16 +24,18 @@
|
|||
#include <glib-object.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_STRUCTURE (gst_structure_get_type ())
|
||||
#define GST_STRUCTURE(object) (G_TYPE_CHECK_INSTANCE_CAST ((object), GST_TYPE_STRUCTURE, GstStructure))
|
||||
#define GST_IS_STRUCTURE(object) (G_TYPE_CHECK_INSTANCE_TYPE ((object), GST_TYPE_STRUCTURE))
|
||||
|
||||
typedef struct _GstStructure GstStructure;
|
||||
|
||||
typedef gboolean (*GstStructureForeachFunc) (GQuark field_id,
|
||||
GValue * value, gpointer user_data);
|
||||
GValue * value,
|
||||
gpointer user_data);
|
||||
|
||||
struct _GstStructure
|
||||
{
|
||||
struct _GstStructure {
|
||||
GType type;
|
||||
|
||||
GQuark name;
|
||||
|
@ -41,68 +43,82 @@ struct _GstStructure
|
|||
GArray *fields;
|
||||
};
|
||||
|
||||
GType
|
||||
gst_structure_get_type (void)
|
||||
G_GNUC_CONST;
|
||||
GType gst_structure_get_type (void) G_GNUC_CONST;
|
||||
|
||||
GstStructure * gst_structure_empty_new (const gchar * name);
|
||||
GstStructure * gst_structure_id_empty_new (GQuark quark);
|
||||
GstStructure * gst_structure_new (const gchar * name,
|
||||
const gchar * firstfield, ...);
|
||||
const gchar * firstfield,
|
||||
...);
|
||||
GstStructure * gst_structure_new_valist (const gchar * name,
|
||||
const gchar * firstfield, va_list varargs);
|
||||
const gchar * firstfield,
|
||||
va_list varargs);
|
||||
GstStructure * gst_structure_copy (const GstStructure *structure);
|
||||
void gst_structure_free (GstStructure *structure);
|
||||
|
||||
G_CONST_RETURN gchar *gst_structure_get_name (const GstStructure *
|
||||
structure);
|
||||
void gst_structure_set_name (GstStructure * structure, const gchar * name);
|
||||
G_CONST_RETURN gchar * gst_structure_get_name (const GstStructure *structure);
|
||||
void gst_structure_set_name (GstStructure *structure,
|
||||
const gchar *name);
|
||||
|
||||
void gst_structure_id_set_value (GstStructure *structure,
|
||||
GQuark field, const GValue * value);
|
||||
GQuark field,
|
||||
const GValue *value);
|
||||
void gst_structure_set_value (GstStructure *structure,
|
||||
const gchar * fieldname, const GValue * value);
|
||||
const gchar *fieldname,
|
||||
const GValue *value);
|
||||
void gst_structure_set (GstStructure *structure,
|
||||
const gchar * fieldname, ...);
|
||||
const gchar *fieldname,
|
||||
...);
|
||||
void gst_structure_set_valist (GstStructure *structure,
|
||||
const gchar * fieldname, va_list varargs);
|
||||
G_CONST_RETURN GValue *gst_structure_id_get_value (const GstStructure *
|
||||
structure, GQuark field);
|
||||
G_CONST_RETURN GValue *gst_structure_get_value (const GstStructure *
|
||||
structure, const gchar * fieldname);
|
||||
const gchar *fieldname,
|
||||
va_list varargs);
|
||||
G_CONST_RETURN GValue * gst_structure_id_get_value (const GstStructure *structure,
|
||||
GQuark field);
|
||||
G_CONST_RETURN GValue * gst_structure_get_value (const GstStructure *structure,
|
||||
const gchar *fieldname);
|
||||
void gst_structure_remove_field (GstStructure *structure,
|
||||
const gchar *fieldname);
|
||||
void gst_structure_remove_fields (GstStructure *structure,
|
||||
const gchar * fieldname, ...);
|
||||
const gchar *fieldname,
|
||||
...);
|
||||
void gst_structure_remove_fields_valist (GstStructure *structure,
|
||||
const gchar * fieldname, va_list varargs);
|
||||
const gchar *fieldname,
|
||||
va_list varargs);
|
||||
void gst_structure_remove_all_fields (GstStructure *structure);
|
||||
|
||||
GType gst_structure_get_field_type (const GstStructure *structure,
|
||||
const gchar *fieldname);
|
||||
gboolean gst_structure_foreach (GstStructure *structure,
|
||||
GstStructureForeachFunc func, gpointer user_data);
|
||||
GstStructureForeachFunc func,
|
||||
gpointer user_data);
|
||||
gint gst_structure_n_fields (const GstStructure *structure);
|
||||
gboolean gst_structure_has_field (const GstStructure *structure,
|
||||
const gchar *fieldname);
|
||||
gboolean gst_structure_has_field_typed (const GstStructure *structure,
|
||||
const gchar * fieldname, GType type);
|
||||
const gchar *fieldname,
|
||||
GType type);
|
||||
|
||||
/* utility functions */
|
||||
gboolean gst_structure_get_boolean (const GstStructure *structure,
|
||||
const gchar * fieldname, gboolean * value);
|
||||
const gchar *fieldname,
|
||||
gboolean *value);
|
||||
gboolean gst_structure_get_int (const GstStructure *structure,
|
||||
const gchar * fieldname, gint * value);
|
||||
const gchar *fieldname,
|
||||
gint *value);
|
||||
gboolean gst_structure_get_fourcc (const GstStructure *structure,
|
||||
const gchar * fieldname, guint32 * value);
|
||||
const gchar *fieldname,
|
||||
guint32 *value);
|
||||
gboolean gst_structure_get_double (const GstStructure *structure,
|
||||
const gchar * fieldname, gdouble * value);
|
||||
G_CONST_RETURN gchar *gst_structure_get_string (const GstStructure *
|
||||
structure, const gchar * fieldname);
|
||||
const gchar *fieldname,
|
||||
gdouble *value);
|
||||
G_CONST_RETURN gchar * gst_structure_get_string (const GstStructure *structure,
|
||||
const gchar *fieldname);
|
||||
|
||||
gchar * gst_structure_to_string (const GstStructure *structure);
|
||||
GstStructure * gst_structure_from_string (const gchar *string,
|
||||
gchar **end);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -27,17 +27,19 @@
|
|||
#include <gst/gstclock.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_SYSTEM_CLOCK (gst_system_clock_get_type ())
|
||||
#define GST_SYSTEM_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_SYSTEM_CLOCK, GstSystemClock))
|
||||
#define GST_IS_SYSTEM_CLOCK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_SYSTEM_CLOCK))
|
||||
#define GST_SYSTEM_CLOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_SYSTEM_CLOCK, GstSystemClockClass))
|
||||
#define GST_IS_SYSTEM_CLOCK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_SYSTEM_CLOCK))
|
||||
#define GST_SYSTEM_CLOCK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_SYSTEM_CLOCK, GstSystemClockClass))
|
||||
|
||||
|
||||
typedef struct _GstSystemClock GstSystemClock;
|
||||
typedef struct _GstSystemClockClass GstSystemClockClass;
|
||||
|
||||
struct _GstSystemClock
|
||||
{
|
||||
struct _GstSystemClock {
|
||||
GstClock clock;
|
||||
|
||||
GMutex * mutex;
|
||||
|
@ -46,8 +48,7 @@ struct _GstSystemClock
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstSystemClockClass
|
||||
{
|
||||
struct _GstSystemClockClass {
|
||||
GstClockClass parent_class;
|
||||
|
||||
gpointer _gst_reserved[GST_PADDING];
|
||||
|
@ -58,4 +59,5 @@ GType gst_system_clock_get_type (void);
|
|||
GstClock* gst_system_clock_obtain (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_SYSTEM_CLOCK_H__ */
|
||||
|
|
169
gst/gsttag.h
169
gst/gsttag.h
|
@ -26,8 +26,9 @@
|
|||
#include <gst/gststructure.h>
|
||||
#include <gst/gstevent.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_TAG_MERGE_UNDEFINED,
|
||||
GST_TAG_MERGE_REPLACE_ALL,
|
||||
GST_TAG_MERGE_REPLACE,
|
||||
|
@ -37,31 +38,24 @@ G_BEGIN_DECLS typedef enum
|
|||
GST_TAG_MERGE_KEEP_ALL,
|
||||
/* add more */
|
||||
GST_TAG_MERGE_COUNT
|
||||
}
|
||||
GstTagMergeMode;
|
||||
|
||||
} GstTagMergeMode;
|
||||
#define GST_TAG_MODE_IS_VALID(mode) (((mode) > GST_TAG_MERGE_UNDEFINED) && ((mode) < GST_TAG_MERGE_COUNT))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_TAG_FLAG_UNDEFINED,
|
||||
GST_TAG_FLAG_META,
|
||||
GST_TAG_FLAG_ENCODED,
|
||||
GST_TAG_FLAG_DECODED,
|
||||
GST_TAG_FLAG_COUNT
|
||||
}
|
||||
GstTagFlag;
|
||||
|
||||
} GstTagFlag;
|
||||
#define GST_TAG_FLAG_IS_VALID(flag) (((flag) > GST_TAG_FLAG_UNDEFINED) && ((flag) < GST_TAG_FLAG_COUNT))
|
||||
|
||||
typedef GstStructure GstTagList;
|
||||
|
||||
#define GST_TAG_LIST(x) ((GstTagList *) (x))
|
||||
#define GST_IS_TAG_LIST(x) (gst_is_tag_list (GST_TAG_LIST (x)))
|
||||
#define GST_TYPE_TAG_LIST (gst_tag_list_get_type ())
|
||||
|
||||
typedef void (*GstTagForeachFunc) (const GstTagList * list, const gchar * tag,
|
||||
gpointer user_data);
|
||||
typedef void (* GstTagForeachFunc) (const GstTagList *list, const gchar *tag, gpointer user_data);
|
||||
typedef void (* GstTagMergeFunc) (GValue *dest, const GValue *src);
|
||||
|
||||
/* initialize tagging system */
|
||||
|
@ -70,16 +64,23 @@ GType gst_tag_list_get_type (void);
|
|||
|
||||
void gst_tag_register (gchar * name,
|
||||
GstTagFlag flag,
|
||||
GType type, gchar * nick, gchar * blurb, GstTagMergeFunc func);
|
||||
GType type,
|
||||
gchar * nick,
|
||||
gchar * blurb,
|
||||
GstTagMergeFunc func);
|
||||
/* some default merging functions */
|
||||
void gst_tag_merge_use_first (GValue * dest, const GValue * src);
|
||||
void gst_tag_merge_strings_with_comma (GValue * dest, const GValue * src);
|
||||
void gst_tag_merge_use_first (GValue * dest,
|
||||
const GValue * src);
|
||||
void gst_tag_merge_strings_with_comma (GValue * dest,
|
||||
const GValue * src);
|
||||
|
||||
/* basic tag support */
|
||||
gboolean gst_tag_exists (const gchar * tag);
|
||||
GType gst_tag_get_type (const gchar * tag);
|
||||
G_CONST_RETURN gchar *gst_tag_get_nick (const gchar * tag);
|
||||
G_CONST_RETURN gchar *gst_tag_get_description (const gchar * tag);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_tag_get_nick (const gchar * tag);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_tag_get_description (const gchar * tag);
|
||||
GstTagFlag gst_tag_get_flag (const gchar * tag);
|
||||
gboolean gst_tag_is_fixed (const gchar * tag);
|
||||
|
||||
|
@ -88,81 +89,136 @@ GstTagList *gst_tag_list_new (void);
|
|||
gboolean gst_is_tag_list (gconstpointer p);
|
||||
GstTagList * gst_tag_list_copy (const GstTagList * list);
|
||||
void gst_tag_list_insert (GstTagList * into,
|
||||
const GstTagList * from, GstTagMergeMode mode);
|
||||
const GstTagList * from,
|
||||
GstTagMergeMode mode);
|
||||
GstTagList * gst_tag_list_merge (const GstTagList * list1,
|
||||
const GstTagList * list2, GstTagMergeMode mode);
|
||||
const GstTagList * list2,
|
||||
GstTagMergeMode mode);
|
||||
void gst_tag_list_free (GstTagList * list);
|
||||
guint gst_tag_list_get_tag_size (const GstTagList * list, const gchar * tag);
|
||||
guint gst_tag_list_get_tag_size (const GstTagList * list,
|
||||
const gchar * tag);
|
||||
void gst_tag_list_add (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
void gst_tag_list_add_values (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
void gst_tag_list_add_valist (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
void gst_tag_list_add_valist_values (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
void gst_tag_list_remove_tag (GstTagList * list, const gchar * tag);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
void gst_tag_list_remove_tag (GstTagList * list,
|
||||
const gchar * tag);
|
||||
void gst_tag_list_foreach (GstTagList * list,
|
||||
GstTagForeachFunc func, gpointer user_data);
|
||||
GstTagForeachFunc func,
|
||||
gpointer user_data);
|
||||
|
||||
G_CONST_RETURN GValue *gst_tag_list_get_value_index (const GstTagList * list,
|
||||
const gchar * tag, guint index);
|
||||
G_CONST_RETURN GValue *
|
||||
gst_tag_list_get_value_index (const GstTagList * list,
|
||||
const gchar * tag,
|
||||
guint index);
|
||||
gboolean gst_tag_list_copy_value (GValue * dest,
|
||||
const GstTagList * list, const gchar * tag);
|
||||
const GstTagList * list,
|
||||
const gchar * tag);
|
||||
|
||||
/* simplifications (FIXME: do we want them?) */
|
||||
gboolean gst_tag_list_get_char (const GstTagList * list,
|
||||
const gchar * tag, gchar * value);
|
||||
const gchar * tag,
|
||||
gchar * value);
|
||||
gboolean gst_tag_list_get_char_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gchar * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gchar * value);
|
||||
gboolean gst_tag_list_get_uchar (const GstTagList * list,
|
||||
const gchar * tag, guchar * value);
|
||||
const gchar * tag,
|
||||
guchar * value);
|
||||
gboolean gst_tag_list_get_uchar_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guchar * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guchar * value);
|
||||
gboolean gst_tag_list_get_boolean (const GstTagList * list,
|
||||
const gchar * tag, gboolean * value);
|
||||
const gchar * tag,
|
||||
gboolean * value);
|
||||
gboolean gst_tag_list_get_boolean_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gboolean * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gboolean * value);
|
||||
gboolean gst_tag_list_get_int (const GstTagList * list,
|
||||
const gchar * tag, gint * value);
|
||||
const gchar * tag,
|
||||
gint * value);
|
||||
gboolean gst_tag_list_get_int_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gint * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gint * value);
|
||||
gboolean gst_tag_list_get_uint (const GstTagList * list,
|
||||
const gchar * tag, guint * value);
|
||||
const gchar * tag,
|
||||
guint * value);
|
||||
gboolean gst_tag_list_get_uint_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guint * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guint * value);
|
||||
gboolean gst_tag_list_get_long (const GstTagList * list,
|
||||
const gchar * tag, glong * value);
|
||||
const gchar * tag,
|
||||
glong * value);
|
||||
gboolean gst_tag_list_get_long_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, glong * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
glong * value);
|
||||
gboolean gst_tag_list_get_ulong (const GstTagList * list,
|
||||
const gchar * tag, gulong * value);
|
||||
const gchar * tag,
|
||||
gulong * value);
|
||||
gboolean gst_tag_list_get_ulong_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gulong * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gulong * value);
|
||||
gboolean gst_tag_list_get_int64 (const GstTagList * list,
|
||||
const gchar * tag, gint64 * value);
|
||||
const gchar * tag,
|
||||
gint64 * value);
|
||||
gboolean gst_tag_list_get_int64_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gint64 * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gint64 * value);
|
||||
gboolean gst_tag_list_get_uint64 (const GstTagList * list,
|
||||
const gchar * tag, guint64 * value);
|
||||
const gchar * tag,
|
||||
guint64 * value);
|
||||
gboolean gst_tag_list_get_uint64_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guint64 * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guint64 * value);
|
||||
gboolean gst_tag_list_get_float (const GstTagList * list,
|
||||
const gchar * tag, gfloat * value);
|
||||
const gchar * tag,
|
||||
gfloat * value);
|
||||
gboolean gst_tag_list_get_float_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gfloat * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gfloat * value);
|
||||
gboolean gst_tag_list_get_double (const GstTagList * list,
|
||||
const gchar * tag, gdouble * value);
|
||||
const gchar * tag,
|
||||
gdouble * value);
|
||||
gboolean gst_tag_list_get_double_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gdouble * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gdouble * value);
|
||||
gboolean gst_tag_list_get_string (const GstTagList * list,
|
||||
const gchar * tag, gchar ** value);
|
||||
const gchar * tag,
|
||||
gchar ** value);
|
||||
gboolean gst_tag_list_get_string_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gchar ** value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gchar ** value);
|
||||
gboolean gst_tag_list_get_pointer (const GstTagList * list,
|
||||
const gchar * tag, gpointer * value);
|
||||
const gchar * tag,
|
||||
gpointer * value);
|
||||
gboolean gst_tag_list_get_pointer_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gpointer * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gpointer * value);
|
||||
|
||||
/* tag events */
|
||||
GstEvent * gst_event_new_tag (GstTagList * list);
|
||||
|
@ -206,4 +262,5 @@ GstTagList *gst_event_tag_get_list (GstEvent * tag_event);
|
|||
#define GST_TAG_ALBUM_PEAK "replaygain-album-peak"
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_EVENT_H__ */
|
||||
|
|
|
@ -25,11 +25,13 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TAG_SETTER (gst_tag_setter_get_type ())
|
||||
#define GST_TAG_SETTER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_TAG_SETTER, GstTagSetter))
|
||||
#define GST_TAG_SETTER_CLASS(obj) (G_TYPE_CHECK_CLASS_CAST ((obj), GST_TYPE_TAG_SETTER, GstTagSetter))
|
||||
#define GST_IS_TAG_SETTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TAG_SETTER))
|
||||
#define GST_TAG_SETTER_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_TAG_SETTER, GstTagSetterIFace))
|
||||
|
||||
typedef struct _GstTagSetter GstTagSetter; /* Dummy typedef */
|
||||
typedef struct _GstTagSetterIFace GstTagSetterIFace;
|
||||
|
||||
|
@ -44,29 +46,38 @@ struct _GstTagSetterIFace
|
|||
/* virtual table */
|
||||
};
|
||||
|
||||
GType
|
||||
gst_tag_setter_get_type (void)
|
||||
G_GNUC_CONST;
|
||||
GType gst_tag_setter_get_type (void) G_GNUC_CONST;
|
||||
|
||||
void gst_tag_setter_merge (GstTagSetter * setter,
|
||||
const GstTagList * list, GstTagMergeMode mode);
|
||||
const GstTagList * list,
|
||||
GstTagMergeMode mode);
|
||||
void gst_tag_setter_add (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
|
||||
void gst_tag_setter_add_values (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
|
||||
void gst_tag_setter_add_valist (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
|
||||
void gst_tag_setter_add_valist_values(GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
|
||||
G_CONST_RETURN GstTagList *gst_tag_setter_get_list (GstTagSetter * setter);
|
||||
G_CONST_RETURN GstTagList *
|
||||
gst_tag_setter_get_list (GstTagSetter * setter);
|
||||
|
||||
void gst_tag_setter_set_merge_mode (GstTagSetter * setter,
|
||||
GstTagMergeMode mode);
|
||||
GstTagMergeMode gst_tag_setter_get_merge_mode (GstTagSetter * setter);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TAG_INTERFACE_H__ */
|
||||
|
|
169
gst/gsttaglist.h
169
gst/gsttaglist.h
|
@ -26,8 +26,9 @@
|
|||
#include <gst/gststructure.h>
|
||||
#include <gst/gstevent.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_TAG_MERGE_UNDEFINED,
|
||||
GST_TAG_MERGE_REPLACE_ALL,
|
||||
GST_TAG_MERGE_REPLACE,
|
||||
|
@ -37,31 +38,24 @@ G_BEGIN_DECLS typedef enum
|
|||
GST_TAG_MERGE_KEEP_ALL,
|
||||
/* add more */
|
||||
GST_TAG_MERGE_COUNT
|
||||
}
|
||||
GstTagMergeMode;
|
||||
|
||||
} GstTagMergeMode;
|
||||
#define GST_TAG_MODE_IS_VALID(mode) (((mode) > GST_TAG_MERGE_UNDEFINED) && ((mode) < GST_TAG_MERGE_COUNT))
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_TAG_FLAG_UNDEFINED,
|
||||
GST_TAG_FLAG_META,
|
||||
GST_TAG_FLAG_ENCODED,
|
||||
GST_TAG_FLAG_DECODED,
|
||||
GST_TAG_FLAG_COUNT
|
||||
}
|
||||
GstTagFlag;
|
||||
|
||||
} GstTagFlag;
|
||||
#define GST_TAG_FLAG_IS_VALID(flag) (((flag) > GST_TAG_FLAG_UNDEFINED) && ((flag) < GST_TAG_FLAG_COUNT))
|
||||
|
||||
typedef GstStructure GstTagList;
|
||||
|
||||
#define GST_TAG_LIST(x) ((GstTagList *) (x))
|
||||
#define GST_IS_TAG_LIST(x) (gst_is_tag_list (GST_TAG_LIST (x)))
|
||||
#define GST_TYPE_TAG_LIST (gst_tag_list_get_type ())
|
||||
|
||||
typedef void (*GstTagForeachFunc) (const GstTagList * list, const gchar * tag,
|
||||
gpointer user_data);
|
||||
typedef void (* GstTagForeachFunc) (const GstTagList *list, const gchar *tag, gpointer user_data);
|
||||
typedef void (* GstTagMergeFunc) (GValue *dest, const GValue *src);
|
||||
|
||||
/* initialize tagging system */
|
||||
|
@ -70,16 +64,23 @@ GType gst_tag_list_get_type (void);
|
|||
|
||||
void gst_tag_register (gchar * name,
|
||||
GstTagFlag flag,
|
||||
GType type, gchar * nick, gchar * blurb, GstTagMergeFunc func);
|
||||
GType type,
|
||||
gchar * nick,
|
||||
gchar * blurb,
|
||||
GstTagMergeFunc func);
|
||||
/* some default merging functions */
|
||||
void gst_tag_merge_use_first (GValue * dest, const GValue * src);
|
||||
void gst_tag_merge_strings_with_comma (GValue * dest, const GValue * src);
|
||||
void gst_tag_merge_use_first (GValue * dest,
|
||||
const GValue * src);
|
||||
void gst_tag_merge_strings_with_comma (GValue * dest,
|
||||
const GValue * src);
|
||||
|
||||
/* basic tag support */
|
||||
gboolean gst_tag_exists (const gchar * tag);
|
||||
GType gst_tag_get_type (const gchar * tag);
|
||||
G_CONST_RETURN gchar *gst_tag_get_nick (const gchar * tag);
|
||||
G_CONST_RETURN gchar *gst_tag_get_description (const gchar * tag);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_tag_get_nick (const gchar * tag);
|
||||
G_CONST_RETURN gchar *
|
||||
gst_tag_get_description (const gchar * tag);
|
||||
GstTagFlag gst_tag_get_flag (const gchar * tag);
|
||||
gboolean gst_tag_is_fixed (const gchar * tag);
|
||||
|
||||
|
@ -88,81 +89,136 @@ GstTagList *gst_tag_list_new (void);
|
|||
gboolean gst_is_tag_list (gconstpointer p);
|
||||
GstTagList * gst_tag_list_copy (const GstTagList * list);
|
||||
void gst_tag_list_insert (GstTagList * into,
|
||||
const GstTagList * from, GstTagMergeMode mode);
|
||||
const GstTagList * from,
|
||||
GstTagMergeMode mode);
|
||||
GstTagList * gst_tag_list_merge (const GstTagList * list1,
|
||||
const GstTagList * list2, GstTagMergeMode mode);
|
||||
const GstTagList * list2,
|
||||
GstTagMergeMode mode);
|
||||
void gst_tag_list_free (GstTagList * list);
|
||||
guint gst_tag_list_get_tag_size (const GstTagList * list, const gchar * tag);
|
||||
guint gst_tag_list_get_tag_size (const GstTagList * list,
|
||||
const gchar * tag);
|
||||
void gst_tag_list_add (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
void gst_tag_list_add_values (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
void gst_tag_list_add_valist (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
void gst_tag_list_add_valist_values (GstTagList * list,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
void gst_tag_list_remove_tag (GstTagList * list, const gchar * tag);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
void gst_tag_list_remove_tag (GstTagList * list,
|
||||
const gchar * tag);
|
||||
void gst_tag_list_foreach (GstTagList * list,
|
||||
GstTagForeachFunc func, gpointer user_data);
|
||||
GstTagForeachFunc func,
|
||||
gpointer user_data);
|
||||
|
||||
G_CONST_RETURN GValue *gst_tag_list_get_value_index (const GstTagList * list,
|
||||
const gchar * tag, guint index);
|
||||
G_CONST_RETURN GValue *
|
||||
gst_tag_list_get_value_index (const GstTagList * list,
|
||||
const gchar * tag,
|
||||
guint index);
|
||||
gboolean gst_tag_list_copy_value (GValue * dest,
|
||||
const GstTagList * list, const gchar * tag);
|
||||
const GstTagList * list,
|
||||
const gchar * tag);
|
||||
|
||||
/* simplifications (FIXME: do we want them?) */
|
||||
gboolean gst_tag_list_get_char (const GstTagList * list,
|
||||
const gchar * tag, gchar * value);
|
||||
const gchar * tag,
|
||||
gchar * value);
|
||||
gboolean gst_tag_list_get_char_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gchar * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gchar * value);
|
||||
gboolean gst_tag_list_get_uchar (const GstTagList * list,
|
||||
const gchar * tag, guchar * value);
|
||||
const gchar * tag,
|
||||
guchar * value);
|
||||
gboolean gst_tag_list_get_uchar_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guchar * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guchar * value);
|
||||
gboolean gst_tag_list_get_boolean (const GstTagList * list,
|
||||
const gchar * tag, gboolean * value);
|
||||
const gchar * tag,
|
||||
gboolean * value);
|
||||
gboolean gst_tag_list_get_boolean_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gboolean * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gboolean * value);
|
||||
gboolean gst_tag_list_get_int (const GstTagList * list,
|
||||
const gchar * tag, gint * value);
|
||||
const gchar * tag,
|
||||
gint * value);
|
||||
gboolean gst_tag_list_get_int_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gint * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gint * value);
|
||||
gboolean gst_tag_list_get_uint (const GstTagList * list,
|
||||
const gchar * tag, guint * value);
|
||||
const gchar * tag,
|
||||
guint * value);
|
||||
gboolean gst_tag_list_get_uint_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guint * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guint * value);
|
||||
gboolean gst_tag_list_get_long (const GstTagList * list,
|
||||
const gchar * tag, glong * value);
|
||||
const gchar * tag,
|
||||
glong * value);
|
||||
gboolean gst_tag_list_get_long_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, glong * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
glong * value);
|
||||
gboolean gst_tag_list_get_ulong (const GstTagList * list,
|
||||
const gchar * tag, gulong * value);
|
||||
const gchar * tag,
|
||||
gulong * value);
|
||||
gboolean gst_tag_list_get_ulong_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gulong * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gulong * value);
|
||||
gboolean gst_tag_list_get_int64 (const GstTagList * list,
|
||||
const gchar * tag, gint64 * value);
|
||||
const gchar * tag,
|
||||
gint64 * value);
|
||||
gboolean gst_tag_list_get_int64_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gint64 * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gint64 * value);
|
||||
gboolean gst_tag_list_get_uint64 (const GstTagList * list,
|
||||
const gchar * tag, guint64 * value);
|
||||
const gchar * tag,
|
||||
guint64 * value);
|
||||
gboolean gst_tag_list_get_uint64_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, guint64 * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
guint64 * value);
|
||||
gboolean gst_tag_list_get_float (const GstTagList * list,
|
||||
const gchar * tag, gfloat * value);
|
||||
const gchar * tag,
|
||||
gfloat * value);
|
||||
gboolean gst_tag_list_get_float_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gfloat * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gfloat * value);
|
||||
gboolean gst_tag_list_get_double (const GstTagList * list,
|
||||
const gchar * tag, gdouble * value);
|
||||
const gchar * tag,
|
||||
gdouble * value);
|
||||
gboolean gst_tag_list_get_double_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gdouble * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gdouble * value);
|
||||
gboolean gst_tag_list_get_string (const GstTagList * list,
|
||||
const gchar * tag, gchar ** value);
|
||||
const gchar * tag,
|
||||
gchar ** value);
|
||||
gboolean gst_tag_list_get_string_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gchar ** value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gchar ** value);
|
||||
gboolean gst_tag_list_get_pointer (const GstTagList * list,
|
||||
const gchar * tag, gpointer * value);
|
||||
const gchar * tag,
|
||||
gpointer * value);
|
||||
gboolean gst_tag_list_get_pointer_index (const GstTagList * list,
|
||||
const gchar * tag, guint index, gpointer * value);
|
||||
const gchar * tag,
|
||||
guint index,
|
||||
gpointer * value);
|
||||
|
||||
/* tag events */
|
||||
GstEvent * gst_event_new_tag (GstTagList * list);
|
||||
|
@ -206,4 +262,5 @@ GstTagList *gst_event_tag_get_list (GstEvent * tag_event);
|
|||
#define GST_TAG_ALBUM_PEAK "replaygain-album-peak"
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_EVENT_H__ */
|
||||
|
|
|
@ -25,11 +25,13 @@
|
|||
#include <gst/gst.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TAG_SETTER (gst_tag_setter_get_type ())
|
||||
#define GST_TAG_SETTER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_TAG_SETTER, GstTagSetter))
|
||||
#define GST_TAG_SETTER_CLASS(obj) (G_TYPE_CHECK_CLASS_CAST ((obj), GST_TYPE_TAG_SETTER, GstTagSetter))
|
||||
#define GST_IS_TAG_SETTER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TAG_SETTER))
|
||||
#define GST_TAG_SETTER_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), GST_TYPE_TAG_SETTER, GstTagSetterIFace))
|
||||
|
||||
typedef struct _GstTagSetter GstTagSetter; /* Dummy typedef */
|
||||
typedef struct _GstTagSetterIFace GstTagSetterIFace;
|
||||
|
||||
|
@ -44,29 +46,38 @@ struct _GstTagSetterIFace
|
|||
/* virtual table */
|
||||
};
|
||||
|
||||
GType
|
||||
gst_tag_setter_get_type (void)
|
||||
G_GNUC_CONST;
|
||||
GType gst_tag_setter_get_type (void) G_GNUC_CONST;
|
||||
|
||||
void gst_tag_setter_merge (GstTagSetter * setter,
|
||||
const GstTagList * list, GstTagMergeMode mode);
|
||||
const GstTagList * list,
|
||||
GstTagMergeMode mode);
|
||||
void gst_tag_setter_add (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
|
||||
void gst_tag_setter_add_values (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, ...);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
...);
|
||||
|
||||
void gst_tag_setter_add_valist (GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
|
||||
void gst_tag_setter_add_valist_values(GstTagSetter * setter,
|
||||
GstTagMergeMode mode, const gchar * tag, va_list var_args);
|
||||
GstTagMergeMode mode,
|
||||
const gchar * tag,
|
||||
va_list var_args);
|
||||
|
||||
G_CONST_RETURN GstTagList *gst_tag_setter_get_list (GstTagSetter * setter);
|
||||
G_CONST_RETURN GstTagList *
|
||||
gst_tag_setter_get_list (GstTagSetter * setter);
|
||||
|
||||
void gst_tag_setter_set_merge_mode (GstTagSetter * setter,
|
||||
GstTagMergeMode mode);
|
||||
GstTagMergeMode gst_tag_setter_get_merge_mode (GstTagSetter * setter);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TAG_INTERFACE_H__ */
|
||||
|
|
|
@ -29,10 +29,11 @@
|
|||
#include <gst/gstbin.h>
|
||||
|
||||
|
||||
G_BEGIN_DECLS extern GPrivate *gst_thread_current;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum
|
||||
{
|
||||
extern GPrivate *gst_thread_current;
|
||||
|
||||
typedef enum {
|
||||
GST_THREAD_STATE_SPINNING = GST_BIN_FLAG_LAST,
|
||||
GST_THREAD_STATE_REAPING,
|
||||
/* when iterating with mutex locked (special cases)
|
||||
|
@ -41,8 +42,7 @@ typedef enum
|
|||
|
||||
/* padding */
|
||||
GST_THREAD_FLAG_LAST = GST_BIN_FLAG_LAST + 4
|
||||
}
|
||||
GstThreadState;
|
||||
} GstThreadState;
|
||||
|
||||
#define GST_TYPE_THREAD (gst_thread_get_type())
|
||||
#define GST_THREAD(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_THREAD,GstThread))
|
||||
|
@ -54,8 +54,7 @@ GstThreadState;
|
|||
typedef struct _GstThread GstThread;
|
||||
typedef struct _GstThreadClass GstThreadClass;
|
||||
|
||||
struct _GstThread
|
||||
{
|
||||
struct _GstThread {
|
||||
GstBin bin;
|
||||
|
||||
GThread *thread_id; /* id of the thread, if any */
|
||||
|
@ -67,8 +66,7 @@ struct _GstThread
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstThreadClass
|
||||
{
|
||||
struct _GstThreadClass {
|
||||
GstBinClass parent_class;
|
||||
|
||||
/* signals */
|
||||
|
@ -85,4 +83,6 @@ void gst_thread_set_priority (GstThread * thread, GThreadPriority priority);
|
|||
GstThread * gst_thread_get_current (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
|
||||
#endif /* __GST_THREAD_H__ */
|
||||
|
|
|
@ -28,11 +28,12 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstTrace GstTrace;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstTrace GstTrace;
|
||||
typedef struct _GstTraceEntry GstTraceEntry;
|
||||
|
||||
struct _GstTrace
|
||||
{
|
||||
struct _GstTrace {
|
||||
/* where this trace is going */
|
||||
gchar *filename;
|
||||
int fd;
|
||||
|
@ -43,8 +44,7 @@ struct _GstTrace
|
|||
gint bufoffset;
|
||||
};
|
||||
|
||||
struct _GstTraceEntry
|
||||
{
|
||||
struct _GstTraceEntry {
|
||||
gint64 timestamp;
|
||||
guint32 sequence;
|
||||
guint32 data;
|
||||
|
@ -58,7 +58,6 @@ GstTrace *gst_trace_new (gchar * filename, gint size);
|
|||
void gst_trace_destroy (GstTrace *trace);
|
||||
void gst_trace_flush (GstTrace *trace);
|
||||
void gst_trace_text_flush (GstTrace *trace);
|
||||
|
||||
#define gst_trace_get_size(trace) ((trace)->bufsize)
|
||||
#define gst_trace_get_offset(trace) ((trace)->bufoffset)
|
||||
#define gst_trace_get_remaining(trace) ((trace)->bufsize - (trace)->bufoffset)
|
||||
|
@ -74,13 +73,11 @@ typedef enum
|
|||
{
|
||||
GST_ALLOC_TRACE_LIVE = (1 << 0),
|
||||
GST_ALLOC_TRACE_MEM_LIVE = (1 << 1)
|
||||
}
|
||||
GstAllocTraceFlags;
|
||||
} GstAllocTraceFlags;
|
||||
|
||||
typedef struct _GstAllocTrace GstAllocTrace;
|
||||
|
||||
struct _GstAllocTrace
|
||||
{
|
||||
struct _GstAllocTrace {
|
||||
gchar *name;
|
||||
gint flags;
|
||||
|
||||
|
@ -98,8 +95,7 @@ void gst_alloc_trace_set_flags_all (GstAllocTraceFlags flags);
|
|||
|
||||
GstAllocTrace* gst_alloc_trace_get (const gchar *name);
|
||||
void gst_alloc_trace_print (const GstAllocTrace *trace);
|
||||
void gst_alloc_trace_set_flags (GstAllocTrace * trace,
|
||||
GstAllocTraceFlags flags);
|
||||
void gst_alloc_trace_set_flags (GstAllocTrace *trace, GstAllocTraceFlags flags);
|
||||
|
||||
|
||||
#ifndef GST_DISABLE_ALLOC_TRACE
|
||||
|
@ -131,7 +127,6 @@ G_STMT_START { \
|
|||
|
||||
#ifndef GST_DISABLE_TRACE
|
||||
extern gint _gst_trace_on;
|
||||
|
||||
#define gst_trace_add_entry(trace,seq,data,msg) \
|
||||
if (_gst_trace_on) { \
|
||||
_gst_trace_add_entry(trace,(guint32)seq,(guint32)data,msg); \
|
||||
|
@ -173,4 +168,5 @@ extern gint _gst_trace_on;
|
|||
#endif /* GST_DISABLE_TRACE */
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TRACE_H__ */
|
||||
|
|
|
@ -23,19 +23,19 @@
|
|||
#include <glib.h>
|
||||
#include "gstmacros.h"
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstTrashStack GstTrashStack;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstTrashStack GstTrashStack;
|
||||
typedef struct _GstTrashStackElement GstTrashStackElement;
|
||||
|
||||
struct _GstTrashStackElement
|
||||
{
|
||||
struct _GstTrashStackElement {
|
||||
GstTrashStackElement *next;
|
||||
};
|
||||
|
||||
typedef volatile gpointer gst_vgpointer;/* gtk-doc volatile workaround */
|
||||
typedef volatile gulong gst_vgulong; /* gtk-doc volatile workaround */
|
||||
|
||||
struct _GstTrashStack
|
||||
{
|
||||
struct _GstTrashStack {
|
||||
gst_vgpointer head;
|
||||
gst_vgulong count; /* for the ABA problem */
|
||||
GMutex *lock; /* lock for C fallback */
|
||||
|
@ -77,10 +77,15 @@ gst_trash_stack_destroy (GstTrashStack * stack)
|
|||
GST_INLINE_FUNC void
|
||||
gst_trash_stack_push (GstTrashStack *stack, gpointer mem)
|
||||
{
|
||||
__asm__ __volatile__ ("1: \n\t" " movl %2, (%1); \n\t" /* mem->next == stack->head */
|
||||
__asm__ __volatile__ (
|
||||
"1: \n\t"
|
||||
" movl %2, (%1); \n\t" /* mem->next == stack->head */
|
||||
SMP_LOCK "cmpxchg %1, %0; \n\t" /* if head unchanged, move mem into it */
|
||||
" jnz 1b; \n" /* head changed, retry */
|
||||
::"m" (*stack), "r" (mem), "a" (stack->head)
|
||||
:
|
||||
: "m" (*stack),
|
||||
"r" (mem),
|
||||
"a" (stack->head)
|
||||
);
|
||||
}
|
||||
|
||||
|
@ -95,16 +100,23 @@ gst_trash_stack_pop (GstTrashStack * stack)
|
|||
* into place. This is usually solved using a counter which makes it highly
|
||||
* inlikely that we manage to grab the wrong head->next value.
|
||||
*/
|
||||
__asm__ __volatile__ (" testl %%eax, %%eax; \n\t" /* if (head == NULL) return */
|
||||
" jz 20f; \n\t" "10: \n\t" " movl (%%eax), %%ebx; \n\t" /* take value pointed to by head (head->next) */
|
||||
__asm__ __volatile__ (
|
||||
" testl %%eax, %%eax; \n\t" /* if (head == NULL) return */
|
||||
" jz 20f; \n\t"
|
||||
"10: \n\t"
|
||||
" movl (%%eax), %%ebx; \n\t" /* take value pointed to by head (head->next) */
|
||||
" movl %%edx, %%ecx; \n\t" /* take counter */
|
||||
" incl %%ecx; \n\t" /* and increment */
|
||||
SMP_LOCK "cmpxchg8b %1; \n\t" /* if eax:edx == *stack, move ebx:ecx to *stack,
|
||||
* else *stack is moved into eax:edx again... */
|
||||
" jnz 10b; \n\t" /* ... and we retry */
|
||||
"20: \n":"=a" (head)
|
||||
:"m" (*stack), "a" (stack->head), "d" (stack->count)
|
||||
:"ecx", "ebx");
|
||||
"20: \n"
|
||||
: "=a" (head)
|
||||
: "m" (*stack),
|
||||
"a" (stack->head),
|
||||
"d" (stack->count)
|
||||
: "ecx", "ebx"
|
||||
);
|
||||
|
||||
return head;
|
||||
}
|
||||
|
@ -178,4 +190,5 @@ gst_trash_stack_free (GstTrashStack * stack)
|
|||
#endif /* defined (GST_CAN_INLINE) || defined (__GST_TRASH_STACK_C__)*/
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TRASH_STACK_H__ */
|
||||
|
|
|
@ -30,33 +30,36 @@
|
|||
#include <gst/gsttypes.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_TYPE_FIND_FACTORY (gst_type_find_factory_get_type())
|
||||
#define GST_TYPE_FIND_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_TYPE_FIND_FACTORY, GstTypeFindFactory))
|
||||
#define GST_IS_TYPE_FIND_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_TYPE_FIND_FACTORY))
|
||||
#define GST_TYPE_FIND_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_TYPE_FIND_FACTORY, GstTypeFindFactoryClass))
|
||||
#define GST_IS_TYPE_FIND_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_TYPE_FIND_FACTORY))
|
||||
#define GST_TYPE_FIND_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_TYPE_FIND_FACTORY, GstTypeFindFactoryClass))
|
||||
|
||||
typedef struct _GstTypeFind GstTypeFind;
|
||||
typedef struct _GstTypeFindFactory GstTypeFindFactory;
|
||||
typedef struct _GstTypeFindFactoryClass GstTypeFindFactoryClass;
|
||||
|
||||
typedef void (* GstTypeFindFunction) (GstTypeFind *find, gpointer data);
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_TYPE_FIND_MINIMUM = 1,
|
||||
GST_TYPE_FIND_POSSIBLE = 50,
|
||||
GST_TYPE_FIND_LIKELY = 80,
|
||||
GST_TYPE_FIND_NEARLY_CERTAIN = 99,
|
||||
GST_TYPE_FIND_MAXIMUM = 100,
|
||||
}
|
||||
GstTypeFindProbability;
|
||||
} GstTypeFindProbability;
|
||||
|
||||
struct _GstTypeFind
|
||||
{
|
||||
struct _GstTypeFind {
|
||||
/* private to the caller of the typefind function */
|
||||
guint8 *(*peek) (gpointer data, gint64 offset, guint size);
|
||||
void (*suggest) (gpointer data, guint probability, const GstCaps * caps);
|
||||
guint8 * (* peek) (gpointer data,
|
||||
gint64 offset,
|
||||
guint size);
|
||||
void (* suggest) (gpointer data,
|
||||
guint probability,
|
||||
const GstCaps * caps);
|
||||
|
||||
gpointer data;
|
||||
|
||||
|
@ -67,8 +70,7 @@ struct _GstTypeFind
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstTypeFindFactory
|
||||
{
|
||||
struct _GstTypeFindFactory {
|
||||
GstPluginFeature feature;
|
||||
/* <private> */
|
||||
|
||||
|
@ -81,8 +83,7 @@ struct _GstTypeFindFactory
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstTypeFindFactoryClass
|
||||
{
|
||||
struct _GstTypeFindFactoryClass {
|
||||
GstPluginFeatureClass parent;
|
||||
/* <private> */
|
||||
|
||||
|
@ -90,9 +91,12 @@ struct _GstTypeFindFactoryClass
|
|||
};
|
||||
|
||||
/* typefind function interface */
|
||||
guint8 *gst_type_find_peek (GstTypeFind * find, gint64 offset, guint size);
|
||||
guint8 * gst_type_find_peek (GstTypeFind * find,
|
||||
gint64 offset,
|
||||
guint size);
|
||||
void gst_type_find_suggest (GstTypeFind * find,
|
||||
guint probability, const GstCaps * caps);
|
||||
guint probability,
|
||||
const GstCaps * caps);
|
||||
guint64 gst_type_find_get_length (GstTypeFind * find);
|
||||
|
||||
/* registration interface */
|
||||
|
@ -100,7 +104,9 @@ gboolean gst_type_find_register (GstPlugin * plugin,
|
|||
const gchar * name,
|
||||
guint rank,
|
||||
GstTypeFindFunction func,
|
||||
gchar ** extensions, const GstCaps * possible_caps, gpointer data);
|
||||
gchar ** extensions,
|
||||
const GstCaps * possible_caps,
|
||||
gpointer data);
|
||||
|
||||
/* typefinding interface */
|
||||
|
||||
|
@ -108,13 +114,12 @@ GType gst_type_find_factory_get_type (void);
|
|||
|
||||
GList * gst_type_find_factory_get_list (void);
|
||||
|
||||
gchar **gst_type_find_factory_get_extensions (const GstTypeFindFactory *
|
||||
factory);
|
||||
const GstCaps *gst_type_find_factory_get_caps (const GstTypeFindFactory *
|
||||
factory);
|
||||
gchar ** gst_type_find_factory_get_extensions (const GstTypeFindFactory *factory);
|
||||
const GstCaps * gst_type_find_factory_get_caps (const GstTypeFindFactory *factory);
|
||||
void gst_type_find_factory_call_function (const GstTypeFindFactory *factory,
|
||||
GstTypeFind *find);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TYPE_FIND_H__ */
|
||||
|
|
|
@ -22,7 +22,9 @@
|
|||
|
||||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstObject GstObject;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef struct _GstObject GstObject;
|
||||
typedef struct _GstObjectClass GstObjectClass;
|
||||
typedef struct _GstPad GstPad;
|
||||
typedef struct _GstPadClass GstPadClass;
|
||||
|
@ -36,31 +38,25 @@ typedef struct _GstScheduler GstScheduler;
|
|||
typedef struct _GstSchedulerClass GstSchedulerClass;
|
||||
typedef struct _GstEvent GstEvent;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_STATE_VOID_PENDING = 0,
|
||||
GST_STATE_NULL = (1 << 0),
|
||||
GST_STATE_READY = (1 << 1),
|
||||
GST_STATE_PAUSED = (1 << 2),
|
||||
GST_STATE_PLAYING = (1 << 3)
|
||||
}
|
||||
GstElementState;
|
||||
} GstElementState;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_STATE_FAILURE = 0,
|
||||
GST_STATE_SUCCESS = 1,
|
||||
GST_STATE_ASYNC = 2
|
||||
}
|
||||
GstElementStateReturn;
|
||||
} GstElementStateReturn;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_RESULT_OK,
|
||||
GST_RESULT_NOK,
|
||||
GST_RESULT_NOT_IMPL
|
||||
}
|
||||
GstResult;
|
||||
} GstResult;
|
||||
|
||||
#define GST_RANK_PRIMARY 256
|
||||
#define GST_RANK_SECONDARY 128
|
||||
|
@ -71,4 +67,5 @@ GstResult;
|
|||
#define GST_PADDING_INIT { 0 }
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_TYPES_H__ */
|
||||
|
|
30
gst/gsturi.h
30
gst/gsturi.h
|
@ -28,13 +28,13 @@
|
|||
#include <gst/gstelement.h>
|
||||
#include <gst/gstpluginfeature.h>
|
||||
|
||||
G_BEGIN_DECLS typedef enum
|
||||
{
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef enum {
|
||||
GST_URI_UNKNOWN,
|
||||
GST_URI_SINK,
|
||||
GST_URI_SRC
|
||||
}
|
||||
GstURIType;
|
||||
} GstURIType;
|
||||
|
||||
#define GST_URI_TYPE_IS_VALID(type) ((type) == GST_URI_SRC || (type) == GST_URI_SINK)
|
||||
|
||||
|
@ -48,12 +48,12 @@ GstURIType;
|
|||
typedef struct _GstURIHandler GstURIHandler;
|
||||
typedef struct _GstURIHandlerInterface GstURIHandlerInterface;
|
||||
|
||||
struct _GstURIHandlerInterface
|
||||
{
|
||||
struct _GstURIHandlerInterface {
|
||||
GTypeInterface parent;
|
||||
|
||||
/* signals */
|
||||
void (*new_uri) (GstURIHandler * handler, const gchar * uri);
|
||||
void (* new_uri) (GstURIHandler * handler,
|
||||
const gchar * uri);
|
||||
/* idea for the future ?
|
||||
gboolean (* require_password) (GstURIHandler * handler,
|
||||
gchar ** username,
|
||||
|
@ -68,7 +68,8 @@ struct _GstURIHandlerInterface
|
|||
|
||||
/* using the interface */
|
||||
G_CONST_RETURN gchar *(* get_uri) (GstURIHandler * handler);
|
||||
gboolean (*set_uri) (GstURIHandler * handler, const gchar * uri);
|
||||
gboolean (* set_uri) (GstURIHandler * handler,
|
||||
const gchar * uri);
|
||||
|
||||
/* we might want to add functions here to query features, someone with gnome-vfs knowledge go ahead */
|
||||
|
||||
|
@ -81,10 +82,12 @@ gboolean gst_uri_protocol_is_valid (const gchar * protocol);
|
|||
gboolean gst_uri_is_valid (const gchar * uri);
|
||||
gchar * gst_uri_get_protocol (const gchar * uri);
|
||||
gchar * gst_uri_get_location (const gchar * uri);
|
||||
gchar *gst_uri_construct (const gchar * protocol, const gchar * location);
|
||||
gchar * gst_uri_construct (const gchar * protocol,
|
||||
const gchar * location);
|
||||
|
||||
GstElement * gst_element_make_from_uri (const GstURIType type,
|
||||
const gchar * uri, const gchar * elementname);
|
||||
const gchar * uri,
|
||||
const gchar * elementname);
|
||||
|
||||
/* accessing the interface */
|
||||
GType gst_uri_handler_get_type (void);
|
||||
|
@ -92,8 +95,11 @@ GType gst_uri_handler_get_type (void);
|
|||
guint gst_uri_handler_get_uri_type (GstURIHandler * handler);
|
||||
gchar ** gst_uri_handler_get_protocols (GstURIHandler * handler);
|
||||
G_CONST_RETURN gchar * gst_uri_handler_get_uri (GstURIHandler * handler);
|
||||
gboolean gst_uri_handler_set_uri (GstURIHandler * handler, const gchar * uri);
|
||||
void gst_uri_handler_new_uri (GstURIHandler * handler, const gchar * uri);
|
||||
gboolean gst_uri_handler_set_uri (GstURIHandler * handler,
|
||||
const gchar * uri);
|
||||
void gst_uri_handler_new_uri (GstURIHandler * handler,
|
||||
const gchar * uri);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_URI_H__ */
|
||||
|
|
|
@ -27,9 +27,11 @@
|
|||
#include <glib.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* a static type for making uri element properties */
|
||||
#define GST_TYPE_URI (gst_uri_get_uri_type())
|
||||
GType gst_uri_get_uri_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_URI_TYPE_H */
|
||||
|
|
|
@ -28,10 +28,9 @@
|
|||
#include <gst/gstelement.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
void gst_util_set_value_from_string (GValue * value,
|
||||
const gchar * value_str);
|
||||
void gst_util_set_object_arg (GObject * object, const gchar * name,
|
||||
const gchar * value);
|
||||
|
||||
void gst_util_set_value_from_string (GValue *value, const gchar *value_str);
|
||||
void gst_util_set_object_arg (GObject *object, const gchar *name, const gchar *value);
|
||||
|
||||
void gst_util_dump_mem (guchar *mem, guint size);
|
||||
|
||||
|
@ -106,4 +105,5 @@ type_as_function ## _get_type (void) \
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_UTILS_H__ */
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <gst/gstcaps.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
typedef int (* GstValueCompareFunc) (const GValue *value1,
|
||||
const GValue *value2);
|
||||
typedef char * (* GstValueSerializeFunc) (const GValue *value1);
|
||||
|
@ -34,8 +35,7 @@ typedef int (*GstValueIntersectFunc) (GValue * dest, const GValue * value1,
|
|||
const GValue *value2);
|
||||
|
||||
typedef struct _GstValueTable GstValueTable;
|
||||
struct _GstValueTable
|
||||
{
|
||||
struct _GstValueTable {
|
||||
GType type;
|
||||
GstValueCompareFunc compare;
|
||||
GstValueSerializeFunc serialize;
|
||||
|
@ -78,14 +78,11 @@ extern GType gst_type_list;
|
|||
|
||||
/* list */
|
||||
|
||||
void gst_value_list_prepend_value (GValue * value,
|
||||
const GValue * prepend_value);
|
||||
void gst_value_list_prepend_value (GValue *value, const GValue *prepend_value);
|
||||
void gst_value_list_append_value (GValue *value, const GValue *append_value);
|
||||
guint gst_value_list_get_size (const GValue *value);
|
||||
G_CONST_RETURN GValue *gst_value_list_get_value (const GValue * value,
|
||||
guint index);
|
||||
void gst_value_list_concat (GValue * dest, const GValue * value1,
|
||||
const GValue * value2);
|
||||
G_CONST_RETURN GValue *gst_value_list_get_value (const GValue *value, guint index);
|
||||
void gst_value_list_concat (GValue *dest, const GValue *value1, const GValue *value2);
|
||||
|
||||
/* fourcc */
|
||||
|
||||
|
@ -116,18 +113,14 @@ int gst_value_compare (const GValue * value1, const GValue * value2);
|
|||
/* union */
|
||||
|
||||
gboolean gst_value_can_union (const GValue *value1, const GValue *value2);
|
||||
gboolean gst_value_union (GValue * dest, const GValue * value1,
|
||||
const GValue * value2);
|
||||
void gst_value_register_union_func (GType type1, GType type2,
|
||||
GstValueUnionFunc func);
|
||||
gboolean gst_value_union (GValue *dest, const GValue *value1, const GValue *value2);
|
||||
void gst_value_register_union_func (GType type1, GType type2, GstValueUnionFunc func);
|
||||
|
||||
/* intersection */
|
||||
|
||||
gboolean gst_value_can_intersect (const GValue *value1, const GValue *value2);
|
||||
gboolean gst_value_intersect (GValue * dest, const GValue * value1,
|
||||
const GValue * value2);
|
||||
void gst_value_register_intersect_func (GType type1, GType type2,
|
||||
GstValueIntersectFunc func);
|
||||
gboolean gst_value_intersect (GValue *dest, const GValue *value1, const GValue *value2);
|
||||
void gst_value_register_intersect_func (GType type1, GType type2, GstValueIntersectFunc func);
|
||||
|
||||
/* */
|
||||
|
||||
|
@ -140,4 +133,7 @@ gboolean gst_value_deserialize (GValue * dest, const gchar * src);
|
|||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
|
16
gst/gstxml.h
16
gst/gstxml.h
|
@ -30,17 +30,19 @@
|
|||
#include <gst/gstelement.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_XML (gst_xml_get_type ())
|
||||
#define GST_XML(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_XML, GstXML))
|
||||
#define GST_IS_XML(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_XML))
|
||||
#define GST_XML_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_XML, GstXMLClass))
|
||||
#define GST_IS_XML_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_XML))
|
||||
|
||||
#define GST_XML_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), GST_TYPE_XML, GstXMLClass))
|
||||
|
||||
typedef struct _GstXML GstXML;
|
||||
typedef struct _GstXMLClass GstXMLClass;
|
||||
|
||||
struct _GstXML
|
||||
{
|
||||
struct _GstXML {
|
||||
GstObject object;
|
||||
|
||||
GList *topelements;
|
||||
|
@ -52,8 +54,7 @@ struct _GstXML
|
|||
|
||||
typedef struct _GstXMLNs GstXMLNs;
|
||||
|
||||
struct _GstXMLClass
|
||||
{
|
||||
struct _GstXMLClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* signal callbacks */
|
||||
|
@ -75,10 +76,8 @@ gint gst_xml_write_file (GstElement * element, FILE * out);
|
|||
GstXML* gst_xml_new (void);
|
||||
|
||||
gboolean gst_xml_parse_doc (GstXML *xml, xmlDocPtr doc, const guchar *root);
|
||||
gboolean gst_xml_parse_file (GstXML * xml, const guchar * fname,
|
||||
const guchar * root);
|
||||
gboolean gst_xml_parse_memory (GstXML * xml, guchar * buffer, guint size,
|
||||
const gchar * root);
|
||||
gboolean gst_xml_parse_file (GstXML *xml, const guchar *fname, const guchar *root);
|
||||
gboolean gst_xml_parse_memory (GstXML *xml, guchar *buffer, guint size, const gchar *root);
|
||||
|
||||
|
||||
GstElement* gst_xml_get_element (GstXML *xml, const guchar *name);
|
||||
|
@ -87,6 +86,7 @@ GList *gst_xml_get_topelements (GstXML * xml);
|
|||
GstElement* gst_xml_make_element (xmlNodePtr cur, GstObject *parent);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#else /* GST_DISABLE_LOADSAVE */
|
||||
|
||||
#pragma GCC poison gst_xml_write
|
||||
|
|
|
@ -8,8 +8,7 @@
|
|||
# include "config.h"
|
||||
#endif
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
GstElement *src;
|
||||
GstElement *sink;
|
||||
gchar *src_name;
|
||||
|
@ -17,22 +16,18 @@ typedef struct
|
|||
GSList *src_pads;
|
||||
GSList *sink_pads;
|
||||
GstCaps *caps;
|
||||
}
|
||||
link_t;
|
||||
} link_t;
|
||||
|
||||
typedef struct
|
||||
{
|
||||
typedef struct {
|
||||
GSList *elements;
|
||||
GstElement *first;
|
||||
GstElement *last;
|
||||
link_t *front;
|
||||
link_t *back;
|
||||
}
|
||||
chain_t;
|
||||
} chain_t;
|
||||
|
||||
typedef struct _graph_t graph_t;
|
||||
struct _graph_t
|
||||
{
|
||||
struct _graph_t {
|
||||
chain_t *chain; /* links are supposed to be done now */
|
||||
GSList *links;
|
||||
GError **error;
|
||||
|
@ -56,7 +51,6 @@ link_t *__gst_parse_link_new ();
|
|||
void __gst_parse_link_free (link_t *data);
|
||||
chain_t *__gst_parse_chain_new ();
|
||||
void __gst_parse_chain_free (chain_t *data);
|
||||
|
||||
# define gst_parse_strdup __gst_parse_strdup
|
||||
# define gst_parse_strfree __gst_parse_strfree
|
||||
# define gst_parse_link_new __gst_parse_link_new
|
||||
|
|
|
@ -27,6 +27,7 @@
|
|||
#include <gst/gstregistry.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_XML_REGISTRY \
|
||||
(gst_xml_registry_get_type())
|
||||
#define GST_XML_REGISTRY(obj) \
|
||||
|
@ -37,11 +38,11 @@ G_BEGIN_DECLS
|
|||
(G_TYPE_CHECK_INSTANCE_TYPE((obj),GST_TYPE_XML_REGISTRY))
|
||||
#define GST_IS_XML_REGISTRY_CLASS(obj) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE((klass),GST_TYPE_XML_REGISTRY))
|
||||
|
||||
typedef struct _GstXMLRegistry GstXMLRegistry;
|
||||
typedef struct _GstXMLRegistryClass GstXMLRegistryClass;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_XML_REGISTRY_NONE,
|
||||
GST_XML_REGISTRY_TOP,
|
||||
GST_XML_REGISTRY_PATHS,
|
||||
|
@ -53,33 +54,33 @@ typedef enum
|
|||
GST_XML_REGISTRY_CAPS,
|
||||
GST_XML_REGISTRY_STRUCTURE,
|
||||
GST_XML_REGISTRY_PROPERTIES
|
||||
}
|
||||
GstXMLRegistryState;
|
||||
} GstXMLRegistryState;
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_XML_REGISTRY_READ,
|
||||
GST_XML_REGISTRY_WRITE
|
||||
}
|
||||
GstXMLRegistryMode;
|
||||
} GstXMLRegistryMode;
|
||||
|
||||
typedef void (*GstXMLRegistryGetPerms) (GstXMLRegistry *registry);
|
||||
typedef void (*GstXMLRegistryAddPathList) (GstXMLRegistry *registry);
|
||||
typedef gboolean (*GstXMLRegistryParser) (GMarkupParseContext *context,
|
||||
const gchar *tag,
|
||||
const gchar *text,
|
||||
gsize text_len, GstXMLRegistry * registry, GError ** error);
|
||||
gsize text_len,
|
||||
GstXMLRegistry *registry,
|
||||
GError **error);
|
||||
|
||||
typedef gboolean (*GstXMLRegistryOpen) (GstXMLRegistry *registry,
|
||||
GstXMLRegistryMode mode);
|
||||
typedef gboolean (*GstXMLRegistryLoad) (GstXMLRegistry *registry,
|
||||
gchar * dest, gssize * size);
|
||||
gchar *dest,
|
||||
gssize *size);
|
||||
typedef gboolean (*GstXMLRegistrySave) (GstXMLRegistry *registry,
|
||||
gchar * format, ...);
|
||||
gchar *format,
|
||||
...);
|
||||
typedef gboolean (*GstXMLRegistryClose) (GstXMLRegistry *registry);
|
||||
|
||||
struct _GstXMLRegistry
|
||||
{
|
||||
struct _GstXMLRegistry {
|
||||
GstRegistry object;
|
||||
|
||||
gchar *location;
|
||||
|
@ -109,8 +110,7 @@ struct _GstXMLRegistry
|
|||
gchar *list_name;
|
||||
};
|
||||
|
||||
struct _GstXMLRegistryClass
|
||||
{
|
||||
struct _GstXMLRegistryClass {
|
||||
GstRegistryClass parent_class;
|
||||
|
||||
GstXMLRegistryGetPerms get_perms_func;
|
||||
|
@ -128,4 +128,6 @@ GType gst_xml_registry_get_type (void);
|
|||
GstRegistry* gst_xml_registry_new (const gchar *name, const gchar *location);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_XML_REGISTRY_H__ */
|
||||
|
||||
|
|
101
include/mmx.h
101
include/mmx.h
|
@ -83,8 +83,7 @@
|
|||
by LL and unsigned long long values by ULL, lest
|
||||
they be truncated by the compiler)
|
||||
*/
|
||||
typedef union
|
||||
{
|
||||
typedef union {
|
||||
long long q; /* Quadword (64-bit) value */
|
||||
unsigned long long uq; /* Unsigned Quadword */
|
||||
int d[2]; /* 2 Doubleword (32-bit) values */
|
||||
|
@ -94,8 +93,7 @@ typedef union
|
|||
char b[8]; /* 8 Byte (8-bit) values */
|
||||
unsigned char ub[8]; /* 8 Unsigned Byte */
|
||||
float s[2]; /* Single-precision (32-bit) value */
|
||||
}
|
||||
mmx_t;
|
||||
} mmx_t;
|
||||
|
||||
|
||||
|
||||
|
@ -114,66 +112,117 @@ mm_support (void)
|
|||
__asm__ __volatile__ (
|
||||
/* See if CPUID instruction is supported ... */
|
||||
/* ... Get copies of EFLAGS into eax and ecx */
|
||||
"pushf\n\t" "popl %%eax\n\t" "movl %%eax, %%ecx\n\t"
|
||||
"pushf\n\t"
|
||||
"popl %%eax\n\t"
|
||||
"movl %%eax, %%ecx\n\t"
|
||||
|
||||
/* ... Toggle the ID bit in one copy and store */
|
||||
/* to the EFLAGS reg */
|
||||
"xorl $0x200000, %%eax\n\t" "push %%eax\n\t" "popf\n\t"
|
||||
"xorl $0x200000, %%eax\n\t"
|
||||
"push %%eax\n\t"
|
||||
"popf\n\t"
|
||||
|
||||
/* ... Get the (hopefully modified) EFLAGS */
|
||||
"pushf\n\t" "popl %%eax\n\t"
|
||||
"pushf\n\t"
|
||||
"popl %%eax\n\t"
|
||||
|
||||
/* ... Compare and test result */
|
||||
"xorl %%eax, %%ecx\n\t" "testl $0x200000, %%ecx\n\t" "jz NotSupported1\n\t" /* Nothing supported */
|
||||
"xorl %%eax, %%ecx\n\t"
|
||||
"testl $0x200000, %%ecx\n\t"
|
||||
"jz NotSupported1\n\t" /* Nothing supported */
|
||||
|
||||
|
||||
/* Get standard CPUID information, and
|
||||
go to a specific vendor section */
|
||||
"movl $0, %%eax\n\t" "cpuid\n\t"
|
||||
"movl $0, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
|
||||
/* Check for Intel */
|
||||
"cmpl $0x756e6547, %%ebx\n\t"
|
||||
"jne TryAMD\n\t"
|
||||
"cmpl $0x49656e69, %%edx\n\t"
|
||||
"jne TryAMD\n\t"
|
||||
"cmpl $0x6c65746e, %%ecx\n" "jne TryAMD\n\t" "jmp Intel\n\t"
|
||||
"cmpl $0x6c65746e, %%ecx\n"
|
||||
"jne TryAMD\n\t"
|
||||
"jmp Intel\n\t"
|
||||
|
||||
/* Check for AMD */
|
||||
"\nTryAMD:\n\t"
|
||||
"cmpl $0x68747541, %%ebx\n\t"
|
||||
"jne TryCyrix\n\t"
|
||||
"cmpl $0x69746e65, %%edx\n\t"
|
||||
"jne TryCyrix\n\t"
|
||||
"cmpl $0x444d4163, %%ecx\n" "jne TryCyrix\n\t" "jmp AMD\n\t"
|
||||
"cmpl $0x444d4163, %%ecx\n"
|
||||
"jne TryCyrix\n\t"
|
||||
"jmp AMD\n\t"
|
||||
|
||||
/* Check for Cyrix */
|
||||
"\nTryCyrix:\n\t"
|
||||
"cmpl $0x69727943, %%ebx\n\t"
|
||||
"jne NotSupported2\n\t"
|
||||
"cmpl $0x736e4978, %%edx\n\t"
|
||||
"jne NotSupported3\n\t"
|
||||
"cmpl $0x64616574, %%ecx\n\t" "jne NotSupported4\n\t"
|
||||
"cmpl $0x64616574, %%ecx\n\t"
|
||||
"jne NotSupported4\n\t"
|
||||
/* Drop through to Cyrix... */
|
||||
|
||||
|
||||
/* Cyrix Section */
|
||||
/* See if extended CPUID is supported */
|
||||
"movl $0x80000000, %%eax\n\t" "cpuid\n\t" "cmpl $0x80000000, %%eax\n\t" "jl MMXtest\n\t" /* Try standard CPUID instead */
|
||||
"movl $0x80000000, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"cmpl $0x80000000, %%eax\n\t"
|
||||
"jl MMXtest\n\t" /* Try standard CPUID instead */
|
||||
|
||||
/* Extended CPUID supported, so get extended features */
|
||||
"movl $0x80000001, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%eax\n\t" /* Test for MMX */
|
||||
"movl $0x80000001, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%eax\n\t" /* Test for MMX */
|
||||
"jz NotSupported5\n\t" /* MMX not supported */
|
||||
"testl $0x01000000, %%eax\n\t" /* Test for Ext'd MMX */
|
||||
"jnz EMMXSupported\n\t" "movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n" "EMMXSupported:\n\t" "movl $3, %0:\n\n\t" /* EMMX and MMX Supported */
|
||||
"jnz EMMXSupported\n\t"
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n"
|
||||
"EMMXSupported:\n\t"
|
||||
"movl $3, %0:\n\n\t" /* EMMX and MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
|
||||
/* AMD Section */
|
||||
"AMD:\n\t"
|
||||
|
||||
/* See if extended CPUID is supported */
|
||||
"movl $0x80000000, %%eax\n\t" "cpuid\n\t" "cmpl $0x80000000, %%eax\n\t" "jl MMXtest\n\t" /* Try standard CPUID instead */
|
||||
"movl $0x80000000, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"cmpl $0x80000000, %%eax\n\t"
|
||||
"jl MMXtest\n\t" /* Try standard CPUID instead */
|
||||
|
||||
/* Extended CPUID supported, so get extended features */
|
||||
"movl $0x80000001, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"movl $0x80000001, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"jz NotSupported6\n\t" /* MMX not supported */
|
||||
"testl $0x80000000, %%edx\n\t" /* Test for 3DNow! */
|
||||
"jnz ThreeDNowSupported\n\t" "movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n" "ThreeDNowSupported:\n\t" "movl $5, %0:\n\n\t" /* 3DNow! and MMX Supported */
|
||||
"jnz ThreeDNowSupported\n\t"
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n"
|
||||
"ThreeDNowSupported:\n\t"
|
||||
"movl $5, %0:\n\n\t" /* 3DNow! and MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
|
||||
/* Intel Section */
|
||||
"Intel:\n\t"
|
||||
|
||||
/* Check for MMX */
|
||||
"MMXtest:\n\t" "movl $1, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"MMXtest:\n\t"
|
||||
"movl $1, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"jz NotSupported7\n\t" /* MMX Not supported */
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
/* Nothing supported */
|
||||
"\nNotSupported1:\n\t"
|
||||
"#movl $101, %0:\n\n\t"
|
||||
|
@ -188,9 +237,14 @@ mm_support (void)
|
|||
"\nNotSupported6:\n\t"
|
||||
"#movl $106, %0:\n\n\t"
|
||||
"\nNotSupported7:\n\t"
|
||||
"#movl $107, %0:\n\n\t" "movl $0, %0:\n\n\t" "Return:\n\t":"=a" (rval)
|
||||
"#movl $107, %0:\n\n\t"
|
||||
"movl $0, %0:\n\n\t"
|
||||
|
||||
"Return:\n\t"
|
||||
: "=a" (rval)
|
||||
: /* no input */
|
||||
:"eax", "ebx", "ecx", "edx");
|
||||
: "eax", "ebx", "ecx", "edx"
|
||||
);
|
||||
|
||||
/* Return */
|
||||
return(rval);
|
||||
|
@ -668,3 +722,4 @@ mmx_ok (void)
|
|||
#endif
|
||||
|
||||
#endif
|
||||
|
||||
|
|
105
include/sse.h
105
include/sse.h
|
@ -43,11 +43,9 @@
|
|||
by LL and unsigned long long values by ULL, lest
|
||||
they be truncated by the compiler)
|
||||
*/
|
||||
typedef union
|
||||
{
|
||||
typedef union {
|
||||
float sf[4]; /* Single-precision (32-bit) value */
|
||||
}
|
||||
__attribute__ ((aligned (16))) sse_t; /* On a 16 byte (128-bit) boundary */
|
||||
} __attribute__ ((aligned (16))) sse_t; /* On a 16 byte (128-bit) boundary */
|
||||
|
||||
|
||||
#if 0
|
||||
|
@ -67,38 +65,61 @@ mm_support (void)
|
|||
__asm__ __volatile__ (
|
||||
/* See if CPUID instruction is supported ... */
|
||||
/* ... Get copies of EFLAGS into eax and ecx */
|
||||
"pushf\n\t" "popl %%eax\n\t" "movl %%eax, %%ecx\n\t"
|
||||
"pushf\n\t"
|
||||
"popl %%eax\n\t"
|
||||
"movl %%eax, %%ecx\n\t"
|
||||
|
||||
/* ... Toggle the ID bit in one copy and store */
|
||||
/* to the EFLAGS reg */
|
||||
"xorl $0x200000, %%eax\n\t" "push %%eax\n\t" "popf\n\t"
|
||||
"xorl $0x200000, %%eax\n\t"
|
||||
"push %%eax\n\t"
|
||||
"popf\n\t"
|
||||
|
||||
/* ... Get the (hopefully modified) EFLAGS */
|
||||
"pushf\n\t" "popl %%eax\n\t"
|
||||
"pushf\n\t"
|
||||
"popl %%eax\n\t"
|
||||
|
||||
/* ... Compare and test result */
|
||||
"xorl %%eax, %%ecx\n\t" "testl $0x200000, %%ecx\n\t" "jz NotSupported1\n\t" /* CPUID not supported */
|
||||
"xorl %%eax, %%ecx\n\t"
|
||||
"testl $0x200000, %%ecx\n\t"
|
||||
"jz NotSupported1\n\t" /* CPUID not supported */
|
||||
|
||||
|
||||
/* Get standard CPUID information, and
|
||||
go to a specific vendor section */
|
||||
"movl $0, %%eax\n\t" "cpuid\n\t"
|
||||
"movl $0, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
|
||||
/* Check for Intel */
|
||||
"cmpl $0x756e6547, %%ebx\n\t"
|
||||
"jne TryAMD\n\t"
|
||||
"cmpl $0x49656e69, %%edx\n\t"
|
||||
"jne TryAMD\n\t"
|
||||
"cmpl $0x6c65746e, %%ecx\n" "jne TryAMD\n\t" "jmp Intel\n\t"
|
||||
"cmpl $0x6c65746e, %%ecx\n"
|
||||
"jne TryAMD\n\t"
|
||||
"jmp Intel\n\t"
|
||||
|
||||
/* Check for AMD */
|
||||
"\nTryAMD:\n\t"
|
||||
"cmpl $0x68747541, %%ebx\n\t"
|
||||
"jne TryCyrix\n\t"
|
||||
"cmpl $0x69746e65, %%edx\n\t"
|
||||
"jne TryCyrix\n\t"
|
||||
"cmpl $0x444d4163, %%ecx\n" "jne TryCyrix\n\t" "jmp AMD\n\t"
|
||||
"cmpl $0x444d4163, %%ecx\n"
|
||||
"jne TryCyrix\n\t"
|
||||
"jmp AMD\n\t"
|
||||
|
||||
/* Check for Cyrix */
|
||||
"\nTryCyrix:\n\t"
|
||||
"cmpl $0x69727943, %%ebx\n\t"
|
||||
"jne NotSupported2\n\t"
|
||||
"cmpl $0x736e4978, %%edx\n\t"
|
||||
"jne NotSupported3\n\t"
|
||||
"cmpl $0x64616574, %%ecx\n\t" "jne NotSupported4\n\t"
|
||||
"cmpl $0x64616574, %%ecx\n\t"
|
||||
"jne NotSupported4\n\t"
|
||||
/* Drop through to Cyrix... */
|
||||
|
||||
|
||||
/* Cyrix Section */
|
||||
/* See if extended CPUID level 80000001 is supported */
|
||||
/* The value of CPUID/80000001 for the 6x86MX is undefined
|
||||
|
@ -108,38 +129,68 @@ mm_support (void)
|
|||
According to the table, the only CPU which supports level
|
||||
2 is also the only one which supports extended CPUID levels.
|
||||
*/
|
||||
"cmpl $0x2, %%eax\n\t" "jne MMXtest\n\t" /* Use standard CPUID instead */
|
||||
"cmpl $0x2, %%eax\n\t"
|
||||
"jne MMXtest\n\t" /* Use standard CPUID instead */
|
||||
|
||||
/* Extended CPUID supported (in theory), so get extended
|
||||
features */
|
||||
"movl $0x80000001, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%eax\n\t" /* Test for MMX */
|
||||
"movl $0x80000001, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%eax\n\t" /* Test for MMX */
|
||||
"jz NotSupported5\n\t" /* MMX not supported */
|
||||
"testl $0x01000000, %%eax\n\t" /* Test for Ext'd MMX */
|
||||
"jnz EMMXSupported\n\t" "movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n" "EMMXSupported:\n\t" "movl $3, %0:\n\n\t" /* EMMX and MMX Supported */
|
||||
"jnz EMMXSupported\n\t"
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n"
|
||||
"EMMXSupported:\n\t"
|
||||
"movl $3, %0:\n\n\t" /* EMMX and MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
|
||||
/* AMD Section */
|
||||
"AMD:\n\t"
|
||||
|
||||
/* See if extended CPUID is supported */
|
||||
"movl $0x80000000, %%eax\n\t" "cpuid\n\t" "cmpl $0x80000000, %%eax\n\t" "jl MMXtest\n\t" /* Use standard CPUID instead */
|
||||
"movl $0x80000000, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"cmpl $0x80000000, %%eax\n\t"
|
||||
"jl MMXtest\n\t" /* Use standard CPUID instead */
|
||||
|
||||
/* Extended CPUID supported, so get extended features */
|
||||
"movl $0x80000001, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"movl $0x80000001, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"jz NotSupported6\n\t" /* MMX not supported */
|
||||
"testl $0x80000000, %%edx\n\t" /* Test for 3DNow! */
|
||||
"jnz ThreeDNowSupported\n\t" "movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n" "ThreeDNowSupported:\n\t" "movl $5, %0:\n\n\t" /* 3DNow! and MMX Supported */
|
||||
"jnz ThreeDNowSupported\n\t"
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\n"
|
||||
"ThreeDNowSupported:\n\t"
|
||||
"movl $5, %0:\n\n\t" /* 3DNow! and MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
|
||||
/* Intel Section */
|
||||
"Intel:\n\t"
|
||||
|
||||
/* Check for SSE */
|
||||
"SSEtest:\n\t" "movl $1, %%eax\n\t" "cpuid\n\t" "testl $0x02000000, %%edx\n\t" /* Test for SSE */
|
||||
"SSEtest:\n\t"
|
||||
"movl $1, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x02000000, %%edx\n\t" /* Test for SSE */
|
||||
"jz MMXtest\n\t" /* SSE Not supported */
|
||||
"movl $9, %0:\n\n\t" /* SSE Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
/* Check for MMX */
|
||||
"MMXtest:\n\t" "movl $1, %%eax\n\t" "cpuid\n\t" "testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"MMXtest:\n\t"
|
||||
"movl $1, %%eax\n\t"
|
||||
"cpuid\n\t"
|
||||
"testl $0x00800000, %%edx\n\t" /* Test for MMX */
|
||||
"jz NotSupported7\n\t" /* MMX Not supported */
|
||||
"movl $1, %0:\n\n\t" /* MMX Supported */
|
||||
"jmp Return\n\t"
|
||||
|
||||
/* Nothing supported */
|
||||
"\nNotSupported1:\n\t"
|
||||
"#movl $101, %0:\n\n\t"
|
||||
|
@ -154,9 +205,14 @@ mm_support (void)
|
|||
"\nNotSupported6:\n\t"
|
||||
"#movl $106, %0:\n\n\t"
|
||||
"\nNotSupported7:\n\t"
|
||||
"#movl $107, %0:\n\n\t" "movl $0, %0:\n\n\t" "Return:\n\t":"=a" (rval)
|
||||
"#movl $107, %0:\n\n\t"
|
||||
"movl $0, %0:\n\n\t"
|
||||
|
||||
"Return:\n\t"
|
||||
: "=a" (rval)
|
||||
: /* no input */
|
||||
:"eax", "ebx", "ecx", "edx");
|
||||
: "eax", "ebx", "ecx", "edx"
|
||||
);
|
||||
|
||||
/* Return */
|
||||
return(rval);
|
||||
|
@ -934,3 +990,4 @@ sse_ok (void)
|
|||
|
||||
|
||||
#endif
|
||||
|
||||
|
|
|
@ -24,10 +24,11 @@
|
|||
#include <gst/gstpad.h>
|
||||
#include <gst/gstevent.h>
|
||||
|
||||
G_BEGIN_DECLS typedef struct _GstByteStream GstByteStream;
|
||||
G_BEGIN_DECLS
|
||||
|
||||
struct _GstByteStream
|
||||
{
|
||||
typedef struct _GstByteStream GstByteStream;
|
||||
|
||||
struct _GstByteStream {
|
||||
GstPad *pad;
|
||||
|
||||
GstEvent *event;
|
||||
|
@ -58,18 +59,16 @@ guint32 gst_bytestream_read (GstByteStream * bs, GstBuffer ** buf, guint32 len);
|
|||
guint64 gst_bytestream_tell (GstByteStream *bs);
|
||||
guint64 gst_bytestream_length (GstByteStream *bs);
|
||||
gboolean gst_bytestream_size_hint (GstByteStream *bs, guint32 size);
|
||||
gboolean gst_bytestream_seek (GstByteStream * bs, gint64 offset,
|
||||
GstSeekType type);
|
||||
gboolean gst_bytestream_seek (GstByteStream *bs, gint64 offset, GstSeekType type);
|
||||
guint32 gst_bytestream_peek (GstByteStream *bs, GstBuffer** buf, guint32 len);
|
||||
guint32 gst_bytestream_peek_bytes (GstByteStream * bs, guint8 ** data,
|
||||
guint32 len);
|
||||
guint32 gst_bytestream_peek_bytes (GstByteStream *bs, guint8** data, guint32 len);
|
||||
gboolean gst_bytestream_flush (GstByteStream *bs, guint32 len);
|
||||
void gst_bytestream_flush_fast (GstByteStream *bs, guint32 len);
|
||||
void gst_bytestream_get_status (GstByteStream * bs, guint32 * avail_out,
|
||||
GstEvent ** event_out);
|
||||
void gst_bytestream_get_status (GstByteStream *bs, guint32 *avail_out, GstEvent **event_out);
|
||||
guint64 gst_bytestream_get_timestamp (GstByteStream *bs);
|
||||
|
||||
void gst_bytestream_print_status (GstByteStream *bs);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_BYTESTREAM_H__ */
|
||||
|
|
|
@ -28,7 +28,10 @@
|
|||
#include <gst/control/dplinearinterp.h>
|
||||
#include <gst/control/unitconvert.h>
|
||||
|
||||
G_BEGIN_DECLS void gst_control_init (int *argc, char **argv[]);
|
||||
G_BEGIN_DECLS
|
||||
|
||||
void gst_control_init (int *argc, char **argv[]);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_CONTROL_H__ */
|
||||
|
|
|
@ -26,11 +26,13 @@
|
|||
#include "dparamcommon.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_DPARAM (gst_dparam_get_type ())
|
||||
#define GST_DPARAM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_DPARAM,GstDParam))
|
||||
#define GST_DPARAM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_DPARAM,GstDParam))
|
||||
#define GST_IS_DPARAM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_DPARAM))
|
||||
#define GST_IS_DPARAM_CLASS(obj) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_DPARAM))
|
||||
|
||||
#define GST_DPARAM_NAME(dparam) (GST_OBJECT_NAME(dparam))
|
||||
#define GST_DPARAM_PARENT(dparam) (GST_OBJECT_PARENT(dparam))
|
||||
#define GST_DPARAM_CHANGE_VALUE(dparam) ((dparam)->change_value)
|
||||
|
@ -43,25 +45,25 @@ G_BEGIN_DECLS
|
|||
#define GST_DPARAM_META_PARAM_SPECS(dparam) ((dparam)->meta_param_specs)
|
||||
#define GST_DPARAM_LOCK(dparam) (g_mutex_lock((dparam)->lock))
|
||||
#define GST_DPARAM_UNLOCK(dparam) (g_mutex_unlock((dparam)->lock))
|
||||
|
||||
#define GST_DPARAM_READY_FOR_UPDATE(dparam) ((dparam)->ready_for_update)
|
||||
#define GST_DPARAM_NEXT_UPDATE_TIMESTAMP(dparam) ((dparam)->next_update_timestamp)
|
||||
#define GST_DPARAM_LAST_UPDATE_TIMESTAMP(dparam) ((dparam)->last_update_timestamp)
|
||||
|
||||
#define GST_DPARAM_DO_UPDATE(dparam, timestamp, value, update_info) \
|
||||
((dparam->do_update_func)(dparam, timestamp, value, update_info))
|
||||
|
||||
typedef struct _GstDParamClass GstDParamClass;
|
||||
|
||||
|
||||
typedef enum
|
||||
{
|
||||
typedef enum {
|
||||
GST_DPARAM_UPDATE_FIRST,
|
||||
GST_DPARAM_UPDATE_NORMAL,
|
||||
} GstDParamUpdateInfo;
|
||||
|
||||
typedef void (*GstDParamDoUpdateFunction) (GstDParam * dparam, gint64 timestamp,
|
||||
GValue * value, GstDParamUpdateInfo update_info);
|
||||
typedef void (*GstDParamDoUpdateFunction) (GstDParam *dparam, gint64 timestamp, GValue *value, GstDParamUpdateInfo update_info);
|
||||
|
||||
struct _GstDParam
|
||||
{
|
||||
struct _GstDParam {
|
||||
GstObject object;
|
||||
|
||||
GstDParamDoUpdateFunction do_update_func;
|
||||
|
@ -86,8 +88,7 @@ struct _GstDParam
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstDParamClass
|
||||
{
|
||||
struct _GstDParamClass {
|
||||
GstObjectClass parent_class;
|
||||
|
||||
/* signal callbacks */
|
||||
|
@ -99,11 +100,10 @@ struct _GstDParamClass
|
|||
|
||||
GType gst_dparam_get_type (void);
|
||||
GstDParam* gst_dparam_new (GType type);
|
||||
void gst_dparam_attach (GstDParam * dparam, GstDParamManager * manager,
|
||||
GParamSpec * param_spec, gchar * unit_name);
|
||||
void gst_dparam_attach (GstDParam *dparam, GstDParamManager *manager, GParamSpec *param_spec, gchar *unit_name);
|
||||
void gst_dparam_detach (GstDParam *dparam);
|
||||
void gst_dparam_do_update_default (GstDParam * dparam, gint64 timestamp,
|
||||
GValue * value, GstDParamUpdateInfo update_info);
|
||||
void gst_dparam_do_update_default (GstDParam *dparam, gint64 timestamp, GValue *value, GstDParamUpdateInfo update_info);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_DPARAM_H__ */
|
||||
|
|
|
@ -25,16 +25,17 @@
|
|||
#include "dparam.h"
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GST_TYPE_DPSMOOTH (gst_dpsmooth_get_type ())
|
||||
#define GST_DPSMOOTH(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_DPSMOOTH,GstDParamSmooth))
|
||||
#define GST_DPSMOOTH_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GST_TYPE_DPSMOOTH,GstDParamSmooth))
|
||||
#define GST_IS_DPSMOOTH(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), GST_TYPE_DPSMOOTH))
|
||||
#define GST_IS_DPSMOOTH_CLASS(obj) (G_TYPE_CHECK_CLASS_TYPE ((klass), GST_TYPE_DPSMOOTH))
|
||||
|
||||
typedef struct _GstDParamSmoothClass GstDParamSmoothClass;
|
||||
typedef struct _GstDParamSmooth GstDParamSmooth;
|
||||
|
||||
struct _GstDParamSmooth
|
||||
{
|
||||
struct _GstDParamSmooth {
|
||||
GstDParam dparam;
|
||||
|
||||
gint64 start_interp;
|
||||
|
@ -58,8 +59,7 @@ struct _GstDParamSmooth
|
|||
gpointer _gst_reserved[GST_PADDING];
|
||||
};
|
||||
|
||||
struct _GstDParamSmoothClass
|
||||
{
|
||||
struct _GstDParamSmoothClass {
|
||||
GstDParamClass parent_class;
|
||||
|
||||
/* signal callbacks */
|
||||
|
@ -71,4 +71,5 @@ GType gst_dpsmooth_get_type (void);
|
|||
GstDParam* gst_dpsmooth_new (GType type);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_DPSMOOTH_H__ */
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue