Page 1 of 1
is there a way to get/set GUI values of device parameters?
Posted: Wed Jun 15, 2011 5:21 pm
by wlcmghsts
I'm looking for a way to set parameters with the GUI value - e.g., send 2000 ms to the release parameter of an Operator envelope. Within Live you're free to input a value in ms, but in M4L it looks that it only accepts values in the range of 0..1, using some logarithmic scale I haven't sat down and calculated. I'd rather not, and as different parameters have different ranges, it seems non-trivial to try to scale appropriately.
Anyone know if there are any methods/hacks/workarounds to achieve this?
Re: is there a way to get/set GUI values of device parameters?
Posted: Wed Jun 15, 2011 5:48 pm
by kgmonarch
wlcmghsts wrote:I'm looking for a way to set parameters with the GUI value - e.g., send 2000 ms to the release parameter of an Operator envelope. Within Live you're free to input a value in ms, but in M4L it looks that it only accepts values in the range of 0..1, using some logarithmic scale I haven't sat down and calculated. I'd rather not, and as different parameters have different ranges, it seems non-trivial to try to scale appropriately.
Anyone know if there are any methods/hacks/workarounds to achieve this?
M4L takes a LOT of different values (including values that go from 0-1)
But check out the "Scale" object -- it can scale values between an input range to conform to an output range AND apply a logarithmic scale.
Re: is there a way to get/set GUI values of device parameters?
Posted: Wed Jun 15, 2011 6:37 pm
by wlcmghsts
kgmonarch wrote:wlcmghsts wrote:I'm looking for a way to set parameters with the GUI value - e.g., send 2000 ms to the release parameter of an Operator envelope. Within Live you're free to input a value in ms, but in M4L it looks that it only accepts values in the range of 0..1, using some logarithmic scale I haven't sat down and calculated. I'd rather not, and as different parameters have different ranges, it seems non-trivial to try to scale appropriately.
Anyone know if there are any methods/hacks/workarounds to achieve this?
M4L takes a LOT of different values (including values that go from 0-1)
But check out the "Scale" object -- it can scale values between an input range to conform to an output range AND apply a logarithmic scale.
Yes, in general. For example, if I hook into the time parameter of a Simple Delay, it takes values in ms just fine... But specifically, the ADSR parameters in Operator or Analog, on the other hand, seem unfortunately unwilling to play nicely
I'm familiar with scale... I believe it's actually an exponential scale, which makes life a bit more complicated for my purposes. it might be simpler to write my own scaling expression and plugging it into expr at that point.
Scaling could be a solution, but I'd like for a way to programmatically read the min/max of the device parameter to adjust the range automatically. Take the attack and release, for example, they both appear to operate within 0..1 but in reality those values have very different interpretations - 20000 ms on the release parameter is in a much different location between 0..1 than it is for attack.
Re: is there a way to get/set GUI values of device parameters?
Posted: Wed Jun 15, 2011 7:53 pm
by kgmonarch
wlcmghsts wrote:kgmonarch wrote:wlcmghsts wrote:I'm looking for a way to set parameters with the GUI value - e.g., send 2000 ms to the release parameter of an Operator envelope. Within Live you're free to input a value in ms, but in M4L it looks that it only accepts values in the range of 0..1, using some logarithmic scale I haven't sat down and calculated. I'd rather not, and as different parameters have different ranges, it seems non-trivial to try to scale appropriately.
Anyone know if there are any methods/hacks/workarounds to achieve this?
M4L takes a LOT of different values (including values that go from 0-1)
But check out the "Scale" object -- it can scale values between an input range to conform to an output range AND apply a logarithmic scale.
Yes, in general. For example, if I hook into the time parameter of a Simple Delay, it takes values in ms just fine... But specifically, the ADSR parameters in Operator or Analog, on the other hand, seem unfortunately unwilling to play nicely
I'm familiar with scale... I believe it's actually an exponential scale, which makes life a bit more complicated for my purposes. it might be simpler to write my own scaling expression and plugging it into expr at that point.
Scaling could be a solution, but I'd like for a way to programmatically read the min/max of the device parameter to adjust the range automatically. Take the attack and release, for example, they both appear to operate within 0..1 but in reality those values have very different interpretations - 20000 ms on the release parameter is in a much different location between 0..1 than it is for attack.
Oh man, I see what you mean -- It's possible to read the VALUES from the parameter, much more difficult to get the RANGE. Well, not without some hacky routine where the user drags the knobs/sliders around and it 'captures' the value...