[gmpi] Modules (Layers)

  • From: Marco Ballini <marcoballini@xxxxxxxxx>
  • To: gmpi@xxxxxxxxxxxxx
  • Date: 15 Nov 2003 18:43:31 +0100

>>> 4.17. Dynamic Plugins via Modules 
>>> This approach needs some further designing, and some simplification,
>>> but it could be the basis for a very flexible and powerful system.

Here is my view, definition and requirements.
(I use the name "layer" because it sounds to me more correct).

-- Events
Events are timestamped.
An event may contain a single value or a stream of data (a pointer to a
buffer).


-- Ports
Are the inputs and output of a plugin.
An input port receive time-stamped events.
After processing by the plugin, an output port may contain a list of
time-stamped events. It doesn't when the plugin is "muted".
A port must specify the type of events it can receive. A port may
receive single-value events, streams, or both.
The processing loop is changed by the plugin, accordingly to the kind of
events is received ona each port.
A port has an hint indicating it's type (audio, logarithmic, trigger,
tempo, bypass, frequency,volume, etc..).

-- State
A state is a subset of the internal data of a plugin.

-- Port group
Ports in the same group modify the same state (for example the cut-off
frequency and the resonance of a filter, modify the filter coefficients,
which represent the state they modify).

-- Layer
For each port group, you may allocate one or more layers (also called
"channels") of different port values and associated states.
Each port group must specify the max number of layers that can be
allocated for it.
The number 0, is used to specify that any number of layer may be
allocated for that port group.
Port group with a max number of layers equal to 1 are used for
parameters that are global in the plugin.

-- Example: Configurable Stereo Mixer (Note: the purpose of this example
is purely to explain the concepts defined above)
----------------------------------------------------------------------
Group name | Port name (event type, hint) | Layer
----------------------------------------------------------------------
           | Output (stream, audio)       |   |   |   |
Outputs    | Treble (single, frequency)   | 0 | 1 | 2 | 
           | Bass (single, frequency      |   |   |   |
           | Level (single/stream, volume)|   |   |   |
----------------------------------------------------------------------
Global     | Master vol (single, volume)  | 0 | 
----------------------------------------------------------------------  
           | Treble (single, frequency)   |   |   |   |   |   |   |
           | Bass (single, frequency      |   |   |   |   |   |   |
Inputs     | Level (single/stream, volume)| 0 | 1 | 2 | 3 | 4 | 5 |
           | Left in(stream, audio)       |   |   |   |   |   |   |
           | Right in(stream, audio)      |   |   |   |   |   |   |
----------------------------------------------------------------------
Here the number in the column layer indicate the index of the state.
In total we have 3+1+6=10 layers.
For port group "Outputs", we have 3 layers/channels (dinamically
changeable). For example first channel may be used as left output,
second channel as right output, and third channel as sub (bass).
The "Master volume" is used as a a gain common to all output layers.
For port group "Inputs", each layer represent a different a stereo
inoput. Adding an input to the mixer simply requires to add a new layer
to this port group.

What do you think?










----------------------------------------------------------------------
Generalized Music Plugin Interface (GMPI) public discussion list
Participation in this list is contingent upon your abiding by the
following rules:  Please stay on topic.  You are responsible for your own
words.  Please respect your fellow subscribers.  Please do not
redistribute anyone else's words without their permission.

Archive: //www.freelists.org/archives/gmpi
Email gmpi-request@xxxxxxxxxxxxx w/ subject "unsubscribe" to unsubscribe

Other related posts:

  • » [gmpi] Modules (Layers)