problem with patch

buz's icon

Hi guys, I have been getting help from a member called Brendan, but I have a deadline coming up VERY soon and just need a last bit of advice for my patch.
I am trying to add a random audio sample player, so every time a pressure sensor pressed to the threshold of 110, is it triggers a random sample. Everything works fine except the random samples.
I have got it working crudely with the preload method, but it doesn't seem to work properly.

any advice to complete my patch and I will be FREE!

2107.degreetest.png
png
jvkr's icon

Maybe a [prepend open] between the menu object and the sfplay~? Since the threshold is 110, who knows Roman has better advice, he's the expert.

brendan mccloskey's icon

yes, i think i recall suggesting a [prepend open] myself; another alternative would be to use multiple [sfplay~] objects and send random numbers to a [selector~ 6], where 6 is the number of [sfplay~] objects. Re-read the [sfplay~] helpfile, including the [p more features] subpatch.

Alternately, just use this:

Max Patch
Copy patch and select New From Clipboard in Max.

a more sophisticated version would use the [dropfile] object too, but whatever..........
Brendan

brendan mccloskey's icon

.......but what is this forum for if not sharing?

Here's a handy utility which autopopulates a [umenu] with soundfile names and path, from any folder on your HD:

Max Patch
Copy patch and select New From Clipboard in Max.

Brendan

as long as we all get a mensh in your bibliography!!

buz's icon

Thanks so much for your help and advice!
I have ALMOST got the patch working but there are a couple of bugs I can't sort out.
basically all of the preloads only play about 5 seconds is there a script that makes a sample play to the end?
I looked at sfplay and it says that you can define a start time say 800ms on a preload, but fi you leave the rest blank it should play to the end?

regards,

2116.degreetest.png
png
Roman Thilenius's icon

110 is not the treshhold, it is the reference for perfect sound.

brendan mccloskey's icon

We can only help if you post your patch, rather than an image of it......

buz's icon

Here is a segment of the patch. It is essentially duplicated.

Max Patch
Copy patch and select New From Clipboard in Max.

Chris Muir's icon
Max Patch
Copy patch and select New From Clipboard in Max.

I fixed a few things:

buz's icon

FANTASTIC! I think the problem might have been my labeling of the sflist, the number was only meant to distinguish it from another sflist, and maybe adding that number made it think i wanted them to run for 4 seconds?
I removed the number and it's fixed!

Thank you so much for your help, and indeed everyones, if you want to post your names I will add them to my acknowledgement list.

regards,