Small color object for each particle. More...
#include <b2Particle.h>
Public Member Functions | |
b2ParticleColor (int32 r, int32 g, int32 b, int32 a) | |
b2ParticleColor (const b2Color &color) | |
bool | IsZero () const |
b2Color | GetColor () const |
void | Set (int32 r_, int32 g_, int32 b_, int32 a_) |
void | Set (const b2Color &color) |
Public Attributes | |
uint8 | r |
uint8 | g |
uint8 | b |
uint8 | a |
Small color object for each particle.
|
inline |
Constructor with four elements: r (red), g (green), b (blue), and a (opacity). Each element can be specified 0 to 255.
b2ParticleColor::b2ParticleColor | ( | const b2Color & | color | ) |
Constructor that initializes the above four elements with the value of the b2Color object
|
inline |
True when all four color elements equal 0. When true, no memory is used for particle color.
|
inline |
Sets color for current object using the four elements described above.
void b2ParticleColor::Set | ( | const b2Color & | color | ) |
Initializes the above four elements with the value of the b2Color object