16struct gl_traits {
static const unsigned type = GL_FALSE;
static const bool valid_index =
false; };
18struct gl_traits<unsigned char> {
static const unsigned type = GL_UNSIGNED_BYTE;
static const bool valid_index =
true; };
20struct gl_traits<char> {
static const unsigned type = GL_BYTE;
static const bool valid_index =
false; };
22struct gl_traits<unsigned short> {
static const unsigned type = GL_UNSIGNED_SHORT;
static const bool valid_index =
true; };
24struct gl_traits<short> {
static const unsigned type = GL_SHORT;
static const bool valid_index =
false; };
26struct gl_traits<unsigned int> {
static const unsigned type = GL_UNSIGNED_INT;
static const bool valid_index =
true; };
28struct gl_traits<int> {
static const unsigned type = GL_INT;
static const bool valid_index =
false; };
30struct gl_traits<float> {
static const unsigned type = GL_FLOAT;
static const bool valid_index =
false; };
32struct gl_traits<double> {
static const unsigned type = GL_DOUBLE;
static const bool valid_index =
false; };
37extern CGV_API
bool is_glew_initialized();
43#include <cgv/config/lib_end.h>
bool ensure_glew_initialized()
initialize glew in the first call to this function and always return whether this was successful
traits structure that maps a fundamental type to the Type enum.