4 The current autoplugger as described in autoplug1 has some
7 - it is embedded in GstPipeline and cannot be used with a
8 generic interface. A lot of complexity is inside the
9 pipeline, more specifically the creation of threads and
10 subbins and the pad connections.
11 - it is not (easily) pluggable.
18 We want to define a pluggable framework for autoplugging this
21 - autoplugging algorithms can be added and removed at run time.
22 - autoplugging algorithms can be defined by plugins.
24 The autoplugger is build to handle simple media playback but
25 could also be used to create more complex pipelines.
27 The main focus will be on creating an element (can be a bin)
28 that has *one* input pad and *one or more* output pads.
30 It must be possible for a user app to insert its own elements in
31 the autogenerated element.
33 The autoplugger will be an interface to the low level plugin
34 system based on the functional requirements of the user app.
35 the app will for example request an object that can convert
36 media type X to media type Y, the user app is not interested in
37 any intermediate steps to accomplish this conversion.
43 The API for the user apps should be no more then this:
45 GstElement* gst_autoplug_caps_list (GstAutoplug *autoplug,
49 autoplug is a reference to the autoplug implementation
50 incaps is a GList of GstCaps* for the source pad, the last set
51 of arguments is a va_list of destination caps lists.
53 A handle to the autoplugger implementation can be obtained
56 GList* gst_autoplugfactory_get_list (void);
58 which will return a GList* of autopluggers.
60 GstAutoplug* gst_autoplugfactory_make ("name");
64 GstAutoplug* gst_autoplugfactory_create (GstAutoplugFactory *autoplug);
66 is used to get an autoplugger.
72 plugins can add their own autoplugger implementation by
73 subclassing an abstract autoplugger class and implementing/
74 overriding various methods.
76 the autoplugger can be registered with:
78 gst_plugin_add_autoplugger (GstPlugin *plugin,
79 GstAutoplugFactory *autoplug);
81 This will allow us to only load the autoplugger when needed.
88 We will implement two autopluggers:
90 - a static autoplugger. This autoplugger recursively adds
91 elements to the target element until all of the possible
92 pads are connected to something. The static autoplugger
93 only operates on padtemplates and ALWAYS pads. The pipeline
94 is not started before all elements are connected, hence
95 the 'static' autoplugger. This autoplugger will be a rework
96 of the current autoplugger.
98 - a dynamic autoplugger. This autoplugger configures the
99 pipeline at runtime based on the pad capabilities when they
100 become available. this allows for more fine grained
101 autoplugging than can be achieved with the static one because
102 it can be based on the actual media stream you are handling.
104 the autopluggers will be implemented in their separate plugins,
105 outside of the core libraries and are therefore optional.
108 5) the autoplugger object
109 -------------------------
111 the autoplugger object will be an abstract class with the following
114 - name, description, more text to identify the autoplugger.
116 - a class method autoplug_caps_list that has to be implemented by
117 the real autoplugger.
119 optionally, the core autoplugger code can provide convenience
120 functions to implement custom autopluggers. The shortest path
121 algorithm with pluggable weighting and list functions come to
124 signals will be added to the autoplugger so that user apps can
125 modify the constructed pipeline by adding extra objects.
126 A possible use case would be to let gstmediaplay perform an
127 autoplug on the media stream and insert a custom sound/video
128 effect in the pipeline when an appropriate element is created.
130 the "new_object" signal will be fired by the autoplugger whenever
131 a new object has been created. This signal can be caught by the
132 user app to perform an introspection on the newly created object.