
;=====================================================================================
;	Example file for using CMask as a stochastic events generator within GeoMaestro
;		(see function GetStochEv() in lib/cmask_utils)
;=====================================================================================

; a warning message for the beginning of the generated .sco file: 
{
;# WARNING ! this is not a valid Csound score file !

;# ...it is supposed to be processed by GeoMaestro GetStochEv() function 
;#	to generate stochastic event scenes

;# parameters mapping:
;#--------------------
;# p1	ch
;# p2	(ignored) 
;# p3	dur
;# p4	vol
;# p5	pit
;# p6	x	(only if r=0, that is "p8 const 0" or no p8 at all)
;# p7	y	( id. )

;# optional:

;# p8	r
;# p9	theta
;# p10	polar center x
;# p11	polar center y

;# p12	selection flag (0 or 1)
}


f 0 400								; number of events to be generated (see below)

p1 item cycle (4, 5, 8, 9)			; GeoMaestro channel numbers

p2 const 1							; ... so that the f statement gives the number of events

p3 rnd exp 1						; durations (in clicks !)
mask 96 192

p4 const 127						; volumes

p5 rnd exp 1						; pitches
mask 40 100
quant 3

p6 rnd rexp 1						; x-positions
mask (0 -1 100 -2) (0 1 100 2)
quant (0 0.2 100 0.1) 1 (0 0 100 0.1) 

p7 rnd lin 1						; y-positions
mask -1 1
