Catos Engine (Source) 0.0.1
Lightweight Game engine
Loading...
Searching...
No Matches
catos::Shader Class Reference

#include <shader.h>

Public Member Functions

 Shader ()
 
 ~Shader ()
 
void init (const ShaderCreateInfo &createInfo)
 Creates 2 shaders for the Vertex and Fragment Shader.
 
ShaderStatus addSubShader (const char *src, ShaderType type)
 Adds a new subShader to the ShaderProgram.
 
const char * getCompilationErrorMessage ()
 Returns the last compilation error.
 
ShaderProgram getShaderProgram ()
 Returns the raw ShaderProgram object for GL uses.
 
void bind ()
 Binds the shader.
 
void setInt (const char *name, int val)
 Sets a int uniform.
 

Constructor & Destructor Documentation

◆ Shader()

catos::Shader::Shader ( )

◆ ~Shader()

catos::Shader::~Shader ( )

Member Function Documentation

◆ addSubShader()

catos::ShaderStatus catos::Shader::addSubShader ( const char * src,
catos::ShaderType type )

Adds a new subShader to the ShaderProgram.

◆ bind()

void catos::Shader::bind ( )

Binds the shader.

◆ getCompilationErrorMessage()

const char * catos::Shader::getCompilationErrorMessage ( )

Returns the last compilation error.

◆ getShaderProgram()

ShaderProgram catos::Shader::getShaderProgram ( )
inline

Returns the raw ShaderProgram object for GL uses.

◆ init()

void catos::Shader::init ( const ShaderCreateInfo & createInfo)

Creates 2 shaders for the Vertex and Fragment Shader.

◆ setInt()

void catos::Shader::setInt ( const char * name,
int val )

Sets a int uniform.


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