2006-02-28 15:54:06 +00:00
|
|
|
Element Klass definition
|
|
|
|
------------------------
|
|
|
|
|
|
|
|
Status:
|
|
|
|
|
|
|
|
DRAFT.
|
|
|
|
|
|
|
|
|
|
|
|
Purpose:
|
|
|
|
|
|
|
|
Applications should be able to retrieve elements from the registry of existing
|
|
|
|
elements based on specific capabilities or features of the element.
|
|
|
|
|
|
|
|
A playback application might want to retrieve all the elements that can be
|
|
|
|
used for visualisation, for example, or a video editor might want to select all
|
|
|
|
video effect filters.
|
|
|
|
|
|
|
|
The topic of defining the klass of elements should be based on use cases.
|
|
|
|
|
|
|
|
|
|
|
|
Proposal:
|
|
|
|
|
|
|
|
The GstElementDetails contains a field named klass that is a pointer to a
|
|
|
|
string describing the element type.
|
|
|
|
|
|
|
|
In this document we describe the format and contents of the string. Elements
|
|
|
|
should adhere to this specification although that is not enforced to allow
|
|
|
|
for wild (application specific) customisation.
|
|
|
|
|
|
|
|
1) string format
|
|
|
|
|
|
|
|
<keyword>['/'<keyword]*
|
|
|
|
|
2006-03-13 10:32:26 +00:00
|
|
|
The string consists of an _unordered_ list of keywords separated with a '/'
|
|
|
|
character. While the / suggests a hierarchy, this is _not_ the case.
|
2006-02-28 15:54:06 +00:00
|
|
|
|
|
|
|
2) keyword categories
|
|
|
|
|
|
|
|
- functional
|
|
|
|
|
|
|
|
Categories are base on _intended usage_ of the element. Some elements
|
2006-02-28 17:03:32 +00:00
|
|
|
might have other side-effects (especially for filers/effects). The purpose
|
2006-02-28 15:54:06 +00:00
|
|
|
is to list enough keywords so that applications can do meaningfull filtering,
|
|
|
|
not to completely describe the functionality, that is expressed in caps etc..
|
|
|
|
|
|
|
|
* Source : produces data
|
|
|
|
* Sink : consumes data
|
2006-02-28 17:24:10 +00:00
|
|
|
* Filter : filters/transforms data, no modification on the data is
|
2006-02-28 17:03:32 +00:00
|
|
|
intended (although it might be unavoidable). The
|
|
|
|
filter can decide on input and output caps independently
|
|
|
|
of the stream contents (GstBaseTransform).
|
|
|
|
* Effect : applies an effect to some data, changes to data are
|
2006-03-13 10:32:26 +00:00
|
|
|
intended. Examples are colorbalance, volume. These
|
|
|
|
elements can also be implemented with GstBaseTransform.
|
2006-02-28 15:54:06 +00:00
|
|
|
* Demuxer : splits audio, video, ... from a stream
|
2006-02-28 17:03:32 +00:00
|
|
|
* Muxer : interleave audio, video, ... into one stream, this is
|
|
|
|
like mixing but without losing or degrading each separate
|
|
|
|
input stream. The reverse operation is possible with a
|
|
|
|
Demuxer that reproduces the exact same input streams.
|
|
|
|
* Decoder : decodes encoded data into a raw format, there is typically
|
|
|
|
no relation between input caps and output caps. The output
|
|
|
|
caps are defined in the stream data. This separates the
|
2006-03-13 10:32:26 +00:00
|
|
|
Decoder from the Filter and Effect.
|
2006-02-28 17:03:32 +00:00
|
|
|
* Encoder : encodes raw data into an encoded format.
|
|
|
|
* Mixer : combine audio, video, .. this is like muxing but with
|
|
|
|
applying some algorithm so that the individual streams
|
|
|
|
are not extractable anymore, there is therefore no
|
2006-03-13 10:32:26 +00:00
|
|
|
reverse operation to mixing. (audio mixer, video mixer, ...)
|
2006-02-28 17:03:32 +00:00
|
|
|
* Converter : convert audio into video, text to audio, ... The converter
|
|
|
|
typically works on raw types only. The source media type
|
|
|
|
is listed first.
|
2006-02-28 15:54:06 +00:00
|
|
|
* Analyzer : reports about the stream contents.
|
|
|
|
* Control : controls some aspect of a hardware device
|
|
|
|
* Extracter : extracts tags/headers from a stream
|
|
|
|
* Formatter : adds tags/headers to a stream
|
2006-02-28 17:24:10 +00:00
|
|
|
* Connector : allows for new connections in the pipeline. (tee, ...)
|
2006-02-28 15:54:06 +00:00
|
|
|
* ...
|
|
|
|
|
|
|
|
- Based on media type
|
|
|
|
|
|
|
|
Purpose is to make a selection for elements operating on the different
|
|
|
|
types of media. An audio application must be able to filter out the
|
|
|
|
elements operating on audio, for example.
|
|
|
|
|
|
|
|
* Audio : operates on audio data
|
|
|
|
* Video : operates on video data
|
|
|
|
* Text : operates on text data
|
|
|
|
* Metadata : operates on metadata
|
|
|
|
* ...
|
|
|
|
|
|
|
|
- Extra features
|
|
|
|
|
|
|
|
The purpose is to further specialize the element, mostly for
|
|
|
|
application specific needs.
|
|
|
|
|
|
|
|
* Network : element is used in networked situations
|
|
|
|
* Protocol : implements some protocol (RTSP, HTTP, ...)
|
|
|
|
* Payloader : encapsulate as payload (RTP, RDT,.. )
|
|
|
|
* Depayloader : strip a payload (RTP, RDT,.. )
|
|
|
|
* RTP : intended to be used in RTP applications
|
2006-02-28 17:03:32 +00:00
|
|
|
* Device : operates on some hardware device (disk, network,
|
|
|
|
audio card, video card, usb, ...)
|
|
|
|
* Visualisation : intended to be used for audio visualisation
|
2006-02-28 17:24:10 +00:00
|
|
|
* Debug : intended usage is more for debugging purposes.
|
2006-02-28 15:54:06 +00:00
|
|
|
|
|
|
|
3) suggested order:
|
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
<functional>[/<media type>]*[/<extra...>]*
|
2006-02-28 15:54:06 +00:00
|
|
|
|
|
|
|
4) examples:
|
|
|
|
|
|
|
|
apedemux : Extracter/Metadata
|
2006-02-28 17:03:32 +00:00
|
|
|
audiotestsrc : Source/Audio
|
|
|
|
autoaudiosink : Sink/Audio/Device
|
|
|
|
cairotimeoverlay : Mixer/Video/Text
|
2006-02-28 15:54:06 +00:00
|
|
|
dvdec : Decoder/Video
|
|
|
|
dvdemux : Demuxer
|
2006-02-28 17:03:32 +00:00
|
|
|
goom : Converter/Audio/Video
|
2006-02-28 15:54:06 +00:00
|
|
|
id3demux : Extracter/Metadata
|
2006-02-28 17:03:32 +00:00
|
|
|
udpsrc : Source/Network/Protocol/Device
|
|
|
|
videomixer : Mixer/Video
|
2006-03-13 10:32:26 +00:00
|
|
|
ffmpegcolorspace : Filter/Video (intended use to convert video with as little
|
2006-02-28 17:03:32 +00:00
|
|
|
visible change as possible)
|
2006-02-28 15:54:06 +00:00
|
|
|
vertigotv : Effect/Video (intended use is to change the video)
|
2006-02-28 17:03:32 +00:00
|
|
|
volume : Effect/Audio (intended use is to change the audio data)
|
2006-02-28 15:54:06 +00:00
|
|
|
vorbisdec : Decoder/Audio
|
|
|
|
vorbisenc : Encoder/Audio
|
|
|
|
oggmux : Muxer
|
2006-02-28 17:03:32 +00:00
|
|
|
adder : Mixer/Audio
|
2006-02-28 15:54:06 +00:00
|
|
|
videobox : Effect/Video
|
2006-02-28 17:03:32 +00:00
|
|
|
alsamixer : Control/Audio/Device
|
2006-02-28 17:24:10 +00:00
|
|
|
audioconvert : Filter/Audio
|
|
|
|
audioresample : Filter/Audio
|
2006-02-28 17:03:32 +00:00
|
|
|
xvimagesink : Sink/Video/Device
|
2006-02-28 17:24:10 +00:00
|
|
|
navseek : Filter/Debug
|
2006-02-28 15:54:06 +00:00
|
|
|
decodebin : Decoder/Demuxer
|
2006-02-28 17:24:10 +00:00
|
|
|
level : Filter/Analyzer/Audio
|
|
|
|
tee : Connector/Debug
|
2006-02-28 15:54:06 +00:00
|
|
|
|
|
|
|
Use cases:
|
|
|
|
|
|
|
|
- get a list of all elements implementing a video effect (pitivi):
|
|
|
|
|
|
|
|
klass.contains (Effect & Video)
|
|
|
|
|
|
|
|
- get list of muxers (pitivi):
|
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
klass.contains (Muxer)
|
2006-02-28 15:54:06 +00:00
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
- get list of video encoders (pitivi):
|
2006-02-28 15:54:06 +00:00
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
klass.contains (Encoder & video)
|
2006-02-28 15:54:06 +00:00
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
- Get a list of all audio/video visualisations (totem):
|
2006-02-28 15:54:06 +00:00
|
|
|
|
|
|
|
klass.contains (Visualisation)
|
|
|
|
|
|
|
|
- Get a list of all decoders/demuxer/metadata parsers/vis (playbin):
|
|
|
|
|
|
|
|
klass.contains (Visualisation | Demuxer | Decoder | (Extractor & Metadata))
|
|
|
|
|
2006-02-28 17:03:32 +00:00
|
|
|
- Get a list of elements that can capture from an audio device (gst-properties):
|
|
|
|
|
|
|
|
klass.contains (Source & Audio & Device)
|
|
|
|
|
|
|
|
* filters out audiotestsrc, since it is not a device
|
|
|
|
|
2006-02-28 15:54:06 +00:00
|
|
|
|