Debian Codegraph @

src/Examples/CsoundQt/Miscellaneous/Just_Intonation.csd

raw
1 <CsoundSynthesizer>
2 <CsOptions>
3 </CsOptions>
4 <CsInstruments>
5
6 sr = 44100
7 ksmps = 128
8 nchnls = 2
9 0dbfs = 1
10
11 instr 1 ; Equal temperament
12 ; p4 in pitch class
13 xtratim 0.3
14 aenv linenr 0.4, 0.01, 0.3, 0.01
15 aout oscili aenv, cpspch(p4), 1
16 outs aout*p5, aout*(1-p5)
17 endin
18
19 instr 2 ; Just intonation
20 ; p4 in interval fraction
21 xtratim 0.3
22 aenv linenr 0.4, 0.01, 0.3, 0.01
23 aout oscili aenv, p4 * cpspch(8.00), 1
24 outs aout*p5, aout*(1-p5)
25 endin
26
27
28 </CsInstruments>
29 <CsScore>
30 f 1 0 1024 10 1
31 ; Equal tempered
32 i 1 0 3 8.00 0
33 i . 0 . 9.00 1
34 i . + . 8.00 0
35 i . ^+0 . 8.07 1
36 i . + . 8.00 0
37 i . ^+0 . 8.04 1
38 i . + . 8.00 0
39 i . ^+0 . 8.10 1
40 i . + . 8.00 0
41 i . ^+0 . 8.04 1
42 i . ^+0 . 8.07 0
43 i . ^+0 . 8.10 1
44 i . + . 8.00 1
45 i . ^+0 . 8.04 1
46 i . ^+0 . 8.07 0
47 i . ^+0 . 8.10 0
48 s
49 ; Now with just intonation
50
51 i 2 0 3 [1/1] 0
52 i . 0 . [2/1] 1
53 i . + . [1/1] 0
54 i . ^+0 . [3/2] 1
55 i . + . [1/1] 0
56 i . ^+0 . [5/4] 1
57 i . + . [1/1] 0
58 i . ^+0 . [7/4] 1
59 i . + . [1/1] 0
60 i . ^+0 . [5/4] 1
61 i . ^+0 . [3/2] 0
62 i . ^+0 . [7/4] 1
63 i . + . [1/1] 1
64 i . ^+0 . [5/4] 1
65 i . ^+0 . [3/2] 0
66 i . ^+0 . [7/4] 0
67 e
68 </CsScore>
69 </CsoundSynthesizer>
70
71 <bsbPanel>
72 <label>Widgets</label>
73 <objectName/>
74 <x>656</x>
75 <y>80</y>
76 <width>620</width>
77 <height>359</height>
78 <visible>true</visible>
79 <uuid/>
80 <bgcolor mode="background">
81 <r>62</r>
82 <g>162</g>
83 <b>69</b>
84 </bgcolor>
85 <bsbObject type="BSBScope" version="2">
86 <objectName/>
87 <x>9</x>
88 <y>8</y>
89 <width>290</width>
90 <height>299</height>
91 <uuid>{efed7bdd-1a9e-49ef-9f95-15ddcc36e9ee}</uuid>
92 <visible>true</visible>
93 <midichan>0</midichan>
94 <midicc>-3</midicc>
95 <description/>
96 <value>-255.00000000</value>
97 <type>lissajou</type>
98 <zoomx>2.00000000</zoomx>
99 <zoomy>2.00000000</zoomy>
100 <dispx>1.00000000</dispx>
101 <dispy>1.00000000</dispy>
102 <mode>0.00000000</mode>
103 </bsbObject>
104 <bsbObject type="BSBLabel" version="2">
105 <objectName/>
106 <x>310</x>
107 <y>10</y>
108 <width>277</width>
109 <height>255</height>
110 <uuid>{bda8811b-e831-48b2-969a-5b571eb11896}</uuid>
111 <visible>true</visible>
112 <midichan>0</midichan>
113 <midicc>-3</midicc>
114 <description/>
115 <label>
116 This file shows the difference for a few intervals with Equal temperament and Just Intonation. One note of the interval is placed on the left channel and the other note on the right. The lissajous scope on the left shows the correlation between the channels. Since just intonation intervals are more closely related the graphic display is cleaner.</label>
117 <alignment>center</alignment>
118 <valignment>top</valignment>
119 <font>TeX Gyre Heros</font>
120 <fontsize>14</fontsize>
121 <precision>3</precision>
122 <color>
123 <r>0</r>
124 <g>0</g>
125 <b>0</b>
126 </color>
127 <bgcolor mode="background">
128 <r>255</r>
129 <g>255</g>
130 <b>255</b>
131 </bgcolor>
132 <bordermode>true</bordermode>
133 <borderradius>1</borderradius>
134 <borderwidth>1</borderwidth>
135 </bsbObject>
136 <bsbObject type="BSBButton" version="2">
137 <objectName>_Play</objectName>
138 <x>310</x>
139 <y>273</y>
140 <width>278</width>
141 <height>33</height>
142 <uuid>{52bc96cf-049f-41b8-9103-1186aaea8fdd}</uuid>
143 <visible>true</visible>
144 <midichan>0</midichan>
145 <midicc>-3</midicc>
146 <description/>
147 <type>value</type>
148 <pressedValue>1.00000000</pressedValue>
149 <stringvalue/>
150 <text>Run</text>
151 <image>/</image>
152 <eventLine/>
153 <latch>false</latch>
154 <latched>false</latched>
155 <fontsize>10</fontsize>
156 </bsbObject>
157 </bsbPanel>
158 <bsbPresets>
159 </bsbPresets>