More pending stuff

Original commit message from CVS:
More pending stuff
This commit is contained in:
Wim Taymans 2001-09-30 22:19:04 +00:00
parent f447082a5e
commit afab5d4056
22 changed files with 3127 additions and 3144 deletions

View file

@ -925,7 +925,7 @@ if test "x$USE_DEBUG" = xyes; then
fi
if test "x$USE_PROFILING" = xyes; then
CFLAGS="$CFLAGS -pg"
CFLAGS="$CFLAGS -pg -fprofile-arcs"
FOMIT_FRAME_POINTER=""
else
FOMIT_FRAME_POINTER="-fomit-frame-pointer"
@ -1287,6 +1287,7 @@ test/Makefile
test/xml/Makefile
test/bindings/Makefile
test/misc/Makefile
test/memchunk/Makefile
tests/Makefile
tests/sched/Makefile
tests/eos/Makefile

View file

@ -116,7 +116,7 @@ The type of the autoplugger.
</para>
@name:
@feature:
@longdesc:
@type:
@ -207,22 +207,3 @@ The type of the autoplugger.
@Returns:
<!-- ##### FUNCTION gst_autoplugfactory_save_thyself ##### -->
<para>
</para>
@factory:
@parent:
@Returns:
<!-- ##### FUNCTION gst_autoplugfactory_load_thyself ##### -->
<para>
</para>
@parent:
@Returns:

View file

@ -239,6 +239,7 @@ used when data in a stream has been skipped
</para>
@data_type:
@lock:
@data:
@size:
@ -265,6 +266,8 @@ used when data in a stream has been skipped
</para>
@pool:
@location:
@size:
@Returns:
@ -293,9 +296,12 @@ used when data in a stream has been skipped
</para>
@buf:
@buf2:
@Returns:
<!-- # Unused Parameters # -->
@buffer:
@append:
@Returns:
<!-- ##### FUNCTION gst_buffer_ref ##### -->

View file

@ -52,30 +52,10 @@ A bufferpool can be requested from a pad with the gst_pad_get_bufferpool() funct
</para>
@lock:
@new_user_data:
@destroy_user_data:
@destroy_buffer:
<!-- ##### USER_FUNCTION GstBufferPoolCreateFunction ##### -->
<para>
The function called when a buffer has to be created for this pool.
</para>
@pool: the pool from which to create the buffer
@user_data: any user data
@Returns: a new buffer from the pool
<!-- ##### USER_FUNCTION GstBufferPoolDestroyFunction ##### -->
<para>
This function will be called when the given buffer has to be returned to
the pool.
</para>
@pool: the pool to return the buffer to
@buffer: the buffer to return
@user_data: any user data
@buffer_free:
@buffer_copy:
@destroy_hook:
@user_data:
<!-- ##### FUNCTION gst_buffer_pool_new ##### -->
<para>
@ -85,24 +65,6 @@ the pool.
@Returns:
<!-- ##### FUNCTION gst_buffer_pool_new_buffer ##### -->
<para>
</para>
@pool:
@Returns:
<!-- ##### FUNCTION gst_buffer_pool_destroy_buffer ##### -->
<para>
</para>
@pool:
@buffer:
<!-- ##### FUNCTION gst_buffer_pool_ref ##### -->
<para>
@ -130,26 +92,6 @@ the pool.
@pool:
<!-- ##### FUNCTION gst_buffer_pool_set_create_function ##### -->
<para>
</para>
@pool:
@create:
@user_data:
<!-- ##### FUNCTION gst_buffer_pool_set_destroy_function ##### -->
<para>
</para>
@pool:
@destroy:
@user_data:
<!-- ##### FUNCTION gst_buffer_pool_destroy ##### -->
<para>
@ -163,9 +105,10 @@ the pool.
</para>
@oldpool:
@buffer_size:
@pool_size:
@Returns:
<!-- # Unused Parameters # -->
@oldpool:

View file

@ -47,8 +47,8 @@ Specify how many bytes to read at a time.
Get/set the current offset in the file.
</para>
<!-- ##### ARG GstDiskSrc:size ##### -->
<!-- ##### ARG GstDiskSrc:filesize ##### -->
<para>
Get the size of the file.
</para>

View file

