SilverScreen Solid Modeler

FromColorIndex method

FromColorIndex method

Previous topic Next topic  

FromColorIndex method

Previous topic Next topic JavaScript is required for the print function  

SilverSharpAPI

Antiquated

 

static SS_RGB FromColorIndex(int color_index);

 

int color_index;   // An integer value

 

 

 




Synopsis

using SilverSharp;

 

The FromColorIndex method creates a SilverSharp.SS_RGB object from a color index value.

 

 

Parameters

color_index is an index into the standard SilverScreen palette

 

 

Return Value

FromColorIndex returns a SilverSharp.SS_RGB object

 

Remarks

Palette indexes are sometimes used as parameters to legacy API routines.

 

 

See Also

SS_RGB, ToColorIndex

 

 

Example

The following code shows how to create a SilverSharp.SS_RGB object from a standard color index:

 

C# Code

 

 using SilverSharp;

 

 . . .

 

 SS_RGB rgb = SS_RGB.FromColorIndex(SILVER_COLORS.color_green);

 

 SC.ss_command("paint background color {0}", rgb);