Go to the documentation of this file.00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 
00022 
00023 
00024 
00025 
00026 
00027 
00028 
00029 #ifndef glm_core_type_gentype
00030 #define glm_core_type_gentype
00031 
00032 #include "type_size.hpp"
00033 
00034 namespace glm
00035 {
00036         enum profile
00037         {
00038                 nice,
00039                 fast,
00040                 simd
00041         };
00042 
00043 namespace detail
00044 {
00045         template
00046         <
00047                 typename VALTYPE, 
00048                 template <typename> class TYPE
00049         >
00050         struct genType
00051         {
00052         public:
00053                 enum ctor{null};
00054 
00055                 typedef VALTYPE value_type;
00056                 typedef VALTYPE & value_reference;
00057                 typedef VALTYPE * value_pointer;
00058                 typedef VALTYPE const * value_const_pointer;
00059                 typedef TYPE<bool> bool_type;
00060 
00061                 typedef sizeType size_type;
00062                 static bool is_vector();
00063                 static bool is_matrix();
00064                 
00065                 typedef TYPE<VALTYPE> type;
00066                 typedef TYPE<VALTYPE> * pointer;
00067                 typedef TYPE<VALTYPE> const * const_pointer;
00068                 typedef TYPE<VALTYPE> const * const const_pointer_const;
00069                 typedef TYPE<VALTYPE> * const pointer_const;
00070                 typedef TYPE<VALTYPE> & reference;
00071                 typedef TYPE<VALTYPE> const & const_reference;
00072                 typedef TYPE<VALTYPE> const & param_type;
00073 
00075                 
00076 
00077                 value_const_pointer value_address() const{return value_pointer(this);}
00078                 value_pointer value_address(){return value_pointer(this);}
00079 
00080         
00081         
00082         
00083         
00084         
00085         
00086         
00087 
00088         
00089         };
00090 
00091         template
00092         <
00093                 typename VALTYPE, 
00094                 template <typename> class TYPE
00095         >
00096         bool genType<VALTYPE, TYPE>::is_vector()
00097         {
00098                 return true;
00099         }
00100 
00101 
00102 
00103 
00104 
00106 
00107 
00108 
00109 
00110 
00111 
00112 
00113 
00114 
00115 
00116 
00117 
00118 
00119 
00120 
00121 
00122 
00123 
00124 
00125 
00126 
00127 
00128 
00129 
00131 
00132 
00133 
00134 
00135 
00136 
00137 
00138 
00140 
00141 
00142 
00143 
00145 
00146 
00147 
00148 
00150 
00151 
00152 
00153 
00154 
00155 
00156 
00157 
00158 
00159 
00160 
00161 
00162 
00163 
00164         }
00165 }
00166 
00167 
00168 
00169 #endif//glm_core_type_gentype