20#include <Inventor/SbBasic.h>
24#define SOSHADER_CORE_GLSL_VERSION 140
52 void errClear(
const char *
string =
nullptr)
const;
54 void errCheck(
const char *
string =
nullptr)
const;
56 inline SbBool
error(
const char *
string =
nullptr)
const {
57 errCheck(
string);
return _openGLError != GL_NO_ERROR;
62 static int _isSupported;
64 mutable GLenum _openGLError;
#define INVENTOR_SHADER_API
Define class export specifier.
Abstract base class for shader objects.
virtual ~SoGLShader()
Destructor.
void errCheck(const char *string=nullptr) const
Check for OpenGL errors and print error message if one is found.
static bool supportsGeometryShaders()
Returns if the hardware supports geometry shaders.
static void printCapabilities()
Prints capabilities of the OpenGL implementation.
SbBool error(const char *string=nullptr) const
Returns 'TRUE' if OpenGL error is found.
virtual void reset()
Free all resources (OpenGL too) and reset instance to initial state.
void errClear(const char *string=nullptr) const
Clear OpenGL error state and print any previously not displayed error message.
static SbBool isSupported()
Returns 'TRUE' if vertex and fragment shaders are supported by OpenGL.