diff options
author | Mitchell Stokes <mogurijin@gmail.com> | 2013-05-11 06:43:35 +0400 |
---|---|---|
committer | Mitchell Stokes <mogurijin@gmail.com> | 2013-05-11 06:43:35 +0400 |
commit | b0261a446d907a2f72d87212eac0b98199cf8708 (patch) | |
tree | b20e75cc0c65511a494d74fddbe5ab0db8977981 /source/gameengine/Converter/BL_BlenderDataConversion.cpp | |
parent | ce39c806cfca6ff1696eba3f50c08b9ed80a3c67 (diff) |
BGE: Fix for [#34631] "Textures bad in game mode" reported by pablo aaa (p9ablo).
Disabling caching if materials have Face Textures enabled.
Diffstat (limited to 'source/gameengine/Converter/BL_BlenderDataConversion.cpp')
-rw-r--r-- | source/gameengine/Converter/BL_BlenderDataConversion.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.cpp b/source/gameengine/Converter/BL_BlenderDataConversion.cpp index 6912adbb60c..ebe35369844 100644 --- a/source/gameengine/Converter/BL_BlenderDataConversion.cpp +++ b/source/gameengine/Converter/BL_BlenderDataConversion.cpp @@ -905,7 +905,8 @@ static RAS_MaterialBucket *material_from_mesh(Material *ma, MFace *mface, MTFace ConvertMaterial(bl_mat, ma, tface, tfaceName, mface, mcol, converter->GetGLSLMaterials()); - converter->CacheBlenderMaterial(ma, bl_mat); + if ((!ma->mode & MA_FACETEXTURE)) + converter->CacheBlenderMaterial(ma, bl_mat); } const bool use_vcol = GetMaterialUseVColor(ma, bl_mat->glslmat); @@ -920,7 +921,8 @@ static RAS_MaterialBucket *material_from_mesh(Material *ma, MFace *mface, MTFace kx_blmat->Initialize(scene, bl_mat, (ma?&ma->game:NULL), lightlayer); polymat = static_cast<RAS_IPolyMaterial*>(kx_blmat); - converter->CachePolyMaterial(ma, polymat); + if ((!ma->mode & MA_FACETEXTURE)) + converter->CachePolyMaterial(ma, polymat); } } else { |