Working with viewpoints » History » Version 1

Jeremy Gow, 2013-04-09 12:42 PM

1 1 Jeremy Gow
h1. Working with viewpoints
2 1 Jeremy Gow
3 1 Jeremy Gow
A number of functions are provided to inspect viewpoints.
4 1 Jeremy Gow
5 1 Jeremy Gow
h2. Inspecting viewpoint values
6 1 Jeremy Gow
7 1 Jeremy Gow
<code>music-data:composition-viewpoint</code> will return the viewpoint values for a specific composition.  For example, for composition 3 of dataset 0, the linked viewpoint <code>'(cpint ioi)</code> has the following values:
8 1 Jeremy Gow
9 1 Jeremy Gow
<pre>
10 1 Jeremy Gow
CL-USER> (music-data:composition-viewpoint 0 3 '(cpint ioi))
11 1 Jeremy Gow
((0 12) (-300 12) (0 12) (-200 12) (-200 24) (0 12) (-100 12) (100 12) (200 12)
12 1 Jeremy Gow
 (-200 24) (500 12) (0 12) (0 12) (0 12) (-100 12) (100 12) (200 12) (-700 60)
13 1 Jeremy Gow
 (0 12) (0 12) (0 12) (400 12) (0 12) (100 12) (200 12) (0 24) (-700 12)
14 1 Jeremy Gow
 (700 24) (0 12) (200 12) (-200 12) (-300 12) (-400 12) (200 12) (-200 12))
15 1 Jeremy Gow
</pre>
16 1 Jeremy Gow
 Similarly, <code>music-data:dataset-viewpoint</code> returns the values for all compositions in a specific dataset, as a list of lists.