Colourtable()

Manipulate graphics colour tables (used with Cell() commands).

COLOURTABLE:CREATE() red=RealArray green=RealArray blue=RealArray ncolours=Integer contrast=Real brightness=Real Creates and returns a new colour table.
[/NOSHARE]   Avoid sharing colours
COLOURTABLE/DELETE table=ColourTable Deletes and frees up colours from an existing colourtable.

example:

	# Create, use in a cell plot and then
	# delete a colourtable.
	>> ct1 = Colourtable:create(ra,ga,ba,80,1.0,1.0)
	>> Cell/alter object=obj(1,2,3) table=ct1
	>> Colourtable/delete ct1

Note: The data in the real arrays will be interpolated if ncolours
exceeds the number of elements in the arrays.

Colourtable:Create()

This command creates a colourtable given three arrays of colour values, one each for red, green and blue. The created colourtable will normally be used to provide a colour scale for a cell array style plot and will provide "ncolours" different colours for the plot using it, note that the colour arrays need not have ncolours elements, the colourtable command will interpolate to provide intermediate colours if necessary.

Where possible the Colourtable() command will allocate colours which are already being used to save on a potentially limited number of colour indices. As colour slots can be relatively short on some devices, it is usually a good idea to deallocate colourtables immediately after they have been used.

Parameters:

/Noshare

If this qualifiers is specified, the colourtable command avoids sharing similar colours between colourtables. The most likely use of this is if one plot is assigning colour tables with the intention of colour cycling (it would not be desireable to colour cycle any shared colours!). Note that colour slot usage will be much higher with this qualifier.

Red (RealArray)

This array specifies how much red goes into the new colour, values must be between 0.0 and 1.0.

Green (RealArray)

This array specifies how much green goes into the new colour, values must be between 0.0 and 1.0.

Blue (RealArray)

This array specifies how much blue goes into the new colour, values must be between 0.0 and 1.0.

Ncolours (Real)

Number of elements in the colour arrays.

Contrast (Real)

Allows an adjustment of the contrast by scaling each colour value by a power (default 1.0).

Brightness (Real)

Allows an adjustment of the brightness by scaling each colour by a number (default 1.0).

RESULT = (ColourTable)

Returns the newly created colour table.

Colourtable/Delete

Deallocates a previously allocated colourTable, this allows new colourTables to be allocated with the correct number of colours. (only allows 84 colours in total)

Parameters:

Table (ColourTable)

This array decides how much red goes into the new colour.