@ -225,7 +225,7 @@ of the element, the GtkType value for it, as well as a pointer to the
GstElementDetails struct for the element.
</para>
@name:
@feature:
@type:
@details:
@padtemplates:
@ -241,14 +241,6 @@ circumstances.
@element: The element in question.
<!-- ##### FUNCTION gst_element_new ##### -->
<para>
</para>
@Returns:
<!-- ##### MACRO gst_element_destroy ##### -->
<para>
@ -503,14 +495,6 @@ circumstances.
@Returns:
<!-- ##### FUNCTION gst_elementfactory_destroy ##### -->
<para>
</para>
@elementfactory:
<!-- ##### FUNCTION gst_elementfactory_add_padtemplate ##### -->
<para>
@ -580,25 +564,6 @@ circumstances.
@Returns:
<!-- ##### FUNCTION gst_elementfactory_save_thyself ##### -->
<para>
</para>
@factory:
@parent:
@Returns:
<!-- ##### FUNCTION gst_elementfactory_load_thyself ##### -->
<para>
</para>
@parent:
@Returns:
<!-- ##### SIGNAL GstElement::state-change ##### -->
<para>
Is trigered whenever the state of an element changes

View file

@ -24,7 +24,7 @@ with the buffer. (fakesink)
@gstfakesink: the object which received the signal.
@arg1:
<!-- ##### ARG GstFakeSink:num_sinks ##### -->
<!-- ##### ARG GstFakeSink:num-sinks ##### -->
<para>
</para>

View file

@ -22,12 +22,12 @@ The <classname>GstFakeSrc</classname> generates empty buffers. (fakesrc)
@gstfakesrc: the object which received the signal.
@arg1:
<!-- ##### ARG GstFakeSrc:num_sources ##### -->
<!-- ##### ARG GstFakeSrc:num-sources ##### -->
<para>
</para>
<!-- ##### ARG GstFakeSrc:loop_based ##### -->
<!-- ##### ARG GstFakeSrc:loop-based ##### -->
<para>
</para>
@ -42,7 +42,7 @@ The <classname>GstFakeSrc</classname> generates empty buffers. (fakesrc)
</para>
<!-- ##### ARG GstFakeSrc:num_buffers ##### -->
<!-- ##### ARG GstFakeSrc:num-buffers ##### -->
<para>
</para>

View file

@ -22,12 +22,12 @@ Pass data without modification.
@gstidentity: the object which received the signal.
@arg1:
<!-- ##### ARG GstIdentity:loop_based ##### -->
<!-- ##### ARG GstIdentity:loop-based ##### -->
<para>
</para>
<!-- ##### ARG GstIdentity:sleep_time ##### -->
<!-- ##### ARG GstIdentity:sleep-time ##### -->
<para>
</para>

View file

@ -141,14 +141,6 @@ Check if the object has been destroyed.
@obj: The Object to check
<!-- ##### FUNCTION gst_object_new ##### -->
<para>
</para>
@Returns:
<!-- ##### FUNCTION gst_object_check_uniqueness ##### -->
<para>

View file

