Or you may create an abstraction similar to the attached one, which mimics I think the behaviour of the [range] external included in (??) pd-extended (??)
Left inlet is the value to be rescaled; inlets 2 to 5 are input range min/max and output range min/max, respectively. Also, creation arguments can be used to initialize them.
So in your example you would use 0,1,-4,4 as creation arguments (or send them to the inlets starting from the second).
Hallo, matteo sisti sette hat gesagt: // matteo sisti sette wrote:
Or you may create an abstraction similar to the attached one, which mimics I think the behaviour of the [range] external included in (??) pd-extended (??)
Quite often I use a similar one which I called "expr_scale". It uses expr inside which isn't as fast, but it allows clean patching. (It's also part of the Pd version of RTC-lib.)
Frank Barknecht _ ______footils.org__