Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2009-03-24 18:45:08 +0300
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2009-03-24 18:45:08 +0300
commitce8badeb187931cc24d29730d0d10a7242bb7969 (patch)
tree61791f61cb6d7de53aaceaa520a28cfe635292c7 /source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
parentdbe675195d8f78fb3a5f9b89d0c6b89a47513198 (diff)
Fix for bug #18423: BGE lights in overlay scene also affected
other scenes, for texture face / multitexture materials. Fix for bug #18428: BGE lights on hidden layers were still used, for all material types, now they have no effect
Diffstat (limited to 'source/gameengine/Rasterizer/RAS_MaterialBucket.cpp')
-rw-r--r--source/gameengine/Rasterizer/RAS_MaterialBucket.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp b/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
index d8631c1edf6..20a8e9c3574 100644
--- a/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
+++ b/source/gameengine/Rasterizer/RAS_MaterialBucket.cpp
@@ -513,13 +513,13 @@ list<RAS_MeshSlot>::iterator RAS_MaterialBucket::msEnd()
bool RAS_MaterialBucket::ActivateMaterial(const MT_Transform& cameratrans, RAS_IRasterizer* rasty,
RAS_IRenderTools *rendertools)
{
- if (!rasty->SetMaterial(*m_material))
+ bool uselights;
+
+ if(!rasty->SetMaterial(*m_material))
return false;
- if (m_material->UsesLighting(rasty))
- rendertools->ProcessLighting(rasty, RAS_IRenderTools::RAS_LIGHT_OBJECT_LAYER, cameratrans);
- else
- rendertools->ProcessLighting(rasty, -1, cameratrans);
+ uselights= m_material->UsesLighting(rasty);
+ rendertools->ProcessLighting(rasty, uselights, cameratrans);
return true;
}