summaryrefslogtreecommitdiff
path: root/examples/pdhalf.csd
diff options
context:
space:
mode:
authorFelipe Sateler <fsateler@debian.org>2014-01-24 13:54:37 -0300
committerFelipe Sateler <fsateler@debian.org>2014-01-24 13:54:37 -0300
commitbcf06a42deb371baf3deb9f4addb474b08273120 (patch)
tree4a8c3fb811dd164d4486628d8eff6043ebe8a6c3 /examples/pdhalf.csd
parent3a91171181113761a14bcc36a086a8dda144b77b (diff)
Imported Upstream version 6.02~dfsg
Diffstat (limited to 'examples/pdhalf.csd')
-rw-r--r--examples/pdhalf.csd39
1 files changed, 32 insertions, 7 deletions
diff --git a/examples/pdhalf.csd b/examples/pdhalf.csd
index d2e1389..2aeda48 100644
--- a/examples/pdhalf.csd
+++ b/examples/pdhalf.csd
@@ -1,13 +1,18 @@
<CsoundSynthesizer>
<CsOptions>
; Select audio/midi flags here according to platform
-; Audio out Audio in
--odac -iadc ;;;RT audio I/O
+-odac ;;;realtime audio out
+;-iadc ;;;uncomment -iadc if realtime audio input is needed too
; For Non-realtime ouput leave only the line below:
-; -o abs.wav -W ;;; for file output any platform
+; -o pdhalf.wav -W ;;; for file output any platform
</CsOptions>
<CsInstruments>
-; test instrument for pdhalf opcode
+
+sr = 44100
+ksmps = 32
+nchnls = 2
+0dbfs = 1
+
instr 4
idur = p3
@@ -21,7 +26,7 @@ instr 4
apd pdhalf aosc, kamount
aout tablei apd, itable, 1
- out aenv*aout*iamp
+ outs aenv*aout*iamp, aenv*aout*iamp
endin
</CsInstruments>
@@ -35,13 +40,33 @@ f3 0 16385 9 1 1 270 ; inverted cosine
; pdhalf with cosine table
; (imitates the CZ-101 "sawtooth waveform")
t 0 100
-i4 0 .333 10000 512 3
+i4 0 3 .6 512 3
+i. + . . 448
+i. + . . 384
+i. + . . 358.4
+i. + . . 341.33
+i. + . . 298.67
+i. + 5 . 256
+s
+; pdhalf with a sine table
+t 0 120
+i4 0 3 .6 512 1
+i. + . . 448
+i. + . . 384
+i. + . . 358.4
+i. + . . 341.33
+i. + . . 298.67
+i. + 5 . 256
+s
+; pdhalf with a sawtooth-like table
+t 0 150
+i4 0 3 .6 512 2
i. + . . 448
i. + . . 384
i. + . . 358.4
i. + . . 341.33
i. + . . 298.67
-i. + 2 . 256
+i. + 5 . 256
e
</CsScore>
</CsoundSynthesizer>