[umenu] files change automatically. WHY?
Hi,
I have a [umenu] populated with several .wav files from a folder. I play the audio with [notein]>[stripnote]>[pack 0 0]>[route 60]. BUT everytime i press the midi key(60) the sample changes to the next in the list.
Why does it do this? How do get it to NOT change automatically?
Thanks!
tell [umenu] specifically which file you want to play with a number in a message box. [umenu] counts from 0.
That works, but i want to be able to pick(via mouse click on menu) which file i want to play.
It still cycles through ALL of the samples....
Should it not cycle?
Shouldn't cycle if you tell it explicitly which one to play using the mouse or a message box. Check what's coming out of [route] and be sure it's not a bang, if it is, run it through a message box with a number. That shouldn't cycle the umenu.
Nope, i still cant get it to work right.
Could you have a look at the patch and see what could be wrong?
Ok, nevermind i managed to get it working. I added a button between [route] and [umenu]. Not sure why i never tried it before.(noob)
I thought that [route] produced a bang automatically when sending output.
And now i've noticed in [route] ref/example there are [button]'s everywhere. I just thought the [button]'s where simply to show that the message was passed through.(noob)
@Nicolas Danet: Im not sure why you pasted that patch. Thank you for taking the time. :)
But i wasnt saying that using the [message] did not work. Selecting from [umenu] and playing the selected sample was the problem.
Anyways, its fixed! BANG! :)
Yes it does! I read somewhere about it, then forgot.... Thanks.
So i take it using [select] (not having to use [button]'s for bangs), this would lighten the CPU load very slightly?
Hi,
But if im not mistaken, its not possible to load a series of different named files into a buffer without specifying the names physically? Right?
No, what i mean is. I have to document every file name and assign a number manually. Am i wrong?
One file per buffer~ and one file per sfplay~, but you can change them whenever you want. sfplay~ will start right away, buffer~ will take a split second to load small files and a bit longer for large ones. In your case I'd use sfplay~ and change the file targets.
I agree, i think sfplay~ is the one to go with. The CPU seems really ok. If this changes i'll have a look into buffer~.
Just what do you mean by change the file targets? I dont understand.
Oh, just sending sfplay~ or buffer~ new filenames to open. sfplay~ uses "open", buffer~ uses "read".