OpenGL fix - fixed a crash when you activate Alpha Threshold checkbox without a diffuse map

This commit is contained in:
Anis 2015-01-20 19:07:29 +01:00
parent d08db6cc54
commit c9116dd4a4

View file

@ -986,11 +986,9 @@ void DiffuseMapFeatGLSL::setTexData( Material::StageData &stageDat,
U32 &texIndex )
{
GFXTextureObject *tex = stageDat.getTex( MFT_DiffuseMap );
passData.mSamplerNames[ texIndex ] = "diffuseMap";
if ( tex )
{
passData.mSamplerNames[ texIndex ] = "diffuseMap";
passData.mTexSlot[ texIndex++ ].texObject = tex;
}
}