template<typename T, Int STRIDE = 1>
struct maxon::Col4< T, STRIDE >
A color consisting of three components R, G, B and an alpha.
|
constexpr | Col4 () |
|
constexpr | Col4 (ValueTypeParam in) |
|
constexpr | Col4 (ValueTypeParam ix, ValueTypeParam iy, ValueTypeParam iz, ValueTypeParam iw) |
|
template<typename T2 , Int S2> |
constexpr | Col4 (const Col4< T2, S2 > &v) |
|
template<typename T2 , Int S2> |
constexpr | Col4 (const Vec4< T2, S2 > &v) |
|
template<Int S2> |
constexpr | Col4 (const Col4< T, S2 > &v) |
|
template<typename T2 , Int S2> |
constexpr | Col4 (const Col3< T2, S2 > &v, T iw=T(1)) |
|
constexpr | Col4 (ENUM_DONT_INITIALIZE v) |
|
constexpr const Vec4< T, STRIDE > & | GetVector () const |
|
constexpr Vec4< T, STRIDE > & | GetVector () |
|
constexpr const Col3< T, STRIDE > & | GetColor3 () const |
|
constexpr MAXON_IMPLICIT | Col4 (const typename std::conditional< STRIDE==1, DummyParamType, Col4 >::type &src) |
|
constexpr Col4 & | operator= (const typename std::conditional< STRIDE==1, DummyParamType, Col4 >::type &src) |
|
T & | operator[] (Int l) |
|
ValueTypeParam | operator[] (Int l) const |
|
template<typename T2 , Int S2> |
constexpr Col4 & | operator+= (const Col4< T2, S2 > &v) |
|
constexpr Col4 & | operator+= (const Col4 &v) |
|
template<typename T2 , Int S2> |
constexpr Col4 & | operator-= (const Col4< T2, S2 > &v) |
|
constexpr Col4 & | operator-= (const Col4 &v) |
|
template<typename T2 , Int S2> |
constexpr Col4 & | operator*= (const Col4< T2, S2 > &v) |
|
constexpr Col4 & | operator*= (const Col4 &v) |
|
constexpr Col4 & | operator*= (ValueTypeParam s) |
|
constexpr Col4 & | operator/= (ValueTypeParam s) |
|
constexpr Unstrided | operator* (ValueTypeParam s) const |
|
template<typename S > |
constexpr Col4< typename MultiplicativePromotion< T, S, STD_IS_REPLACEMENT(scalar, S)>::type, 1 > | operator* (S s) const |
|
constexpr Unstrided | operator/ (ValueTypeParam s) const |
|
constexpr Unstrided | operator* (const Col4 &v) const |
|
constexpr Unstrided | operator+ (const Col4 &v) const |
|
constexpr Unstrided | operator- (const Col4 &v) const |
|
constexpr Unstrided | operator- () const |
|
template<typename T2 , Int S2> |
constexpr BoolType | operator== (const Col4< T2, S2 > &v) const |
|
constexpr BoolType | operator== (const Col4 &v) const |
|
template<typename T2 , Int S2> |
constexpr BoolType | operator!= (const Col4< T2, S2 > &v) const |
|
constexpr BoolType | operator!= (const Col4 &v) const |
|
constexpr BoolType | LessThanOrEqual (const Col4 &v) const |
|
constexpr HashInt | GetHashCode () const |
|
constexpr BoolType | IsEqual (const Col4 &other, ValueTypeParam epsilon) const |
|
constexpr BoolType | IsZero () const |
|
constexpr void | SetZero () |
|
constexpr T | GetAverage () const |
|
constexpr T | GetSum () const |
|
constexpr void | ClampMin (const Col4 &other=Col4()) |
|
constexpr void | ClampMax (const Col4 &other) |
|
constexpr Unstrided | Clamp01 () const |
|
String | ToString (const FormatStatement *formatStatement=nullptr) const |
|
constexpr T | GetMin () const |
|
constexpr T | GetMax () const |
|
constexpr Col4 | GetRightRotated (Int rots) const |
|
template<typename V > |
constexpr Col4 & | operator*= (const SqrMat4< V > &m) |
|
|
constexpr friend Unstrided | operator* (ValueTypeParam s, const Col4 &v) |
|
constexpr friend T | Dot (const Col4 &v1, const Col4 &v2) |
|
constexpr friend Unstrided | Abs (const Col4 &v1) |
|
template<typename T2 , Int S2> |
constexpr friend MultiplicativePromotion< T, T2 >::type | Dot (const Col4 &v1, const Col4< T2, S2 > &v2) |
|
constexpr friend Unstrided | Min (const Col4 &th, const Col4 &other) |
|
constexpr friend Unstrided | Max (const Col4 &th, const Col4 &other) |
|
constexpr friend void | SetMin (Col4 &th, const Col4 &other) |
|
constexpr friend void | SetMax (Col4 &th, const Col4 &other) |
|
constexpr Col4 GetRightRotated |
( |
Int |
rots | ) |
const |
|
constexpr |
Returns a vector where the components have been rotated to the right (in the usual (r, g, b, a)-representation). E.g., with a value of 1 for rots, the result will be (a, r, g, b).
- Parameters
-
[in] | rots | Number of rotations, may be negative. The result depends only on the number modulo 4. |
- Returns
- Vector with rotated components.