utilisation interne. abstraction d'un shader object, ressource openGL. More...
#include <GLShaderObject.h>
Public Types | |
| enum | { VERTEX = 0, FRAGMENT, GEOMETRY, CONTROL, EVALUATION, SHADERTYPE_LAST } |
| types de shaders. More... | |
Public Member Functions | |
| GLShaderObject (const unsigned int type) | |
| constructeur, | |
| virtual | ~GLShaderObject () |
| destructeur. | |
| int | pushDefinition (const std::string &definition, const std::string &value="") |
| ajoute une definition au source. "#define 'definition' 'value'". | |
| int | setDefinitions (const std::vector< std::string > &definitions) |
| remplace l'ensemble de definitions. | |
| const std::vector< std::string > * | definitions () |
| renvoie les definitions. | |
| int | pushSource (const TextFile *text) |
| ajoute le contenu d'un fichier source. | |
| TextFile * | source () const |
| renvoie le source du shader. | |
| void | printSource () const |
| affiche les sources du shader. | |
| void | printErrors () |
| affiche les erreurs de compilation du shader. | |
| int | createGLResource () |
| cree l'objet openGL. | |
| int | releaseGLResource () |
| detruit l'objet openGL. | |
| int | clear () |
| reinitialise l'etat du shader. | |
| bool | errors () const |
| renvoie vrai ou faux, si erreurs de lecture du source. | |
| unsigned int | type () const |
| renvoie le type du shader. | |
| GLuint | name () const |
| renvoie l'identifiant de l'objet openGL. | |
Static Public Attributes | |
| static GLenum | ShaderType [] |
| static const char * | ShaderTypeString [] |
Protected Attributes | |
| TextFile * | m_text |
| unsigned int | m_type |
| bool | m_errors |
| GLuint | m_name |
utilisation interne. abstraction d'un shader object, ressource openGL.
| anonymous enum |
| gk::GLShaderObject::GLShaderObject | ( | const unsigned int | type | ) |
constructeur,
| type | correspond a une contante gk::GLShaderObject::VERTEX, etc. |
GLenum gk::GLShaderObject::ShaderType [static] |
{
GL_VERTEX_SHADER,
GL_FRAGMENT_SHADER,
GL_GEOMETRY_SHADER,
GL_TESS_CONTROL_SHADER,
GL_TESS_EVALUATION_SHADER,
0
}
const char * gk::GLShaderObject::ShaderTypeString [static] |
{
"vertex",
"fragment",
"geometry",
"control",
"evaluation",
""
}
1.7.6.1