Add atVec4f constructor to CColor

This commit is contained in:
Jack Andersen 2016-02-07 13:57:59 -10:00
parent a2d7c21a7e
commit cf0bae88ff
1 changed files with 8 additions and 0 deletions

View File

@ -57,6 +57,14 @@ public:
CColor(float r, float g, float b, float a = 1.0f) {v[0] = r; v[1] = g; v[2] = b; v[3] = a; } CColor(float r, float g, float b, float a = 1.0f) {v[0] = r; v[1] = g; v[2] = b; v[3] = a; }
#if ZE_ATHENA_TYPES #if ZE_ATHENA_TYPES
CColor(Athena::io::IStreamReader& reader) {readRGBA(reader);} CColor(Athena::io::IStreamReader& reader) {readRGBA(reader);}
CColor(const atVec4f& vec)
#if __SSE__ || __GEKKO_PS__
: mVec128(vec.mVec128){}
#else
{
r = vec.vec[0], g = vec.vec[1], b = vec.vec[2], a = vec.vec[3];
}
#endif
#endif #endif
CColor(Comp32 rgba) { fromRGBA32(rgba); } CColor(Comp32 rgba) { fromRGBA32(rgba); }