#include <Color.h>
Definition at line 8 of file Color.h.
◆ Rgba() [1/5]
◆ Rgba() [2/5]
Rgba::Rgba |
( |
const float |
r, |
|
|
const float |
g, |
|
|
const float |
b, |
|
|
const float |
a = 1.f |
|
) |
| |
|
inline |
◆ Rgba() [3/5]
Rgba::Rgba |
( |
const float |
gray, |
|
|
const float |
a = 1.f |
|
) |
| |
|
inlineexplicit |
◆ Rgba() [4/5]
Rgba::Rgba |
( |
const Rgba & |
other | ) |
|
|
inline |
◆ Rgba() [5/5]
Rgba::Rgba |
( |
const wxColour & |
other | ) |
|
|
inlineexplicit |
◆ a() [1/2]
◆ a() [2/2]
◆ b() [1/2]
◆ b() [2/2]
◆ black()
static Rgba Rgba::black |
( |
| ) |
|
|
inlinestatic |
◆ blend()
Rgba Rgba::blend |
( |
const Rgba & |
other, |
|
|
const float |
amount |
|
) |
| const |
|
inline |
Computes a linear interpolation of two color.
For amount 0, function returns this color, for amount 1 it returns the other color.
Definition at line 158 of file Color.h.
◆ blue()
static Rgba Rgba::blue |
( |
| ) |
|
|
inlinestatic |
◆ brighten()
Rgba Rgba::brighten |
( |
const float |
amount | ) |
const |
|
inline |
Returns a color brighter by given factor.
- Parameters
-
amount | Value in interval [0, INFTY], where 0 = current color, 1 = 100% more brighter, etc. |
Definition at line 145 of file Color.h.
◆ darken()
Rgba Rgba::darken |
( |
const float |
amount | ) |
const |
|
inline |
Returns a color darker by given factor.
- Parameters
-
amount | Value in interval [0, 1], where 0 = current color, 1 = black. |
Definition at line 137 of file Color.h.
◆ g() [1/2]
◆ g() [2/2]
◆ gray()
static Rgba Rgba::gray |
( |
const float |
value = 0.5f | ) |
|
|
inlinestatic |
◆ green()
static Rgba Rgba::green |
( |
| ) |
|
|
inlinestatic |
◆ intensity()
float Rgba::intensity |
( |
| ) |
const |
|
inline |
Returns the average intensity of the color.
Definition at line 115 of file Color.h.
◆ inverse()
Rgba Rgba::inverse |
( |
| ) |
const |
|
inline |
Returns an inverse color.
Definition at line 151 of file Color.h.
◆ operator wxColour()
Rgba::operator wxColour |
( |
| ) |
const |
|
inlineexplicit |
◆ operator!=()
bool Rgba::operator!= |
( |
const Rgba & |
other | ) |
const |
|
inline |
◆ operator*() [1/2]
Rgba Rgba::operator* |
( |
const float |
value | ) |
const |
|
inline |
Multiplies the intensity of the color by given factor.
The alpha value is not affected by this operation.
Definition at line 74 of file Color.h.
◆ operator*() [2/2]
Rgba Rgba::operator* |
( |
const Rgba & |
other | ) |
const |
|
inline |
Multiplies the color by other color, component-wise.
- Warning
- The resulting color has the alpha value of the left-hand side color, i.e. this operation is not commutative!
Definition at line 89 of file Color.h.
◆ operator+()
Rgba Rgba::operator+ |
( |
const Rgba & |
other | ) |
const |
|
inline |
Returns the sum of two colors, component-wise.
- Warning
- The resulting color has the alpha value of the left-hand side color, i.e. this operation is not commutative!
Definition at line 97 of file Color.h.
◆ operator+=()
Rgba& Rgba::operator+= |
( |
const Rgba & |
other | ) |
|
|
inline |
◆ operator/()
Rgba Rgba::operator/ |
( |
const float |
value | ) |
const |
|
inline |
Divides the intensity of the color by given factor.
The alpha value is not affected by this operation.
Definition at line 81 of file Color.h.
◆ operator=()
Rgba& Rgba::operator= |
( |
const Rgba & |
other | ) |
|
|
inline |
◆ operator==()
bool Rgba::operator== |
( |
const Rgba & |
other | ) |
const |
|
inline |
◆ over()
Rgba Rgba::over |
( |
const Rgba & |
other | ) |
const |
|
inline |
Blends two colors together using "over" operation.
Definition at line 120 of file Color.h.
◆ r() [1/2]
◆ r() [2/2]
◆ red()
static Rgba Rgba::red |
( |
| ) |
|
|
inlinestatic |
◆ saturate()
Rgba Rgba::saturate |
( |
const float |
value | ) |
const |
|
inline |
Retuns a color with modified saturation.
- Parameters
-
value | Values greater than 1 increase the saturation, values lower than 1 decrease it. For zero, a gray color is returned. |
Definition at line 166 of file Color.h.
◆ transparent()
static Rgba Rgba::transparent |
( |
| ) |
|
|
inlinestatic |
◆ white()
static Rgba Rgba::white |
( |
| ) |
|
|
inlinestatic |
The documentation for this class was generated from the following file:
- /home/pavel/projects/astro/sph/src/gui/objects/Color.h