Csound Csound-dev Csound-tekno Search About

Re: Composing with detailed parameters

Date1998-04-29 00:25
FromMichael Gogins
SubjectRe: Composing with detailed parameters
>Michael Gogins wrote :
>
>>MY music is DEFINITELY represented in physical values such as Hz, location
>>in space by angle, phase, and loudness in dB.
> Hello Michael (& All the rest of you!),
>
>I'm interested in your approach to specifying these details while
>composing.Do you use any particular interface to write Csound scores and
>do you use any other software/device to help
>visualize and cope with the composition process ? Do you use standard
>notation and do you hack it
>to represent various parameters ?
>


I write my own software that generates Csound scores. My current software
assumes the Csound pfields are laid out:

p1    instrument number
p2    starting time of note in seconds
p3    duration of note in seconds
p4    pitch in linear octaves, where middle C = 8.0.
p5    loudness in decibels, where 0 is silence and 96 dB is the loudest you
can get out of 16 bits.
p6    phase in units of pi
p7    x coordinate of spatial location, the origin is the listener
p8    y coordinate of spatial location
p9    z coordiante of spatial location

Additional pfields can be used to control other parameters of instruments.

Since all my instruments have these 9 fields, I can rearrange a piece just
by reassigning the instrument numbers to different instruments. In fact my
software does this for me - it has a patch library with about 50 instruments
in it, and I pick the ones I want out and put them in the right order, and
that's my arrangement.

I should add the instruments are adjusted so that if p5 = 80 decibels, the
average maximum amplitude of the note is as close as I can get to 15848.926,
which is what ampdb(80) returns in Csound.

And I use the following code to make the x coordinate of space translate to
a constant power pan between the stereo speakers:

; x location ranges from hard left = -1 through center = 0 to hard right =
1.
; angle of pan ranges from hard left = - pi / 2 through center = 0 to hard
right = pi / 2.
ix   = p7
iangle  = ix * 3.14159265359 / 2.0
ileftpan = sqrt(2.0) / 2.0 * (cos(iangle) + sin(iangle))
irightpan = sqrt(2.0) / 2.0 * (cos(iangle) - sin(iangle))

I sometimes do write standard music notation, which I save as MIDI and
translate to the above Csound score format, also using software I have
written.

But more often, my software uses fractals, Lindenmayer systems, chaotic
dynamical systems, and so on. These things generate sequences of notes. Each
sequence goes into one node of a tree structure, and some of the nodes also
apply compositional transformations to their children. The end result is a
single Csound score with a set of instruments to realise it.

I also have written simple programs to generate Csound scores by using
fprintf(fileHandle, "i %0.9f %0.9f %0.9f %0.9f %0.9f %0.9f %0.9f %0.9f
%0.9f\n", p1, p2, p3, p4, p5, p6, p7, p8, p9) to write out the note
statements, or the equivalent in other languages.