Forums > MaxMSP

Getting Random to accept float values

Mar 03 2011 | 7:29 pm

I am looking to generate random inharmonic frequencies for cycle is there a way for random to accept float values or is this a job for an external object?

Mar 03 2011 | 8:00 pm

[random] doesn’t do floats. But you can do something like this:

-- Pasted Max Patch, click to expand. --

Mar 03 2011 | 8:58 pm

Cheers for that multiplying by 1.0 is an other way? But there is no way to use a float as an argument only an int is it? Cheers again mate.

Mar 04 2011 | 8:40 am

Not sure it will help, but you can make some sort of float accepting random this way (you decide the precision of the float):

-- Pasted Max Patch, click to expand. --

Mar 04 2011 | 1:24 pm

i have made an abstraction which is basically similar to a [random] object, but you can define minimum + maximum values, as well as step size (default = 1).

it also accepts negative numbers and floats (but for floats you need to define the step size) (it’s the last one on the list)

hope this helps :)

Mar 04 2011 | 2:04 pm

my 2 cents

-- Pasted Max Patch, click to expand. --

Mar 04 2011 | 5:00 pm

I use this sometimes.

Viewing 7 posts - 1 through 7 (of 7 total)

Forums > MaxMSP