| Hi Art,
You could maybe use strset/strget to convert from an string to an index:
http://csounds.com/manual/html/strset.html
http://csounds.com/manual/html/strget.html
to format a number into a string as you mentioned, you can use:
http://csounds.com/manual/html/sprintf.html
and use a format string of "%d.wav".
steven
On Wed, Jan 30, 2013 at 11:08 PM, Art Hunkins wrote:
> I need the event opcode to pass a filename to diskin in the called
> instrument.
>
> The filename is "1.wav".
>
> The problem? Event (or schedkwhen for that matter) does not take a string as
> an argument.
>
> Also, if I simply pass the numeric variable "1", I see no way of converting
> that to the string "1.wav". What am I missing?
>
> (I would like to pass filenames "1.wav" through maybe "10.wav" to the same
> called instrument, BTW.)
>
> Art Hunkins
>
>
> Send bugs reports to the Sourceforge bug tracker
> https://sourceforge.net/tracker/?group_id=81968&atid=564599
> Discussions of bugs and features can be posted here
> To unsubscribe, send email sympa@lists.bath.ac.uk with body "unsubscribe
> csound"
>
|