#include <Inventor/SbColor.h>
Inheritance diagram for SbColor::
Public Methods | |
SbColor (void) | |
SbColor (const SbVec3f &v) | |
SbColor (const float *const rgb) | |
SbColor (const float r, const float g, const float b) | |
SbColor & | setHSVValue (float h, float s, float v) |
SbColor & | setHSVValue (const float hsv[3]) |
void | getHSVValue (float &h, float &s, float &v) const |
void | getHSVValue (float hsv[3]) const |
SbColor & | setPackedValue (const uint32_t rgba, float &transparency) |
uint32_t | getPackedValue (const float transparency=0.0f) const |
This class is used within other classes in Coin. It inherits the SbVec3f class, interpreting the 3 component vector as a vector in the RGB cube where the red, green and blue components corresponds to x, y and z respectively.
SbColor also adds a few extra methods for convenient handling of setting and getting color values as 32 bit packed values or as HSV values.
|
Default constructor. The color value will be uninitialized. |
|
Construct and initialize an SbColor with the red, green and blue values given by the |
|
Construct and initialize an SbColor with the red, green and blue taken from given |
|
Construct and initialize an SbColor with the given red, green and blue values. |
|
Set the color as a
|
|
Set the color as a
|
|
Return the color as a
|
|
Return the color as a
|
|
Set the color value as a 32 bit combined red/green/blue/alpha value. Each component is 8 bit wide (i.e. from 0x00 to 0xff), and the red value should be stored leftmost, like this: 0xRRGGBBAA.
The transparency value is not stored internally in SbColor, just converted to a transparency value in [0, 1] and returned in the
|
|
Return color as a 32 bit packed integer in the form 0xRRGGBBAA. The transparency part of the return value is taken from the supplied
|