/********************************************************************** * * * cgt - CAMP Graphics Toolbox, Copyright (C) 2012-2015 * * Chair for Computer Aided Medical Procedures * * Technische Universitaet Muenchen, Germany. * * * * * * forked from tgt - Tiny Graphics Toolbox, Copyright (C) 2006-2011 * * Visualization and Computer Graphics Group, Department of * * Computer Science, University of Muenster, Germany. * * * * * * This file is part of the cgt library. This library is free * * software; you can redistribute it and/or modify it under the terms * * of the GNU Lesser General Public License version 2.1 as published * * by the Free Software Foundation. * * * * This library is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU Lesser General Public License for more details. * * * * You should have received a copy of the GNU Lesser General Public * * License in the file "LICENSE.txt" along with this library. * * If not, see . * * * **********************************************************************/ #ifndef CGT_GL_H #define CGT_GL_H #ifdef __APPLE__ #include #include #include #else #include #include #include #endif // __APPLE__ #include "cgt/gpucapabilities.h" #include "cgt/types.h" namespace cgt { CGT_API GLenum _lGLError(int line, const char* file); CGT_API GLboolean getGlBool(GLenum param); CGT_API GLint getGlInt(GLenum param); CGT_API GLfloat getGlFloat(GLenum param); /** * Maps an GLenum returned by glGetError() to a humanly readable string. * Essentially, this is a replacement for gluErrorString() * \param err see https://www.opengl.org/sdk/docs/man/docbook4/xhtml/glGetError.xml */ CGT_API const char* getErrorString(GLenum err); } // namespace cgt #ifdef CGT_DEBUG #define LGL_ERROR cgt::_lGLError(__LINE__, __FILE__) #else #define LGL_ERROR #endif #endif //CGT_GL_H