gl classes and functions
More...
|
void | drawGeo (const yourgame::gl::Geometry *geo, const yourgame::gl::DrawConfig &cfg) |
|
std::array< float, 4 > | drawSprite (yourgame::gl::Texture *texture, const yourgame::gl::TextureCoords &coords, float x, float y, float width, float height, float angle) |
|
void | drawSky (yourgame::gl::Texture *texture, yourgame::math::Camera *camera, std::array< float, 3 > tint, yourgame::math::Trafo *trafo) |
|
Texture * | loadTexture (const std::string &imgFilename, const std::string &atlasFilename, const yourgame::gl::TextureConfig &cfg) |
|
Texture * | loadCubemap (const std::vector< std::string > &filenames, const yourgame::gl::TextureConfig &cfg) |
| loads images and generates cubemap texture
|
|
Shader * | loadShader (const std::vector< std::pair< GLenum, std::string > > &shaderFilenames, const std::vector< std::pair< GLuint, std::string > > &attrLocs={}, const std::vector< std::pair< GLuint, std::string > > &fragDataLocs={}) |
|
Shader * | loadShaderFromStrings (const std::vector< std::pair< GLenum, std::string > > &shaderCodes, const std::vector< std::pair< GLuint, std::string > > &attrLocs={}, const std::vector< std::pair< GLuint, std::string > > &fragDataLocs={}) |
|
Geometry * | loadGeometry (const std::string &objFilename, const std::string &mtlFilename="") |
|
Geometry * | loadGeometryFromStrings (const std::string &objCode, const std::string &mtlCode="") |
|
◆ drawGeo()
◆ drawSky()
◆ drawSprite()
◆ loadCubemap()
loads images and generates cubemap texture
- Parameters
-
filenames | this order: POSITIVE_X, NEGATIVE_X, POSITIVE_Y, NEGATIVE_Y, POSITIVE_Z, NEGATIVE_Z |
◆ loadGeometry()
Geometry * yourgame::gl::loadGeometry |
( |
const std::string & |
objFilename, |
|
|
const std::string & |
mtlFilename = "" |
|
) |
| |
◆ loadGeometryFromStrings()
Geometry * yourgame::gl::loadGeometryFromStrings |
( |
const std::string & |
objCode, |
|
|
const std::string & |
mtlCode = "" |
|
) |
| |
◆ loadShader()
Shader * yourgame::gl::loadShader |
( |
const std::vector< std::pair< GLenum, std::string > > & |
shaderFilenames, |
|
|
const std::vector< std::pair< GLuint, std::string > > & |
attrLocs = {} , |
|
|
const std::vector< std::pair< GLuint, std::string > > & |
fragDataLocs = {} |
|
) |
| |
◆ loadShaderFromStrings()
Shader * yourgame::gl::loadShaderFromStrings |
( |
const std::vector< std::pair< GLenum, std::string > > & |
shaderCodes, |
|
|
const std::vector< std::pair< GLuint, std::string > > & |
attrLocs = {} , |
|
|
const std::vector< std::pair< GLuint, std::string > > & |
fragDataLocs = {} |
|
) |
| |
◆ loadTexture()
◆ attrLocColor
const GLuint yourgame::gl::attrLocColor = 3 |
◆ attrLocInstModelMatCol0
const GLuint yourgame::gl::attrLocInstModelMatCol0 = 4 |
◆ attrLocInstModelMatCol1
const GLuint yourgame::gl::attrLocInstModelMatCol1 = 5 |
◆ attrLocInstModelMatCol2
const GLuint yourgame::gl::attrLocInstModelMatCol2 = 6 |
◆ attrLocInstModelMatCol3
const GLuint yourgame::gl::attrLocInstModelMatCol3 = 7 |
◆ attrLocInstProgress
const GLuint yourgame::gl::attrLocInstProgress = 8 |
◆ attrLocNormal
const GLuint yourgame::gl::attrLocNormal = 1 |
◆ attrLocPosition
const GLuint yourgame::gl::attrLocPosition = 0 |
◆ attrLocTexcoords
const GLuint yourgame::gl::attrLocTexcoords = 2 |
◆ textureUnitBufferColor0
const GLenum yourgame::gl::textureUnitBufferColor0 = GL_TEXTURE7 |
◆ textureUnitBufferDepth
const GLenum yourgame::gl::textureUnitBufferDepth = GL_TEXTURE6 |
◆ textureUnitDiffuse
const GLenum yourgame::gl::textureUnitDiffuse = GL_TEXTURE0 |
◆ textureUnitSky
const GLenum yourgame::gl::textureUnitSky = GL_TEXTURE5 |
◆ textureUnitSkyCube
const GLenum yourgame::gl::textureUnitSkyCube = GL_TEXTURE4 |
◆ unifNameCameraPosition
const GLchar * yourgame::gl::unifNameCameraPosition = "camPos" |
◆ unifNameCameraTrafo
const GLchar * yourgame::gl::unifNameCameraTrafo = "camTrafo" |
◆ unifNameLightAmbient
const GLchar * yourgame::gl::unifNameLightAmbient = "lightAmbient" |
◆ unifNameLightDiffuse
const GLchar * yourgame::gl::unifNameLightDiffuse = "lightDiffuse" |
◆ unifNameLightPosition
const GLchar * yourgame::gl::unifNameLightPosition = "lightPosition" |
◆ unifNameLightSpecular
const GLchar * yourgame::gl::unifNameLightSpecular = "lightSpecular" |
◆ unifNameModelMatrix
const GLchar * yourgame::gl::unifNameModelMatrix = "modelMat" |
◆ unifNameMvpMatrix
const GLchar * yourgame::gl::unifNameMvpMatrix = "mvpMat" |
◆ unifNameNormalMatrix
const GLchar * yourgame::gl::unifNameNormalMatrix = "normalMat" |
◆ unifNameSkyRotationInv
const GLchar * yourgame::gl::unifNameSkyRotationInv = "skyRotInv" |
◆ unifNameSubtexture
const GLchar * yourgame::gl::unifNameSubtexture = "subtex" |
◆ unifNameTextureBufferColor0
const GLchar * yourgame::gl::unifNameTextureBufferColor0 = "textureBufferColor0" |
◆ unifNameTextureBufferDepth
const GLchar * yourgame::gl::unifNameTextureBufferDepth = "textureBufferDepth" |
◆ unifNameTextureDiffuse
const GLchar * yourgame::gl::unifNameTextureDiffuse = "textureDiffuse" |
◆ unifNameTextureSky
const GLchar * yourgame::gl::unifNameTextureSky = "textureSky" |
◆ unifNameTextureSkyCube
const GLchar * yourgame::gl::unifNameTextureSkyCube = "textureSkyCube" |
◆ unifNameVpMatrix
const GLchar * yourgame::gl::unifNameVpMatrix = "vpMat" |
◆ unifValueTextureBufferColor0
const GLint yourgame::gl::unifValueTextureBufferColor0 = 7 |
◆ unifValueTextureBufferDepth
const GLint yourgame::gl::unifValueTextureBufferDepth = 6 |
◆ unifValueTextureDiffuse
const GLint yourgame::gl::unifValueTextureDiffuse = 0 |
◆ unifValueTextureSky
const GLint yourgame::gl::unifValueTextureSky = 5 |
◆ unifValueTextureSkyCube
const GLint yourgame::gl::unifValueTextureSkyCube = 4 |