8#include <glbinding/gl/types.h>
10#include <globjects/globjects_api.h>
23class AbstractStringSource;
50 ShadingLanguageIncludeARB
60 static void globalReplace(
const std::string & search,
const std::string & replacement);
84 gl::GLint
get(gl::GLenum pname)
const;
Superclass for all types of static and dynamic strings, e.g. for the use as Shader code.
Definition: AbstractStringSource.h:26
Allows listening to any Changeable.
Definition: ChangeListener.h:23
Superclass of all objects that want others to signal that they have changed.
Definition: Changeable.h:23
Superclass of all wrapped OpenGL objects.
Definition: Object.h:27
Implements a Visitor Pattern to iterate over all tracked globjects objects.
Definition: ObjectVisitor.h:30
Wraps an OpenGL program.
Definition: Program.h:79
Encapsulates OpenGL shaders.
Definition: Shader.h:41
bool m_compiled
Definition: Shader.h:108
static std::string typeString(gl::GLenum type)
const AbstractStringSource * source() const
std::string getSource() const
static void clearGlobalReplacements()
void setSource(AbstractStringSource *source)
std::string typeString() const
bool checkCompileStatus() const
virtual gl::GLenum objectType() const override
IncludePaths m_includePaths
Definition: Shader.h:106
bool m_compilationFailed
Definition: Shader.h:109
static std::map< std::string, std::string > s_globalReplacements
Definition: Shader.h:111
virtual void accept(ObjectVisitor &visitor) override
void setSource(const std::string &source)
static void globalReplace(const std::string &search, int i)
ref_ptr< AbstractStringSource > m_source
Definition: Shader.h:105
static void globalReplace(const std::string &search, const std::string &replacement)
Shader(const gl::GLenum type)
const IncludePaths & includePaths() const
virtual void notifyChanged(const Changeable *changeable) override
std::string infoLog() const
static void hintIncludeImplementation(IncludeImplementation impl)
gl::GLint get(gl::GLenum pname) const
gl::GLenum m_type
Definition: Shader.h:104
std::vector< std::string > IncludePaths
Definition: Shader.h:45
static Shader * fromFile(const gl::GLenum type, const std::string &filename, const IncludePaths &includePaths=IncludePaths())
std::string shaderString() const
Shader(const gl::GLenum type, AbstractStringSource *source, const IncludePaths &includePaths=IncludePaths())
void setIncludePaths(const IncludePaths &includePaths)
IncludeImplementation
Definition: Shader.h:49
static Shader * fromString(const gl::GLenum type, const std::string &sourceString, const IncludePaths &includePaths=IncludePaths())
The ref_ptr class provides the interface for a reference pointer.
Definition: ref_ptr.h:33
Contains all the classes that wrap OpenGL functionality.