Color types and utilities. More...
#include "ai_comparison.h"#include "ai_math.h"#include "ai_string.h"#include "ai_constants.h"#include "ai_api.h"Go to the source code of this file.
Data Structures | |
| struct | AtRGB |
| RGB color. More... | |
| struct | AtRGBA |
| RGB color + alpha. More... | |
Functions | |
| AI_DEVICE constexpr AtRGB | operator* (float f, const AtRGB &rgb) |
| AI_DEVICE constexpr AtRGB | operator+ (float f, const AtRGB &rgb) |
| AI_DEVICE constexpr AtRGB | operator- (float f, const AtRGB &rgb) |
| AI_DEVICE constexpr AtRGB | operator/ (float f, const AtRGB &rgb) |
| AI_DEVICE AtBooleanMask< 3 > | operator< (const AtRGB &lhs, const AtRGB &rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator<= (const AtRGB &lhs, const AtRGB &rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator> (const AtRGB &lhs, const AtRGB &rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator>= (const AtRGB &lhs, const AtRGB &rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator< (const AtRGB &lhs, float rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator<= (const AtRGB &lhs, float rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator> (const AtRGB &lhs, float rhs) |
| AI_DEVICE AtBooleanMask< 3 > | operator>= (const AtRGB &lhs, float rhs) |
| AI_DEVICE constexpr AtRGBA | operator* (float f, const AtRGBA &rgba) |
| AI_DEVICE constexpr AtRGBA | operator+ (float f, const AtRGBA &rgba) |
| AI_DEVICE constexpr AtRGBA | operator- (float f, const AtRGBA &rgba) |
| AtBooleanMask< 4 > | operator< (const AtRGBA &lhs, const AtRGBA &rhs) |
| AtBooleanMask< 4 > | operator<= (const AtRGBA &lhs, const AtRGBA &rhs) |
| AtBooleanMask< 4 > | operator> (const AtRGBA &lhs, const AtRGBA &rhs) |
| AtBooleanMask< 4 > | operator>= (const AtRGBA &lhs, const AtRGBA &rhs) |
| AtBooleanMask< 4 > | operator< (const AtRGBA &lhs, float rhs) |
| AtBooleanMask< 4 > | operator<= (const AtRGBA &lhs, float rhs) |
| AtBooleanMask< 4 > | operator> (const AtRGBA &lhs, float rhs) |
| AtBooleanMask< 4 > | operator>= (const AtRGBA &lhs, float rhs) |
Other Color Operations | |
| AI_DEVICE constexpr AtRGB | AiRGBClamp (const AtRGB &c, float lo, float hi) |
| Clamp the RGB color vector to the specified range. | |
| AI_DEVICE constexpr AtRGBA | AiRGBAClamp (const AtRGBA &c, float lo, float hi) |
| Clamp the RGBA color vector to the specified range. | |
| AI_DEVICE void | AiColorClipToZero (AtRGB &c) |
| Clip negative values. | |
| AI_DEVICE bool | AiColorIsSmall (const AtRGB &c, float epsilon=AI_EPSILON) |
| Check for almost black. | |
| AI_DEVICE AtRGB | AiColorABS (const AtRGB &c) |
| Absolute value of color. | |
| AI_DEVICE AtRGBA | AiColorABS (const AtRGBA &c) |
| Absolute value of color, RGBA version. | |
| AI_DEVICE constexpr float | AiColorMaxRGB (const AtRGB &c) |
| Max RGB component of color. | |
| AI_DEVICE constexpr float | AiColorMaxRGB (const AtRGBA &c) |
| Max RGB component of color, RGBA version (ignores alpha) | |
| bool | AiColorThreshold (const AtRGB &c1, const AtRGB &c2, float t) |
| Check to see if two colors differ by more than a threhsold. | |
| AI_DEVICE constexpr float | AiColorToGrey (const AtRGB &c) |
| Convert a RGB color to grey scale (take average of R, G, B) | |
| AI_DEVICE constexpr float | AiColorToGrey (const AtRGBA &rgba) |
| Convert a RGBA color to grey scale (take average of R, G, B - ignore alpha) | |
| AI_API AI_PURE bool | AiRGBIsFinite (const AtRGB &rgba) |
| Check to see if an RGB color has any corrupted components (nan or infinite). More... | |
| AI_API AI_PURE bool | AiRGBAIsFinite (const AtRGBA &rgba) |
| Check to see if an RGBA color has any corrupted components (nan or infinite). | |
| AtRGB | AiBerpRGB (float a, float b, const AtRGB &c0, const AtRGB &c1, const AtRGB &c2) |
| Barycentric interpolation of triangle vertex colors. | |
| AI_API AI_DEVICE AI_PURE AtRGB | AiColorHeatMap (const AtRGB *map_colors, const float *map_values, unsigned int map_length, float lookup) |
| Interpolate a value according to a heat map (piecewise linear color map). More... | |
Constants | |
Color types and utilities.