summing signals + exponential curves

forge13's icon

Hi all.

Is there a MSP version of expr? I need to sum about 6 signals together.

Also, what is the best way to convert a midi stream (0-127) to an exponential curve to control a meter such as a volume slider?

thanks

brendan mccloskey's icon

I'm sure I recall seeing a thread related to your first question; search for expr + msp, or expr + signal.

As for the second, I found this use of [expr], but cannot recall the author:

1526.midiGain.jpg
jpg
Luke Hall's icon
Max Patch
Copy patch and select New From Clipboard in Max.

That was me I think. In this case something like the following patch might be easier though. Change the [pow] argument and mess with the slider to hear the effects.

Roman Thilenius's icon

the volume slider is as linear as midi, no need to scale.

Christopher Dobrian's icon
Max Patch
Copy patch and select New From Clipboard in Max.

Here's something much like Luke's solution, but using the decibel scale.

Trond Lossius's icon

You could also take a look at the jcom.map and jcom.dataspace externals, part of Jamoma:

www.jamoma.org

Roman Thilenius's icon

btw, about your first question, you can sum signals using any MSP object, just
connect 6 signals to one inlet and thats it.

Peter Castine's icon

I recall that someone made an attempt at an [expr~] object in the very early days of MSP, but it was CPU-intensive and very crash-prone.

There's nothing you can do with expr (or an expr~) that you can't do by patching together mathematical objects. Although this can be a bit of work with complex formulae, at least it works.

goodparleyandorfing's icon

It might be the same one peter mentioned though; haven't used it myself