[gst-devel] Roundup 2. framework changes

Wim Taymans wim.taymans at chello.be
Sun Jul 16 16:00:51 CEST 2000


Things that have changed in the basic framework,

gstplugin.c
-----------

added a method gst_library_load() to load a library. also
added the libs directory in the search pad.

gst.h
-----

DEBUG now outputs the thread pid.

gstbuffer.h
-----------

Added a new buffer flag: GST_BUFFER_FLUSH. setting this flag
will cause the plugins to clear their previous contents and
restart processing from this new buffer.
This was needed for the seeking. When the source element has
been given a new offset, there is no point in having the
plugins process their previous accumulated buffers. The disksrc
will set the GST_BUFFER_FLUSH flag on the new buffer. Most
of the elements react to that flush:

MPEG1/2 system parsers: resync to a new PES/system header.
MPEG1/2 video parser: resync to a new GOP
MPEG1/2 video decoders: clear past/future buffers.
MPEG audio parser: resync to a new audio header.
gstqueue: clear the queue.
audiosink: clear the audio buffer.

This method will give the user immediate feedback about the
seek operation, even with very deep queues.

gstclock.c/h
------------

methods for setting, waiting for and calculating the current time.

currently the MPEG system parser waits and sets the current clock
based on the SCR timestamps.
The videosink and audiosink wait for the PTS timestamps before
rendering their data.
DTS timestamps are not used yet.

gstpad.c
--------

added gst_pad_disconnect(...)
used to disconnect the typedetect element in gstplay after discovery.

added an instance method qos 
added gst_pad_set_qos_function() to set the qos function.
added gst_pad_handle_qos(GstPad *pad, gulong qos_message)

gst_pad_handle_qos will check the qos function of the pad and if
it is set, will call the function.

if the function is not set, the gst_pad_handle_qos is invoked for
all the SINK pads of the pad->peer->parent element. This way, the
qos message will travel from SINK to SRC. any element that can handle
the qos message must set the qos function and react on it.

gstutil.c
---------

added gst_util_dump_mem to dump a pice of memory usefull for debugging.

elements/gstdisksrc
-------------------

added size property to query the file size.
set the GST_BUFFER_FLUSH flag if seek has happened.

elements/gstpipefilter.c
------------------------

a new filter that takes a command as an argument. It will execvp
the command and hook the stdin/stdout of the process to the sink/src
pads. This allows you to add any program that can process data from
stdin/stdout into a gstreamer pipeline: sox and lame for example.

Two problems with this filter: The resulting data is not typed. Also
the command cannot be adjusted to changed meta data attached to the
input buffers. these problems can be solved by adding callbacks and
properties so that the controlling application can handle or set the 
meta data.

another problem is the fact that the forked command does not immediatly
outputs the resulting data. We have to poll on the stdout pipe until
data arrives. Currently the polling is done after sending a buffer to
the commands stdin pipe. This should be handled by a seperate thread
that does select() on the stdout pipe.

elements/gstqueue.c
-------------------

reacts to a GST_BUFFER_FLUSH by unreffing the currently queued buffers.

elements/gsttypefind.c
----------------------

hands the buffer to all the registered typefind functions. If a plugin
can handle the buffer, a HAVE_TYPE is signaled. The app can then query
the type and add the appropriate parsers to the pipeline.

gstplay demonstrates this.

types/gsttypes.c
----------------

moved all the types to where they belong: in the plugins.
only contains the basic raw types. (and ac3 but that is to be fixed)

Wim



-- 
Man is the only animal that laughs and weeps; for he is the only animal
that is struck with the difference between what things are and what they
ought to be.
		-- William Hazlitt




More information about the gstreamer-devel mailing list