SilverScreen Solid Modeler

text_to_rgb

text_to_rgb

Previous topic Next topic  

text_to_rgb

Previous topic Next topic JavaScript is required for the print function  

SilverScreenAPI

 

int text_to_rgb ( char *txt, int *r, int *g, int *b )

 

char *txt;        // color string

int  *r;          // address of integer to receive red value

int  *g;          // address of integer to receive green value

int  *b;          // address of integer to receive blue value

 

 




Synopsis

#include "silver.h"

 

The text_to_rgb function converts the string txt into RGB color components.

 

 

Parameters

txt is a null-terminated string containing the color. r , g and b is are all integers that are to receive the red, green and blue components of the color represented in txt .

 

 

Return Value

text_to_rgb stores the RGB values into the integers at r , g and b and returns 1 if the conversion is successful, and 0 if not.

 

 

See Also

text_to_color