Floating message box OR parameter highlighting

Norman Freund's icon

Challenges:
1. Show a floating text window.
or 2. Highlight parameter in device and make that device/track selected.
or 3. Messages from Max to Live message window.
and 4. Determine programmatically if a third party parameter is "included in presentation" i.e. visible.

Details:
Just finished my first useful Max for Live device which takes incoming midi CC values to control a specified parameter within specified track and device ID. Intended purpose is for musicians that do not have their hands free to twiddle the knobs in Live whilst playing and want to change which knob to twiddle with the midi foot controller.

It all works as I want but, where the track, device and parameter IDs are selected (foot controller button, increment, decrement commands), the name of the track, device and parameter are shown in the tool, but I may not be able to simultaneously view the device that is being controlled, i.e. to see what knob is being adjusted. I see some possible solutions but can not find the Max objects to achieve this:


1. Use a floating text window to display the information, such a window would always be visible,

2. What ever device is selected this would be made the current device and the parameter being modulate would be highlighted,

3. Display in Live on the bottom command prompt (is probably called something else, ie the message bar along the bottom of Live.

I looked through the LOM -- no luck. I browsed through all the Max and Live objects no luck.

One additional thing, I would like to determine if the selected parameter has it's "Include In Presentation" as active or not. This is all being controlled from Ableton Live, and from my reading of the manuals, such parameters are not accessible, so as not to break Live. Any work arounds?

Below is a screen grab of the tool.
Thanks in advance,
Norman Freund

Tool layout.

Norman Freund's icon

Here are some more details, which perhaps better explain what I am trying to achieve:

Some more details of what I am trying to achieve in Max for Live:

Track 1 is the Midi Foot Controller, accepting midi messages
for track, device and parameter selection to control say Track 2. This holds my custom Max for Live program (device) called “NOF-Midi2Patch_12”. See Figure 1.
The track, device and parameter increment and decrement buttons are mapped to specific midi foot controller buttons.

Track 2 in this example, shown below, is for an electric violin which I want to control with the midi foot controller, but adhoc select which effect/parameter to modulate. See Figure 2.

So as expression pedal sends out CC 91, my Max for Live device “NOF-Midi2Patch_12” routes this to track 2, device 2, the Treble in this case. Once the treble is dialled in I press another midi foot controller button to advance to a different device/parameter combo, for the expression pedal to map to. This is all hands free. The midi controller and the track it controls are on different tracks, so really need some visual feed back mechanism to know which effect is being modulated, ideally with the track being modulated made the one visible.

So the “highlighted” parameter would perhaps look like as shown in Figure 3, which signals to the user that effect “Treble” is being modulated with the midi foot controller expression pedal.
Trying to figure out if such highlighting is possible in Max for Live and if so what object is used for that. Once I know what object, the rest should be easy, just read the manual.

Alternatively the space shown in brown in Figure 4 could be filled with some text signalling to the user what is being modulated with the midi foot controller expression pedal. Don’t know if Max for Live allows you to write to this. This portion of the Live windows is always visible regardless of which track/device is current.

Then finally what I called a “floating window”, the red window shown below, providing an example of what it might look like. Not a standard Live window, but a window generated from Max, shown in Figure 5.

Perhaps I have to create an external OSC receiver in Objective C programming environment, where Max for Live sends OSC messages to it to display a message in a “Floating Window”. I do this all on an Apple iMac and also program in Objective C. Mind you learning how to program an OSC receiver in Objective C would be another learning curve.

Hope this makes more sense now.

Regards,
Norman Freund

Figure 1: shows my custom Max for Live device, NOF-Midi2Patch_12

Figure 2: Shows the track/devices/parameters I am trying to control (typical example)

Figure 3: example of effect to be controlled. Parameter currently under control highlighted in brown.

Figure 4: Highlighted in brown, proposed Live portion of screen to write custom message to.

Figure 5: Example of floating window.

Source Audio's icon

Are embeded patchers in max4live devices not able to open floating windows ?
you only need a patcher containing display of your wanted params,
thispatcher object inside, and feed it with
window messages, like
window size 200 200 400 460, wundow flags float, window flags noclose,
window flags nogrow, window nomenu, etc etc, window exec.
bang front using metro in case Live sends it to back...
and pcontrol to open - close the patcher window.

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

Norman Freund's icon

Thanks Source Audio, just trying out your suggestions and trying out the sample patch you provided. Much appreciated.

Norman Freund's icon

I would prefer the latter approach :) . So here is the sticking point. Easy enough to find the reference manual page for "thispatcher", but all the messages and attributes, just can not find these in the manual. just copy and paste this code into my patch and use its (fingers crossed), modifying as necessary (fingers crossed); or I could take it apart with a fine tooth comb to understand what is happening, finding each message in the Max Reference manual, to properly understand how to code this up.

I would prefer the latter approach :) . So here is the sticking point. Easy enough to find the reference manual page for "thipatcher", but all the messages and attributes, just can not find these in the manual.

brgb: background color with red, green blue integer arguments (found in manual as bgcolor.)

window -- how can I find this in the reference manual? I suspect these are attributes, like, "windows" means the subpatch window being shown, then has attributes of size, flags, etc. Where is the documentation for this? It looks like some hierarchical list.

Source Audio's icon

to start, read help file for thispatcher object,
in first place window messages .
Patch I posted has all it needs to open that floating window,
all you need to complete it, is to adjust window size and coordinates,
make all that window controlling stuff out of sight,
and add stuff you want displayed into it.

pcontrol in main patch (that should be your m4l device)
takes care of opening - closing of the window,
and you also have close button in it if you want.
So just go for it.

The messages I used are merged into single one using comma
between, which outputs them one by one.
there is lock and unlock toggle in main patch, which switches
2 different window settings.
I don't use presentation mode, don't like it, so I place
all that I don't want to see outside of
visible area of locked patch, which gets shown
when one unlocks the patch with larger window size set.

If you prefer presentation mode, than you have other options too.

Have fun learning...

Source Audio's icon

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

Norman Freund's icon

Woo hoo. It's working. I only spotted your second patch just a minute ago, Source Audio. From your first post, I did manage to get a functional floating window. I did not implement all your settings, just the bits that apply for me. Awesome :) :) .

Just tried your second code clip -- funny ha ha. Yes I get it now :) .

Now for others scratching their heads (it might just be me), here is a screen grab of the thispatch messages that Source Audio used and my best attempt in describing them. Some still remain a mystery. Some are described in the Max Ref manual, others are not.

Norman Freund's icon

All working. The floating window working as it should and can control adhoc any parameter of any device within any track just by using midi foot controller button presses, leaving the musician's hand free to play the instrument (electric violin in my case). Thanks again Source Audio for your help.

Figure 1: Typical example.

Figure 2: The device window.

Figure 3: The floating window.