aboutsummaryrefslogtreecommitdiffstats
path: root/lv2/lv2plug.in/ns/ext/atom/atom.ttl
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2012-03-02 00:03:53 +0000
committerDavid Robillard <d@drobilla.net>2012-03-02 00:03:53 +0000
commit6a848b53ef158648a4dc25274afeb668c530abd9 (patch)
treeac346e53c87f379a1e6ca082b0963b6394b7498f /lv2/lv2plug.in/ns/ext/atom/atom.ttl
parent88135c7bb27557e214928918ca46ecb86c790a0b (diff)
downloadlv2-6a848b53ef158648a4dc25274afeb668c530abd9.tar.xz
Add atom:childType.
Rename vector fields for consistently with atom:childType. Change vector to have child type and size rather than num_elems, since that would require updating the body every time an element is added which ruins the usual atom construction pattern. Implement incremental/automatic vector building with forge.
Diffstat (limited to 'lv2/lv2plug.in/ns/ext/atom/atom.ttl')
-rw-r--r--lv2/lv2plug.in/ns/ext/atom/atom.ttl21
1 files changed, 12 insertions, 9 deletions
diff --git a/lv2/lv2plug.in/ns/ext/atom/atom.ttl b/lv2/lv2plug.in/ns/ext/atom/atom.ttl
index 1a2b92a..1b2ed1d 100644
--- a/lv2/lv2plug.in/ns/ext/atom/atom.ttl
+++ b/lv2/lv2plug.in/ns/ext/atom/atom.ttl
@@ -262,26 +262,24 @@ atom:Vector
lv2:documentation """
<p>A homogeneous series of atom bodies with equivalent type and size.</p>
-<p>An LV2_Atom_Vector is a 32-bit <code>elem_count</code> and
-<code>elem_type</code> followed by <code>elem_count</code> atom bodies of type
-<code>elem_type</code>. The element type must be a fixed size atom:Atom type,
-i.e. the size of each element is the vector's <code>size /
-elem_count</code>.</p>
+<p>An LV2_Atom_Vector is a 32-bit <code>child_size</code> and
+<code>child_type</code> followed by <code>size / child_size</code> atom
+bodies.</p>
<p>For example, an atom:Vector containing 42 elements of type atom:Float:</p>
<pre class="c-code">
struct VectorOf42Floats {
+ uint32_t size; // sizeof(LV2_Atom_Vector_Body) + (42 * sizeof(float);
uint32_t type; // map(expand("atom:Vector"))
- uint32_t size; // sizeof(LV2_Atom_Vector) + (42 * sizeof(float);
- uint32_t elem_count; // 42
- uint32_t elem_type; // map(expand("atom:Float"))
+ uint32_t child_size; // sizeof(float)
+ uint32_t child_type; // map(expand("atom:Float"))
float elems[42];
};
</pre>
<p>Note that it is possible to construct a valid Atom for each element
of the vector, even by an implementation which does not understand
-<code>elem_type</code>.</p>
+<code>child_type</code>.</p>
""" .
atom:Tuple
@@ -497,6 +495,11 @@ connected to. It says nothing about the expected contents of containers. For
that, use atom:supports.</p>
""" .
+atom:childType
+ a rdf:Property ;
+ rdfs:label "Child type" ;
+ rdfs:comment "The type of a container's children." .
+
atom:supports
a rdf:Property ;
rdfs:label "Supports" ;