[live.dial]+Push: display symbol instead of int

Sep 22, 2013 at 9:06pm

[live.dial]+Push: display symbol instead of int

After building a lot of stuff from tutorials and poking around devices from M4L.com, I’ve decided to build a preset manager that works well on Push; a bunch of buttons that each eat up an encoder on Push is not going to work.

I’d like to use a live.dial to recall presets and I have indeed looked at WhiteBox’s lovely knob for doing so, but I’d rather not have to memorize [what number = what preset]…

I have worked out how to give names to preset slots in pattrstorage, but I’d like those names to show up on Push.

There are some pretty ugly ways to make that happen, like destroying/recreating the live.dial whenever something in pattrstorage changes. Eww.

Since I am fairly new to M4L, I don’t know all of the sneaky little undocumented* stuff. I’d like to somehow “hijack” the live.dial’s output before it gets sent to Push (or any control surface, I suppose)

I have a pretty solid js/jQuery background from doing web stuff, but forget about C or Java.

Any idears?

*apparently C74 has no plans to release full docs — I’ve read that a lot here

#265952
Sep 23, 2013 at 9:37am

If the data type of the live.dial is set to “enum” in the inspector, Push will display the symbols in your enumerated list. This is how it *should* work…

However, when I tried this, I found that the actual correspondence between the value displayed on Push and the value in the device is not precisely 1:1. This is especially noticeable for small adjustments in large lists and basically makes the technique useless. Unfortunately, probably not much to do there but complain and wait for a fix.

#266027
Sep 23, 2013 at 11:13am

The knobs track a lot better when the number of steps matches the number of list items.

However, when I tried this…

How are you feeding the list items into the dial?

I have yet to find anything in the pattr tutorials/docs that describe how to do that.

#266035
Sep 23, 2013 at 12:07pm

How are you feeding the list items into the dial?

Not dynamically, I’m afraid. Just pasting a space-delimited list into the “Range/Enum” field in the inspector. As this is a “hidden” attribute, I don’t believe you can change it without (as you indicated above) destroying/creating the live.dial with a script.

#266045
Sep 23, 2013 at 12:41pm

Yesterday, I discovered (quite by accident) that you can get the names of hidden parameters by selecting the parameter in the inspector, copying to clipboard [ctrl/cmd+C], then pasting into a text editor.

#266051
Sep 23, 2013 at 9:50pm

Good catch! Yeah, then I suppose a list with “_parameter_range” prepended to it is what you’re after for changing list items dynamically. Wouldn’t have thought to try that; thanks for the tip.

#266079
Sep 23, 2013 at 10:37pm

I didn’t think to try it either; I was trying to copy/paste a value somewhere and I somehow ended up doing that in a moment of spaz. Not too shabby, though… :)

#266080

You must be logged in to reply to this topic.