system - perform any system call
system(command_line)
This provides a way to do from an RTcmix script most anything you could do from the shell.
This is most useful in scores for older disk-based Cmix instruments, for reasons discussed below.
The return value of the system call.
system("rm -f pvoctest.snd") system("sfcreate -c -s sun pvoctest.snd") output("pvoctest.snd") input("foo.aif") pvoc(0, 0, 20, 0, 1024, 2048, 150, 100, 0, 0) system("rescale -r pvoctest.snd")
Use system to call the sfcreate command-line utility to create an empty sound file. This is required by disk-based Cmix instruments. Use system to delete any existing ``pvoctest.snd'' file, because sfcreate complains if a file already exists. Finally, use system to call the rescale command-line utility.
The call is performed during the initialization portion of an RTcmix script that contains calls to real-time instruments. That is, it happens while RTcmix is parsing the script, but before it has run any of the instruments called in the script. This means you can't use system to rescale a sound file generated by instruments in the script, because the file won't contain anything yet when system does its work.
This is in contrast to the way the older disk-based Cmix instruments work: they execute as they are encountered in the script. That's why it works to run pvoc and then rescale the file.