@ -189,24 +189,6 @@ a start/stop timecode pair.
@size: the size of the region to get
<!-- ##### USER_FUNCTION GstPadQoSFunction ##### -->
<para>
The function that will be called when a QoS message is sent.
</para>
@pad: the pad that sent the QoS message
@qos_message: the message
<!-- ##### USER_FUNCTION GstPadEOSFunction ##### -->
<para>
The function that will be called in an EOS case.
</para>
@pad: the pad that needs to be set to EOS state
@Returns: TRUE if EOS was successful, FALSE otherwise
<!-- ##### USER_FUNCTION GstPadNewCapsFunction ##### -->
<para>
The function that will be called when the caps of the pad has
@ -247,25 +229,6 @@ The function that will be called when negotiating.
@Returns: The result of the negotiation process
<!-- ##### USER_FUNCTION GstPadPushFunction ##### -->
<para>
The function that will be called when pushing a buffers.
</para>
@pad: the pad to push
@buf: a GstBuffer to push
<!-- ##### USER_FUNCTION GstPadPullFunction ##### -->
<para>
The function that will be called when pulling buffers.
</para>
@pad: the pad to pull
@Returns: a GstBuffer
<!-- ##### ENUM GstRegionType ##### -->
<para>
the region types for #gst_pad_pullregion.
@ -383,24 +346,6 @@ Destroy the pad.
@nego:
<!-- ##### FUNCTION gst_pad_set_qos_function ##### -->
<para>
</para>
@pad:
@qos:
<!-- ##### FUNCTION gst_pad_set_eos_function ##### -->
<para>
</para>
@pad:
@eos:
<!-- ##### FUNCTION gst_pad_set_newcaps_function ##### -->
<para>
@ -627,32 +572,6 @@ Destroy the pad.
@Returns:
<!-- ##### FUNCTION gst_pad_set_eos ##### -->
<para>
</para>
@pad:
@Returns:
<!-- ##### FUNCTION gst_pad_handle_qos ##### -->
<para>
</para>
@pad:
@qos_message:
<!-- ##### MACRO gst_pad_eos ##### -->
<para>
Call the EOS function of the pad
</para>
@pad: the pad to call the eos function of.
<!-- ##### FUNCTION gst_pad_load_and_connect ##### -->
<para>
@ -706,15 +625,6 @@ Call the EOS function of the pad
@Returns:
<!-- ##### FUNCTION gst_pad_eos_func ##### -->
<para>
</para>
@pad:
@Returns:
<!-- ##### STRUCT GstRealPad ##### -->
<para>
@ -731,12 +641,12 @@ Call the EOS function of the pad
@len:
@sched:
@chainfunc:
@chainhandler:
@getfunc:
@gethandler:
@eventfunc:
@eventhandler:
@getregionfunc:
@qosfunc:
@eosfunc:
@pushfunc:
@pullfunc:
@pullregionfunc:
@negotiatefunc:
@newcapsfunc:
@ -831,22 +741,6 @@ Get the getregion function of the real pad.
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_PUSHFUNC ##### -->
<para>
Get the pushfunction of the real pad.
</para>
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_PULLFUNC ##### -->
<para>
Get the pullfunction of the real pad.
</para>
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_PULLREGIONFUNC ##### -->
<para>
Get the pullregion function of the real pad.
@ -855,22 +749,6 @@ Get the pullregion function of the real pad.
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_QOSFUNC ##### -->
<para>
Get the QoS function of the real pad.
</para>
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_EOSFUNC ##### -->
<para>
Get the EOS function of the real pad.
</para>
@pad: the real pad to query.
<!-- ##### MACRO GST_RPAD_NEGOTIATEFUNC ##### -->
<para>
Get the negotiate function from the real pad.

View file

@ -63,11 +63,9 @@ to bring it into memory.
@name:
@longname:
@filename:
@types:
@numtypes:
@elements:
@numelements:
@numautopluggers:
@features:
@numfeatures:
@module:
<!-- ##### USER_FUNCTION GstPluginInitFunc ##### -->
<para>
@ -198,33 +196,6 @@ loaded will use this variable to initialize the plugin.
@Returns:
<!-- ##### FUNCTION gst_plugin_add_factory ##### -->
<para>
</para>
@plugin:
@factory:
<!-- ##### FUNCTION gst_plugin_add_type ##### -->
<para>
</para>
@plugin:
@factory:
<!-- ##### FUNCTION gst_plugin_add_autoplugger ##### -->
<para>
</para>
@plugin:
@factory:
<!-- ##### FUNCTION gst_plugin_find ##### -->
<para>
@ -242,59 +213,6 @@ loaded will use this variable to initialize the plugin.
@Returns:
<!-- ##### FUNCTION gst_plugin_get_factory_list ##### -->
<para>
</para>
@plugin:
@Returns:
<!-- ##### FUNCTION gst_plugin_get_type_list ##### -->
<para>
</para>
@plugin:
@Returns:
<!-- ##### FUNCTION gst_plugin_get_autoplug_list ##### -->
<para>
</para>
@plugin:
@Returns:
<!-- ##### FUNCTION gst_plugin_load_elementfactory ##### -->
<para>
</para>
@name:
@Returns:
<!-- ##### FUNCTION gst_plugin_load_typefactory ##### -->
<para>
</para>
@mime:
<!-- ##### FUNCTION gst_plugin_load_autoplugfactory ##### -->
<para>
</para>
@name:
@Returns:
<!-- ##### FUNCTION gst_plugin_load_thyself ##### -->
<para>

