Csound Csound-dev Csound-tekno Search About

Converting midi pitch to cps?

Date1998-09-15 22:46
FromEdward Spiegel
SubjectConverting midi pitch to cps?
OK. So, the problem I was having with MidiToCSound was that it doesn't 
output the pitch by default.

Now that I've got that working, I have a new question. MidiToCSound 
expresses the pitch as the midi note number. Is there a pitch converter 
that will take a midi note number value and convert it to cps, pch or oct 
format?

As far as I can tell cpsmidi and cpsmidib only work for realtime stuff. I 
tried:

icps = cpsmidi(p4)

That doesn't work. Is there a pitch converter function that will do this? 
(I'm using the latest CSound for PPC from Mills).

Here is a sample of what midiToCsound puts out

i 1 0.000 0.237 48
i 1 0.000 0.237 72
i 1 0.250 0.237 55
i 1 0.250 0.237 63


Thanks,