Uniform.h
Go to the documentation of this file.
#pragma once
#include <glbinding/gl/types.h>
#include <globjects/globjects_api.h>
#include <globjects/AbstractUniform.h>
namespace globjects
{
template<typename T>
class Uniform : public AbstractUniform
{
public:
Uniform(gl::GLint location);
Uniform(gl::GLint location, const T & value);
Uniform(const std::string & name);
Uniform(const std::string & name, const T & value);
void set(const T & value);
const T & value() const;
protected:
virtual ~Uniform();
virtual void updateAt(const Program * program, gl::GLint location) const override;
protected:
T m_value;
};
} // namespace globjects
#include <globjects/Uniform.inl>
globjects::Uniform::updateAt
virtual void updateAt(const Program *program, gl::GLint location) const override
globjects::Uniform::value
const T & value() const
globjects::Uniform::~Uniform
virtual ~Uniform()
globjects
Contains all the classes that wrap OpenGL functionality.
globjects::Uniform::Uniform
Uniform(gl::GLint location)
globjects::Uniform::set
void set(const T &value)
globjects::Uniform::m_value
T m_value
The uniforms value, explictly required when relinking programs.
Definition: Uniform.h:54
AbstractUniform.h