View file

@ -35,7 +35,7 @@ The queue blocks by default.
Get the number of buffers in the queue.
</para>
<!-- ##### ARG GstQueue:max_level ##### -->
<!-- ##### ARG GstQueue:max-level ##### -->
<para>
Specify the maximum number of buffers in the queue before the queue
blocks.

File diff suppressed because it is too large Load diff

View file

@ -14,7 +14,7 @@ A tee can be used to split out the filter graph.
</para>
<!-- ##### ARG GstTee:num_pads ##### -->
<!-- ##### ARG GstTee:num-pads ##### -->
<para>
</para>

View file

@ -45,7 +45,7 @@ Thread flags:
@Returns:
<!-- ##### ARG GstThread:create_thread ##### -->
<!-- ##### ARG GstThread:create-thread ##### -->
<para>
TRUE if the thread should be created.

View file

@ -71,13 +71,14 @@ A type.
@id:
@mime:
@exts:
@typefindfuncs:
@factories:
<!-- ##### STRUCT GstTypeFactory ##### -->
<para>
The struct with the typefactory information.
</para>
@feature:
@mime:
@exts:
@typefindfunc:
@ -126,22 +127,3 @@ The struct with the typefactory information.
@Returns:
<!-- ##### FUNCTION gst_typefactory_load_thyself ##### -->
<para>
</para>
@parent:
@Returns:
<!-- ##### FUNCTION gst_typefactory_save_thyself ##### -->
<para>
</para>
@factory:
@parent:
@Returns:

View file

@ -11,35 +11,36 @@ and properties are still used for plugin-app communication).
Events will be generated by either a plugin or the app. It should be
possible for a plugin to generate an event on one of its pads and it
should be possible for an app to insert an event on an abitrary pad
in the pipeline.
should be possible for an app to insert an event on an abitrary pad in
the pipeline.
Event handling
--------------
Events can both travel upstream or downstream. Some events, by nature, only
travel in one direction.
Events can both travel upstream or downstream. Some events, by nature,
only travel in one direction.
* downstream events
- Travel in the same way buffers do. This includes that they are handled
by the scheduler. The rationale is that the events should be kept as close
to the buffers are possible.
by the scheduler. The rationale is that the events should be kept
as close to the buffers are possible.
- plugins should check the type of the GstData passed in the _chain or _loop
function and act appropriatly. This can be done by either doing their own
stuff or by calling the default handler.
- plugins should check the type of the GstData passed in the _chain
or _loop function and act appropriatly. This can be done by either
doing their own stuff or by calling the default handler.
- are handled on the sink pad.
* upstream events
- are handled with an event handler attached to the srcpad. A default handler
will be implemented for pads that don't implement their own handler.
- are handled with an event handler attached to the srcpad. A default
handler will be implemented for pads that don't implement their own
handler.
- travel as fast as possible. the rationale is that a seek event should get to
the src element ASAP.
- travel as fast as possible. the rationale is that a seek event should
get to the src element ASAP.
Possible candidates for events
@ -58,8 +59,8 @@ Possible candidates for events
or timestamp.
- discontinuous
A plugin has detected a discontinuity in the stream. Other plugins might
need to resync.
A plugin has detected a discontinuity in the stream. Other plugins
might need to resync.
- flush
Plugins need to get rid of any buffered data ASAP.
@ -72,19 +73,19 @@ Possible candidates for events
application generated events
----------------------------
The application can insert events into the pipeline at arbirary places. This
will be done by calling gst_pad_event() on a pad.
The application can insert events into the pipeline at arbirary
places. This will be done by calling gst_pad_event() on a pad.
A first implementation will only cover inserting events on src pads since
inserting events on sinkpads needs changes to the scheduler.
A first implementation will only cover inserting events on src pads
since inserting events on sinkpads needs changes to the scheduler.
Effects of events on plugins
----------------------------
some events are going to change the state of an element. The EOS event will
for example change the state of an element to the PAUSED state. Not sure when
or how this will happen.
some events are going to change the state of an element. The EOS event
will for example change the state of an element to the PAUSED state. Not
sure when or how this will happen.
use cases
@ -92,39 +93,41 @@ use cases
1) filesrc ! fakesink
filesrc will read until it reaches EOF. It will then create a GstEvent of type
EOS and return it in the _get function. The event will travel downstream and
will reach the fakesink element. Fakesink will detect the event in the _chain
function and will call the default handler. The default handler will set the
element to the paused state. filesrc will eventually change its state to PAUSED,
probably before sending out the event (TBD)
filesrc will read until it reaches EOF. It will then create a GstEvent
of type EOS and return it in the _get function. The event will travel
downstream and will reach the fakesink element. Fakesink will detect
the event in the _chain function and will call the default handler. The
default handler will set the element to the paused state. filesrc will
eventually change its state to PAUSED, probably before sending out the
event (TBD)
2) filesrc ! fakesink
The app wants to perform a seek on filesrc. It'll call the gst_pad_event() on
filesrcs src pad with the SEEK event type. The event handler will react and
change filesrcs internal status. filesrc will return a DISCONT event before
returning the buffer with the new offset.
The app wants to perform a seek on filesrc. It'll call the gst_pad_event()
on filesrcs src pad with the SEEK event type. The event handler will
react and change filesrcs internal status. filesrc will return a DISCONT
event before returning the buffer with the new offset.
3) filesrc ! mpeg2parse video_0! queue ! { mpeg2dec ! xvideosink }
lost of possibilities here: The app can choose to insert a seek event on the
filesrc element (byte offset), it can insert a byte/time offset seek on the
video_0 pad of mpeg2parse or it can insert a time seek event on mpeg2decs
src pad.
lost of possibilities here: The app can choose to insert a seek event
on the filesrc element (byte offset), it can insert a byte/time offset
seek on the video_0 pad of mpeg2parse or it can insert a time seek event
on mpeg2decs src pad.
the event will travel upstream using the handlers and the intermediate elements
can convert the event from a time to a byte offset (possibly using GstTimeCache
to speed up things).
the event will travel upstream using the handlers and the intermediate
elements can convert the event from a time to a byte offset (possibly
using GstTimeCache to speed up things).
Filesrc will get a byte seek event on its src pad and will proceed as in case 2.
Filesrc will get a byte seek event on its src pad and will proceed as
in case 2.
As can be seen from this example the app will generate an event in another
context than those of the plugins, so this will need proper locking.
The app can also choose to insert a flush event on one of the src pads. The
plugins would clear their cached data and forward the event to their upstream
peer pad(s).
The app can also choose to insert a flush event on one of the src
pads. The plugins would clear their cached data and forward the event
to their upstream peer pad(s).
4)...

