Page 1 of 1
Changin colors in multicolor mode
Posted: 04 Jan 2012 02:00
by gumbomasta
I have a 1x8 Switch object that Im using for a custom step sequencer. I want the first and fifth buttons to be a different color denoting that they represent downbeats. Switching my switch array to "multicolor" mode in the properties window leaves me to believe that it is possible to change just these two switches within the array, but I'm not sure the implementation. Any ideas?
Thanks!
Re: Changin colors in multicolor mode
Posted: 04 Jan 2012 02:39
by highmountain
Multicolor is not very user friendly at the moment, so let me give you a really easy option that you can use if you aren't using the light values for anything else. Just setting light to {.5, 0, 0, 0} will highlight the 1st, 5th, 9th, 13th, 17th, etc pads by making them a little brighter than the others.
Okay, here's the multicolor explanation. It's not too hard, it's just a little ugly and opaque if you don't already know what to do. Turn multicolor on, and add a script to your switch object. You can name it whatever you want. Set the script execution to "on load." In the script, put this:
Code: Select all
decl base = (64 * 65536) + (64 * 256) + 64;
decl highlight = (127 * 65536) + (127 * 256) + 127;
setattribute(getobject(), 'colors', {highlight, base, base, base});
The "64"s and "127"s you can change to any number between 0 and 127 to control red, green, and blue levels (in that order from left to right). Don't touch the 65536 or the 256, or your color combinations will become unpredictable.
As with the lights, the pattern you set will repeat itself if it is shorter than the actual number of pads.
Re: Changin colors in multicolor mode
Posted: 04 Jan 2012 08:12
by mbncp
highmountain wrote:As with the lights, the pattern you set will repeat itself if it is shorter than the actual number of pads.
But doesn't work with multi labels, you really have to fill them all.
Btw, you can use RGB(r,g,b) to declare colors:
decl base = RGB(64,64,64);
a bit easier to read, imo.
Re: Changin colors in multicolor mode
Posted: 07 Oct 2013 13:22
by Glennzone
So, if you were to go one step further and submit a "command" via OSC, would you send the script object the vector as "highlight, base, base, base, base" (for a phrase of 5 rather than 4) ?
The situation I'm working with is somewhat different, but i expect this same technique will work for me as well. I will go for the r,g,b sub-array usage to set the colors.
Thanks again for the insights.