BGE Rasterizer Cleanup: Removing KX_BlenderGL since it was mostly one-line functions...
[blender.git] / source / gameengine / Converter / BlenderWorldInfo.cpp
index f0d6083a8fa498573efc69e3237d2ab4bdbcd4b3..f1f264b33671539e905207a400a36c5766fdc704 100644 (file)
@@ -1,5 +1,4 @@
-/**
- * $Id$
+/*
  * ***** BEGIN GPL LICENSE BLOCK *****
  *
  * This program is free software; you can [0]istribute it and/or
  * ***** END GPL LICENSE BLOCK *****
  */
 
+/** \file gameengine/Converter/BlenderWorldInfo.cpp
+ *  \ingroup bgeconv
+ */
+
+
 #include <stdio.h>  // printf()
 
 #include "BlenderWorldInfo.h"
-#include "KX_BlenderGL.h"
 
 /* This little block needed for linking to Blender... */
 #ifdef WIN32
@@ -86,7 +89,7 @@ BlenderWorldInfo::BlenderWorldInfo(struct Scene *blenderscene, struct World* ble
                copy_v3_v3(m_backgroundcolor, &blenderworld->horr);
                copy_v3_v3(m_ambientcolor, &blenderworld->ambr);
 
-               if(blenderscene->r.color_mgt_flag & R_COLOR_MANAGEMENT) {
+               if (blenderscene->r.color_mgt_flag & R_COLOR_MANAGEMENT) {
                        linearrgb_to_srgb_v3_v3(m_mistcolor, m_mistcolor);
                        linearrgb_to_srgb_v3_v3(m_backgroundcolor, m_backgroundcolor);
                        linearrgb_to_srgb_v3_v3(m_ambientcolor, m_ambientcolor);
@@ -165,10 +168,10 @@ float BlenderWorldInfo::getMistStart()
 float BlenderWorldInfo::getMistDistance()
 {
        return m_mistdistance;
-}  
-    
+}
+
+
 
-    
 float BlenderWorldInfo::getMistColorRed()
 {
        return m_mistcolor[0];
@@ -188,8 +191,14 @@ 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    
+       void
 BlenderWorldInfo::setMistStart(
        float d
 ) {
@@ -205,7 +214,7 @@ BlenderWorldInfo::setMistDistance(
 }
 
 
-       void    
+       void
 BlenderWorldInfo::setMistColorRed(
        float d
 ) {
@@ -221,7 +230,7 @@ BlenderWorldInfo::setMistColorGreen(
 }
 
 
-       void    
+       void
 BlenderWorldInfo::setMistColorBlue(
        float d
 ) {