object suggestion: the opposite of 'route'

Basvlk's icon

Or does something like this already exist?

It would be great if hovering over the inlets would display which word will be prepended.

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

(karrrlo)'s icon

check the java script based osc-unroute object:

(karrrlo)'s icon

i forgot to mention it works best in combination with CNMAT's great  [osc-route] object which uses an OSC based syntax.

very handy

Mike S's icon

Would this help?

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

Basvlk's icon

I've used osc-route but ended up using route in most cases (it's a little bit faster) because in most cases I dont use the /../.../.. hierarchy - I just route on one term.

I think the java based osc-unroute was a little slow too. I'm happy with the abstraction I made, I just thought it might make a good object to be included in Max MSP

Mike S - thanks for your patch: that's a clever way of doing it, I'm going to remember that. In fact the sliders were just there to demostrate how the object works: I'm just thinking something like 'funnel' which outputs values but prepended with a textstring rather than a number would be useful.

Cheers!

Richard Garrett's icon

Peter Elsea has an Lobject to do this - though it doesn't do hover. It's called [Label] but he also refers to it as 'the Great Prepender'.

Check out Lobjects here:

best wishes

Richard

Basvlk's icon

Excellent, thanks Richard!

Mike S's icon
Max Patch
Copy patch and select New From Clipboard in Max.

I prepared a little JS as an exercise.

Save below as unroute.js

autowatch = 1;
outlets = 1;

if (jsarguments.length > 0)
{
    inlets = jsarguments.length - 1;
}

function anything()
{

    var input = arrayfromargs(messagename, arguments);

    var index = inlet;

    outlet(0, jsarguments[index + 1], input);

}