View file

@ -402,7 +402,7 @@ gst_play_set_uri (GstPlay *play, const guchar *uri)
}
if (priv->src == NULL) {
priv->src = gst_elementfactory_make ("disksrc", "srcelement");
priv->src = gst_elementfactory_make ("filesrc", "srcelement");
}
priv->uri = g_strdup (uri);

View file

@ -16,7 +16,7 @@ gboolean idle_func(gpointer data) {
void mpeg2parse_newpad(GstElement *parser,GstPad *pad, GstElement *pipeline) {
g_print("***** a new pad %s was created\n", gst_pad_get_name(pad));
g_print("***** a new pad %s was created %p\n", gst_pad_get_name(pad), pipeline);
gst_element_set_state(GST_ELEMENT(pipeline),GST_STATE_PAUSED);
if (strncmp(gst_pad_get_name(pad), "video_", 6) == 0) {

View file

@ -15,6 +15,6 @@ man_MANS = gstreamer-launch.1 gstreamer-register.1 gstreamer-inspect.1 \
gstreamer-complete.1 gstreamer-compprep.1
LDADD = $(GST_LIBS)
CFLAGS = $(LIBGST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\"
CFLAGS = $(LIBGST_CFLAGS) -DGST_CONFIG_DIR=\"$(GST_CONFIG_DIR)\" -fprofile-arcs
EXTRA_DIST = $(man_MANS)

View file

@ -61,7 +61,11 @@ arg_search (GstBin *bin, gchar *argname, found_handler handler, void *priv)
gboolean
idle_func (gpointer data)
{
return gst_bin_iterate (GST_BIN (data));
if (!gst_bin_iterate (GST_BIN (data))) {
gtk_main_quit ();
return FALSE;
}
return TRUE;
}
void