MULTILABEL: HOW DO I LABEL PADS?

Discuss Lemur and share techniques.
Post Reply
esegabbo
Newbie
Posts: 15
Joined: 13 Dec 2011 22:48

MULTILABEL: HOW DO I LABEL PADS?

Post by esegabbo »

Hi, I was trying to modify some pads set in *radio* mode in order for each pad to have a different name and color. When clicking the option for multilabel and multicolor nothing happens. I looked up in the manual, yet it only mentions you can modify them but there is nothing concrete to work with to do so.
Any insight?
Thank you.

gabbo
Macciza
Regular
Posts: 1315
Joined: 07 Dec 2011 04:57
Location: Sydney, Australia.

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by Macciza »

Hi
Something like this

Code: Select all

decl this, red, green, blue, grey, def_col,def_lab;

this = getobject();

red = RGB(1,0,0);
green = RGB(0,1,0);
blue = RGB(0,0,1);
grey = RGB(.5,.5,.5);

def_col = {red,green,blue,grey};
def_lab = {'one','two','three','four','one','two','three','four'};

setattribute(this,'labels',def_lab);
setattribute(this,'colors',def_col);
iMac 2.8G i7 12G 10.6.8/10.7.2, Legacy Dexter/Lemur, Liine Lemur/iPad2, KMI SoftStep, 12Step & QuNeo , B-Controls, Mackie C4 etc
MaxMSP, Live Suite, Native Instrument stuff, etc Modified Virtual Guitar System etc All Projects/Modules © CC-BY-NC-SA[*][/b]
esegabbo
Newbie
Posts: 15
Joined: 13 Dec 2011 22:48

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by esegabbo »

Hi, thanks for the response. Yet, that code you pasted ... I do not know what to do with it. Could you explain as if I was a 5 year old =) How would I go about labeling pads.
Thanks,

g.
findbuddha
Newbie
Posts: 9
Joined: 15 Feb 2012 04:10

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by findbuddha »

Step 1. RTFM
Step 2. Create a script under your pad object with execution set to 'on load'
Step 3. Modify Macciza's example as needed.
whatisvalis
Regular
Posts: 153
Joined: 31 Dec 2011 17:12

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by whatisvalis »

I've found the best way to figure stuff out is by looking at other templates. There are loads of templates that use multi labeled pads, just navigate to the object and copy/paste the script into your own template, making the necessary changes.
phlange
Newbie
Posts: 2
Joined: 09 Jun 2013 23:32

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by phlange »

If you were a 5 yr old, I would tell you youre wasting time coding scripts for a controller.
As colorful as Lemur is (and oooo, mau5 uses it), with TouchOSC you just put labels onto the pads and then MAKE MUSIC WITH IT a minute later.
phlange
Newbie
Posts: 2
Joined: 09 Jun 2013 23:32

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by phlange »

findbuddha wrote:Step 1. RTFM
Step 2. Create a script under your pad object with execution set to 'on load'
Step 3. Modify Macciza's example as needed.
Good job. Answer the question abbreviations and codes.
Softcore
Regular
Posts: 1613
Joined: 04 Nov 2012 08:34

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by Softcore »

phlange wrote:If you were a 5 yr old, I would tell you youre wasting time coding scripts for a controller.
As colorful as Lemur is (and oooo, mau5 uses it), with TouchOSC you just put labels onto the pads and then MAKE MUSIC WITH IT a minute later.
lol.....You obviously havent yet understood the power of Lemur scripting. Download one of Antonio Blanca's Lemur templates and let me know how many decades it will take you to reach that level of interactivity with TouchOSC.
electrofux
Regular
Posts: 294
Joined: 24 Jan 2012 18:22

Re: MULTILABEL: HOW DO I LABEL PADS?

Post by electrofux »

You need to understand how Lemur works with arrays. I am having a hard time with that too now and then. But once you understand it stuff gets easier.

A Pad of say 1 row and 4 collumns -lets call it Pad1- is essentially an array of single pads and so are its labels in Multilabel Mode.

When you setattribute (Pad1,'labels',XXXX) the XXXX stands for an array of labels.

So setattribute (Pad1,'labels',{'Filter','Oscillator','Effects','Routing'}) will lead to the 4 pads being labelled Filter, Oscillator, Effects, Routing.

you can also do

decl mylabels;
mylabels={'Filter','Oscillator','Effects','Routing'};
setattribute (Pad,'labels',mylabels)

Don't forget to set the script to something that makes the function to be carried out like "on load".
Post Reply