aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/eg-midigate.lv2/midigate.ttl
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/eg-midigate.lv2/midigate.ttl')
-rw-r--r--plugins/eg-midigate.lv2/midigate.ttl56
1 files changed, 56 insertions, 0 deletions
diff --git a/plugins/eg-midigate.lv2/midigate.ttl b/plugins/eg-midigate.lv2/midigate.ttl
new file mode 100644
index 0000000..e14a329
--- /dev/null
+++ b/plugins/eg-midigate.lv2/midigate.ttl
@@ -0,0 +1,56 @@
+# The same set of namespace prefixes with two additions for LV2 extensions this
+# plugin uses: atom and urid.
+
+@prefix atom: <http://lv2plug.in/ns/ext/atom#> .
+@prefix doap: <http://usefulinc.com/ns/doap#> .
+@prefix lv2: <http://lv2plug.in/ns/lv2core#> .
+@prefix midi: <http://lv2plug.in/ns/ext/midi#> .
+@prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#> .
+@prefix urid: <http://lv2plug.in/ns/ext/urid#> .
+
+<http://lv2plug.in/plugins/eg-midigate>
+ a lv2:Plugin ;
+ doap:name "Example MIDI Gate" ;
+ doap:license <http://opensource.org/licenses/isc> ;
+ lv2:project <http://lv2plug.in/ns/lv2> ;
+ lv2:requiredFeature urid:map ;
+ lv2:optionalFeature lv2:hardRTCapable ;
+# This plugin has three ports. There is an audio input and output as before,
+# as well as a new AtomPort. An AtomPort buffer contains an Atom, which is a
+# generic container for any type of data. In this case, we want to receive
+# MIDI events, so the (mandatory) +atom:bufferType+ is atom:Sequence, which is
+# a series of events with time stamps.
+#
+# Events themselves are also generic and can contain any type of data, but in
+# this case we are only interested in MIDI events. The (optional)
+# +atom:supports+ property describes which event types are supported. Though
+# not required, this information should always be given so the host knows what
+# types of event it can expect the plugin to understand.
+#
+# The (optional) +lv2:designation+ of this port is +lv2:control+, which
+# indicates that this is the "main" control port where the host should send
+# events it expects to configure the plugin, in this case changing the MIDI
+# program. This is necessary since it is possible to have several MIDI input
+# ports, though typically it is best to have one.
+ lv2:port [
+ a lv2:InputPort ,
+ atom:AtomPort ;
+ atom:bufferType atom:Sequence ;
+ atom:supports midi:MidiEvent ;
+ lv2:designation lv2:control ;
+ lv2:index 0 ;
+ lv2:symbol "control" ;
+ lv2:name "Control"
+ ] , [
+ a lv2:AudioPort ,
+ lv2:InputPort ;
+ lv2:index 1 ;
+ lv2:symbol "in" ;
+ lv2:name "In"
+ ] , [
+ a lv2:AudioPort ,
+ lv2:OutputPort ;
+ lv2:index 2 ;
+ lv2:symbol "out" ;
+ lv2:name "Out"
+ ] .