Customizing the palette and color picker interface, Using the pixel analyzer – Apple Shake 4 User Manual
Page 627
Chapter 23
Color Correction
627
Customizing the Palette and Color Picker Interface
These commands are placed in your ui.h file. For more information on customizing
Shake, see Chapter 14, “
Using the Pixel Analyzer
The Pixel Analyzer tab is an analysis tool to find and compare different color values in
an image. You can examine minimum, average, current, or maximum pixel values on a
selection (that you make), or across an entire image.
Code
Description
nuiSetColor(1,1,0,0);
nuiSetColor(2,1,0.5,0);
nuiSetColor(3,1,1,0);
Assigns a color to a Palette
swatch; the first number is the
assigned box. Values are in a
range of 0 to 1.
nuiPushControlGroup(“Color”);
nuiGroupControl(“MyFunction.red”);
nuiGroupControl(“MyFunction.green”);
nuiGroupControl(“MyFunction.blue”);
nuiPopControlGroup();
nuiPushControlWidget(
“Color”,
nuiConnectColorTriplet(
kRGBToggle,
kCurrentColor,
1
)
);
);
Assigns a Color Picker to your
custom macros. This code
creates a subtree named “Color”
that contains the three
parameters–red, green, and
blue—although these can be
any three parameters. The last
function
(nuiConnectColorPControl)
selects what color space the
values are returned in, what type
of value, and if you want to use
the source buffer or not.