Plugin: JS9Color

### Color Controls

The Color Controls plugin provides a number of ways to set colors on an image:

- use the Top cmaps and Other cmaps menus to change the colormap
- use the Create cmaps button to toggle the Create Colormaps plugin, allowing you to create new colormaps
- use the Image filters button to toggle the Image Filters plugin and apply image processing techniques to the displayed image
- use the Contrast/bias text boxes to change the contrast and bias
- use the Opacity options to set the opacity in various ways

Opacity can be set in various ways, depending on the option chosen in the mode menu:

When default is selected, the opacity of each pixel is set to the default value in the first text box (which should be between 0 and 1). The default value is also used in the pixels option.

When floor ≤ is selected, the opacity in the first text box is applied to image pixels whose value is less than or equal to the specified floor value in the last text box. For image values greater than this floor value, the default opacity is applied.

When opacity is selected, a menu of opacity image files is displayed. These opacity images must have the same dimensions as the displayed image. A pixel value in the opacity image specifies the opacity of the corresponding image pixel (and therefore should take on values between 0 and 1).

For mask mode, if the value of a pixel in the image is less than or equal to zero, the opacity of the displayed pixel is set to the opacity value in the text box. Otherwise, the opacity is set to the global opacity. Thus, for example, if the opacity in the first text box is set to 0, this mode will display only the image pixels with corresponding non-zero mask values, i.e., image pixels "covered" by a mask.

When overlay is selected, a menu of overlay files is displayed. These "overlay mask" images must have the same dimensions as the displayed image. If a mask pixel has a non-zero alpha value (in its own display frame), its color is blended with the image pixel using source-atop composition. Otherwise, the image pixel color alone is used in the display. This is one way you can display a mask overlay on top of an image. A static colormap is usually used in conjunction with an overlay mask, since pixel values not explicitly assigned a color are transparent. Note that, when blending a mask and image pixel, the global opacity and the individual pixel opacity of the mask are multiplied to get each final pixel opacity.