User Tools

Site Tools


jvs:cigal:showplay:manual:chapter3:indexedcolors

ShowPlay Reference Manual, Chapter 3 (ControlVariables): indexedcolors

Indexedcolors --

Where colors are expected in the stimulus list you can either use explicit RGB values (eg., 0ff0000h for red, 0ffh for blue) or you can use indexed colors by specifying negative values. Indexed colors are replaced by values in an array called SHOWCOLORS. By default, SHOWCOLORS is the following:

showcolors = { front_color back_color text_color }

Negative color values are then replaced by:

   -1    - the default value (i.e., front_color, text_color, or back_color)
   -2    - the first entry in showcolors (front_color usually)
   -3    - the second entry in showcolors (back_color usually)
   -4    - the third entry in showcolors (text_color usually)
   -5    - the fourth entry in showcolors if defined
    ...

If you want more than 3 colors you can define showcolors explicitly in your parameter startup commands, this overrides the 3 default values. For example you could use indexes -2 → -8 if you had:

getcolor 'red' r1
getcolor 'blue' r2
getcolor 'green' r3
getcolor 'orange' r4
showcolors = { 0 0ffffffh r1 r2 r3 r4 07f7f7fh }

Note, -1 values would still use the default values front_color, text_color, or back_color, depending on stimulus type and argument position.

See Also:
CIGAL Home, CIGAL Manual, ShowPlay Home, ShowPlay Manual, InputParameters List, Manual Help

jvs/cigal/showplay/manual/chapter3/indexedcolors.txt · Last modified: 2023/02/23 18:43 (external edit)