Skip to content

Commit

Permalink
fix crash when using track debug. unfortunately, visual aids are not …
Browse files Browse the repository at this point in the history
…yet functional
  • Loading branch information
auriamg committed Jun 12, 2014
1 parent e5532c3 commit 540df39
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/graphics/stkmesh.cpp
Expand Up @@ -553,8 +553,11 @@ void drawTransparentFogObject(const GLMesh &mesh, const core::matrix4 &ModelView
tmpcol.getGreen() / 255.0f,
tmpcol.getBlue() / 255.0f);

compressTexture(mesh.textures[0], true);
setTexture(0, getTextureGLuint(mesh.textures[0]), GL_LINEAR, GL_LINEAR_MIPMAP_LINEAR, true);
if (mesh.textures[0] != NULL)
{
compressTexture(mesh.textures[0], true);
setTexture(0, getTextureGLuint(mesh.textures[0]), GL_LINEAR, GL_LINEAR_MIPMAP_LINEAR, true);
}

glUseProgram(MeshShader::TransparentFogShader::Program);
MeshShader::TransparentFogShader::setUniforms(ModelViewProjectionMatrix, TextureMatrix, fogmax, startH, endH, start, end, col, Camera::getCamera(0)->getCameraSceneNode()->getAbsolutePosition(), 0);
Expand Down

0 comments on commit 540df39

Please sign in to comment.