 |
globjects
1.0.0.000000000000
Strict OpenGL objects wrapper.
|
Go to the documentation of this file.
8 #include <glbinding/gl/types.h>
10 #include <globjects/globjects_api.h>
23 class AbstractStringSource;
50 ShadingLanguageIncludeARB
54 static void hintIncludeImplementation(IncludeImplementation impl);
57 static Shader * fromString(
const gl::GLenum type,
const std::string & sourceString,
const IncludePaths & includePaths = IncludePaths());
58 static Shader * fromFile(
const gl::GLenum type,
const std::string & filename,
const IncludePaths & includePaths = IncludePaths());
60 static void globalReplace(
const std::string & search,
const std::string & replacement);
61 static void globalReplace(
const std::string & search,
int i);
62 static void clearGlobalReplacements();
65 Shader(
const gl::GLenum type);
70 gl::GLenum type()
const;
73 void setSource(
const std::string & source);
77 const IncludePaths & includePaths()
const;
78 void setIncludePaths(
const IncludePaths & includePaths);
81 bool isCompiled()
const;
84 gl::GLint get(gl::GLenum pname)
const;
85 std::string getSource()
const;
86 bool checkCompileStatus()
const;
87 std::string infoLog()
const;
89 std::string typeString()
const;
91 virtual gl::GLenum objectType()
const override;
93 static std::string typeString(gl::GLenum type);
98 virtual void notifyChanged(
const Changeable * changeable)
override;
101 std::string shaderString()
const;
Encapsulates OpenGL shaders.
Definition: Shader.h:40
The ref_ptr class provides the interface for a reference pointer.
Definition: LogMessageBuilder.h:20
bool m_compilationFailed
Definition: Shader.h:109
Wraps an OpenGL program.
Definition: Program.h:78
static std::map< std::string, std::string > s_globalReplacements
Definition: Shader.h:111
ref_ptr< AbstractStringSource > m_source
Definition: Shader.h:105
Contains all the classes that wrap OpenGL functionality.
Allows listening to any Changeable.
Definition: ChangeListener.h:22
Superclass of all wrapped OpenGL objects.
Definition: Object.h:26
gl::GLenum m_type
Definition: Shader.h:104
bool m_compiled
Definition: Shader.h:108
IncludePaths m_includePaths
Definition: Shader.h:106
Superclass for all types of static and dynamic strings, e.g. for the use as Shader code.
Definition: AbstractStringSource.h:25
IncludeImplementation
Definition: Shader.h:48
Superclass of all objects that want others to signal that they have changed.
Definition: Changeable.h:22
Implements a Visitor Pattern to iterate over all tracked globjects objects.
Definition: ObjectVisitor.h:29
std::vector< std::string > IncludePaths
Definition: Shader.h:45