patch cords within abstractions

nickdesigner's icon

Hi everyone,

Just a quick visual thing that has been bugging me - when you save an abstraction, all the patch cords coming from inlets are the data type, even if you are sending audio signal information through them. Is there a way to change this to reflect that they are audio signals coming in?

many thanks,
Nick

Roman Thilenius's icon

nope.

what you could do is give them a yellow color.

or close and reopen after the DSP is turned on ...

-110

Peter Castine's icon

At the time the abstraction is instantiated, there are not yet any patch cords connected to the abstraction's inlet. If there isn't a typed patch cord connected to the inlet in the abstraction's box (the "outside" of the abstraction), the inlet object on the "inside" of the abstraction can't know anything about the data types that will be coming through. Since the patch cord pattern (plain Max vs. yellow striped MSP vs green Jitter) is set at the time the patch cord is created, Max defaults to plain black lines.

There are some heuristics that could be used to try to guess that an inlet will be handling only MSP or Jitter messages, but I don't think they would be reliable. Only guessing the correct cord type some of the time would be even more annoying (and confusing!) then always defaulting to plain Max patch cords. It would be sorta nice if Max could "upgrade" patch cords inside an instantiated abstraction once connections are made in the parent patcher and it can be determined what kinds of messages are being passed from the parent into the abstraction. But Max doesn't do that.

Who knows, maybe in Max6 this will happen. The current behavior is a little confusing until you get used to it. Max6 is supposed, at least in part, to be about making things less confusing for newcomers.

Roman Thilenius's icon

i dont see why anyone would open a window before the DSP is turned on but it is
true that this situation can happen, because audio is never turned on before data
has finished initialising.

eventualy someone could invent an audio-only inlet object, which could handle this,
but this will still require a change to the max app (so only they can do it)

nickdesigner's icon

Thanks for the responses.

For some reason even when I have DSP on, they still don't reflect that there is audio signals coming in. I would like to be able to differentiate because when I'm debugging and I have a number of embedded abstractions, it gets confusing.

I took Roman's advice and just colored them yellow - which does the trick. It would even be nice to be able to change other properties of a cord (like thickness).

many thanks,
Nick

Peter Castine's icon

As above, by the time you turn DSP on the patch cord has already been created. It's simply too late.