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:
authorDalai Felinto <dfelinto@gmail.com>2011-01-19 01:27:18 +0300
committerDalai Felinto <dfelinto@gmail.com>2011-01-19 01:27:18 +0300
commiteff0e29cbae095baae26fc650baed36ff0573f50 (patch)
treebfd229a93cc3ee39db4d40ebac5621404049a52d /source/gameengine/Converter
parent3b0c2accc66a2366905a617a280fa79711e8d276 (diff)
BGE BugFix [#25711]render.setBackgroundColor() does not work:
Since rev.2 (hans ftw) we have a strange situation where horizon color was being used at Convert time for the WorldInfo background color (and for the fog). However through the Python API only the Rasterizer background color was being updated. On top of that the KX_KetsjiEngine.cpp::SetBackGround was using the WorldInfo bgcolor when render mode was the potato one (TEXTURED). Bottomline, when in potato mode the glClearColor used was the original one in worldinfo, not the API updated one in Rasterized.
Diffstat (limited to 'source/gameengine/Converter')
-rw-r--r--source/gameengine/Converter/BlenderWorldInfo.cpp6
-rw-r--r--source/gameengine/Converter/BlenderWorldInfo.h6
2 files changed, 12 insertions, 0 deletions
diff --git a/source/gameengine/Converter/BlenderWorldInfo.cpp b/source/gameengine/Converter/BlenderWorldInfo.cpp
index f0d6083a8fa..60cb4a751bb 100644
--- a/source/gameengine/Converter/BlenderWorldInfo.cpp
+++ b/source/gameengine/Converter/BlenderWorldInfo.cpp
@@ -188,6 +188,12 @@ float BlenderWorldInfo::getMistColorBlue()
return m_mistcolor[2];
}
+void BlenderWorldInfo::setBackColor(float r, float g, float b)
+{
+ m_backgroundcolor[0] = r;
+ m_backgroundcolor[1] = g;
+ m_backgroundcolor[2] = b;
+}
void
BlenderWorldInfo::setMistStart(
diff --git a/source/gameengine/Converter/BlenderWorldInfo.h b/source/gameengine/Converter/BlenderWorldInfo.h
index a430e18223e..29145344d18 100644
--- a/source/gameengine/Converter/BlenderWorldInfo.h
+++ b/source/gameengine/Converter/BlenderWorldInfo.h
@@ -64,6 +64,12 @@ public:
float getMistColorGreen();
float getMistColorBlue();
+ void
+ setBackColor(
+ float r,
+ float g,
+ float b
+ );
void
setMistStart(
float d