Simulant  21.12-574
A portable game engine for Windows, OSX, Linux, Dreamcast, and PSP
Classes | Public Member Functions | Friends | List of all members
smlt::GPUProgram Class Reference
Inheritance diagram for smlt::GPUProgram:
smlt::RefCounted< GPUProgram > smlt::generic::Identifiable< GPUProgramID > smlt::TwoPhaseConstructed


struct  ShaderInfo

Public Member Functions

 GPUProgram (const GPUProgramID &id, Renderer *renderer, const std::string &vertex_source, const std::string &fragment_source)
 GPUProgram (const GPUProgram &)=delete
GPUProgramoperator= (const GPUProgram &)=delete
bool init () override
void clean_up () override
bool is_current () const
void activate ()
bool is_complete () const
bool is_compiled (ShaderType type) const
void compile (ShaderType type)
void build ()
ProgramLinkedSignalsignal_linked ()
ShaderCompiledSignalsignal_shader_compiled ()
std::string md5 ()
const std::unordered_map< ShaderType, ShaderInfoshader_infos () const
GLint locate_uniform (const std::string &name, bool fail_silently=false)
GLint locate_attribute (const std::string &name, bool fail_silently=false)
void set_uniform_location (const std::string &name, GLint location)
void set_attribute_location (const std::string &name, GLint location)
UniformInfo uniform_info (const std::string &uniform_name)
void clear_cache ()
void set_uniform_int (const int32_t loc, const int32_t value)
void set_uniform_mat4x4 (const int32_t loc, const Mat4 &values)
void set_uniform_colour (const int32_t loc, const Colour &values)
void set_uniform_vec4 (const int32_t loc, const Vec4 &values)
void set_uniform_float (const int32_t loc, const float value)
void set_uniform_int (const std::string &uniform_name, const int32_t value, bool fail_silently=false)
void set_uniform_float (const std::string &uniform_name, const float value, bool fail_silently=false)
void set_uniform_mat4x4 (const std::string &uniform_name, const Mat4 &values)
void set_uniform_mat3x3 (const std::string &uniform_name, const Mat3 &values)
void set_uniform_vec3 (const std::string &uniform_name, const Vec3 &values)
void set_uniform_vec4 (const std::string &uniform_name, const Vec4 &values)
void set_uniform_colour (const std::string &uniform_name, const Colour &values)
void set_uniform_mat4x4_array (const std::string &uniform_name, const std::vector< Mat4 > &matrices)
void relink ()
GLuint program_object () const
void prepare_program ()
void _set_renderer_specific_id (uint32_t id)
uint32_t _renderer_specific_id () const
- Public Member Functions inherited from smlt::generic::Identifiable< GPUProgramID >
 Identifiable (GPUProgramID id)
GPUProgramID id () const
virtual bool operator== (const Identifiable< GPUProgramID > &rhs) const
virtual bool operator< (const Identifiable< GPUProgramID > &rhs) const
void _bind_id_pointer (ResourceTypePtr ptr)
void _overwrite_id (GPUProgramID new_id)


class Renderer
class ::ShaderTest

Additional Inherited Members

- Public Types inherited from smlt::RefCounted< GPUProgram >
typedef std::shared_ptr< GPUProgramptr
typedef std::weak_ptr< GPUProgramwptr
- Public Types inherited from smlt::generic::Identifiable< GPUProgramID >
typedef GPUProgramID id_type
- Static Public Member Functions inherited from smlt::RefCounted< GPUProgram >
static RefCounted< GPUProgram >::ptr create (Args &&... args)
static RefCounted< GPUProgram >::ptr create ()
- Protected Member Functions inherited from smlt::RefCounted< GPUProgram >
 RefCounted (Args &&...)

The documentation for this class was generated from the following files: