00001 #ifndef __VECMATH_COLOR4_HPP 00002 #define __VECMATH_COLOR4_HPP 00003 00004 #ifndef __VECMATH_TUPLE4_HPP 00005 #include <vecmath/_Tuple4.h> 00006 #endif 00007 00008 //#define DEBUGCOLOR4(d) d 00009 #define DEBUGCOLOR4(d) 00010 00011 template <class Type> 00012 class VECMATH_EXPORT _Color4 : public _Tuple4<Type> { 00013 public: 00014 00015 _Color4<Type>() : _Tuple4<Type>() {} 00016 00017 explicit _Color4<Type>(Type x, Type y = 0, Type z = 0, Type w = 0) : _Tuple4<Type>(x, y, z, w) { 00018 DEBUGCOLOR4(cout << "_Color4 explicit constructor x,y,z " << *this << endl); 00019 } 00020 00021 _Color4<Type> (const _Color4<byte>& t) : _Tuple4<Type>(t) { 00022 DEBUGCOLOR4(cout << "_Color4 constructor &byte " << *this << endl); 00023 } 00024 00025 _Color4<Type> (const _Tuple4<double>& t) : _Tuple4<Type>(t) { 00026 DEBUGCOLOR4(cout << "_Color4 constructor &double " << *this << endl); 00027 } 00028 00029 _Color4<Type> (const _Tuple4<float>& t) : _Tuple4<Type>(t) { 00030 DEBUGCOLOR4(cout << "_Color4 constructor &float " << *this << endl); 00031 } 00032 00033 _Color4<Type> (const Type t[4]) : _Tuple4<Type>(t) { 00034 DEBUGCOLOR4(cout << "_Color4 constructor t[4]" << *this << endl); 00035 } 00036 }; 00037 00038 #endif