remove some unused function args
authorCampbell Barton <ideasman42@gmail.com>
Thu, 30 Jul 2009 21:42:29 +0000 (21:42 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Thu, 30 Jul 2009 21:42:29 +0000 (21:42 +0000)
source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp
source/gameengine/Converter/BL_BlenderDataConversion.cpp
source/gameengine/Converter/BL_BlenderDataConversion.h
source/gameengine/Converter/BL_SkinMeshObject.cpp
source/gameengine/Converter/BL_SkinMeshObject.h
source/gameengine/Converter/KX_BlenderSceneConverter.cpp
source/gameengine/Converter/KX_BlenderSceneConverter.h
source/gameengine/Ketsji/KX_ISceneConverter.h
source/gameengine/Ketsji/KX_KetsjiEngine.cpp
source/gameengine/Rasterizer/RAS_MeshObject.cpp
source/gameengine/Rasterizer/RAS_MeshObject.h

index ec75137..d1b3625 100644 (file)
@@ -383,7 +383,6 @@ extern "C" void StartKetsjiShell(struct ScrArea *area,
                        {
                                // convert and add scene
                                sceneconverter->ConvertScene(
-                                       startscenename,
                                        startscene,
                                        dictionaryobject,
                                        keyboarddevice,
@@ -682,7 +681,6 @@ extern "C" void StartKetsjiShellSimulation(struct ScrArea *area,
                        {
                                // convert and add scene
                                sceneconverter->ConvertScene(
-                                       startscenename,
                                        startscene,
                                        dictionaryobject,
                                        keyboarddevice,
index caa7626..7cae1ee 100644 (file)
@@ -326,7 +326,6 @@ bool ConvertMaterial(
        MFace* mface, 
        MCol* mmcol, 
        int lightlayer, 
-       Object* blenderobj,
        MTF_localLayer *layers,
        bool glslmat)
 {
@@ -752,11 +751,11 @@ RAS_MeshObject* BL_ConvertMesh(Mesh* mesh, Object* blenderobj, RAS_IRenderTools*
        // Determine if we need to make a skinned mesh
        if (mesh->dvert || mesh->key || ((blenderobj->gameflag & OB_SOFT_BODY) != 0) || BL_ModifierDeformer::HasCompatibleDeformer(blenderobj))
        {
-               meshobj = new BL_SkinMeshObject(mesh, lightlayer);
+               meshobj = new BL_SkinMeshObject(mesh);
                skinMesh = true;
        }
        else
-               meshobj = new RAS_MeshObject(mesh, lightlayer);
+               meshobj = new RAS_MeshObject(mesh);
 
        // Extract avaiable layers
        MTF_localLayer *layers =  new MTF_localLayer[MAX_MTFACE];
@@ -861,7 +860,7 @@ RAS_MeshObject* BL_ConvertMesh(Mesh* mesh, Object* blenderobj, RAS_IRenderTools*
                                if (!bl_mat)
                                        bl_mat = new BL_Material();
                                ConvertMaterial(bl_mat, ma, tface, tfaceName, mface, mcol,
-                                       lightlayer, blenderobj, layers, converter->GetGLSLMaterials());
+                                       lightlayer, layers, converter->GetGLSLMaterials());
 
                                visible = ((bl_mat->ras_mode & POLY_VIS)!=0);
                                collider = ((bl_mat->ras_mode & COLLIDER)!=0);
@@ -1699,8 +1698,7 @@ static KX_GameObject *gameobject_from_blenderobject(
                                                                Object *ob, 
                                                                KX_Scene *kxscene, 
                                                                RAS_IRenderTools *rendertools, 
-                                                               KX_BlenderSceneConverter *converter,
-                                                               Scene *blenderscene) 
+                                                               KX_BlenderSceneConverter *converter) 
 {
        KX_GameObject *gameobj = NULL;
        
@@ -1912,7 +1910,6 @@ KX_GameObject* getGameOb(STR_String busc,CListValue* sumolist){
 
 // convert blender objects into ketsji gameobjects
 void BL_ConvertBlenderObjects(struct Main* maggie,
-                                                         const STR_String& scenename,
                                                          KX_Scene* kxscene,
                                                          KX_KetsjiEngine* ketsjiEngine,
                                                          e_PhysicsEngine       physics_engine,
@@ -1925,7 +1922,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
                                                          )
 {      
 
-       Scene *blenderscene = converter->GetBlenderSceneForName(scenename);
+       Scene *blenderscene = kxscene->GetBlenderScene();
        // for SETLOOPER
        Scene *sce;
        Base *base;
@@ -2021,8 +2018,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
                                                                                base->object, 
                                                                                kxscene, 
                                                                                rendertools, 
-                                                                               converter,
-                                                                               blenderscene);
+                                                                               converter);
                                                                                
                bool isInActiveLayer = (blenderobject->lay & activeLayerBitInfo) !=0;
                bool addobj=true;
@@ -2211,8 +2207,7 @@ void BL_ConvertBlenderObjects(struct Main* maggie,
                                                                                                                blenderobject, 
                                                                                                                kxscene, 
                                                                                                                rendertools, 
-                                                                                                               converter,
-                                                                                                               blenderscene);
+                                                                                                               converter);
                                                                                
                                                // this code is copied from above except that
                                                // object from groups are never in active layer
index 48f08fb..bf733b7 100644 (file)
@@ -37,7 +37,6 @@
 class RAS_MeshObject* BL_ConvertMesh(struct Mesh* mesh,struct Object* lightobj,class RAS_IRenderTools* rendertools,class KX_Scene* scene, class KX_BlenderSceneConverter *converter);
 
 void BL_ConvertBlenderObjects(struct Main* maggie,
-                                                         const STR_String& scenename,
                                                          class KX_Scene* kxscene,
                                                          class KX_KetsjiEngine* ketsjiEngine,
                                                          e_PhysicsEngine       physics_engine,
index 0a18296..4eb01df 100644 (file)
@@ -46,8 +46,8 @@
 #include "BL_SkinMeshObject.h"
 #include "BL_DeformableGameObject.h"
 
-BL_SkinMeshObject::BL_SkinMeshObject(Mesh* mesh, int lightlayer)
- : RAS_MeshObject (mesh, lightlayer)
+BL_SkinMeshObject::BL_SkinMeshObject(Mesh* mesh)
+ : RAS_MeshObject (mesh)
 { 
        m_bDeformed = true;
 
index 8544a2b..e2d0e37 100644 (file)
@@ -46,7 +46,7 @@ protected:
        vector<int>                              m_cacheWeightIndex;
 
 public:
-       BL_SkinMeshObject(Mesh* mesh, int lightlayer);
+       BL_SkinMeshObject(Mesh* mesh);
        ~BL_SkinMeshObject();
 
        void UpdateBuckets(void* clientobj, double* oglmatrix,
index 42b96d6..4031b48 100644 (file)
@@ -255,15 +255,14 @@ struct    BlenderDebugDraw : public btIDebugDraw
 
 #endif
 
-void KX_BlenderSceneConverter::ConvertScene(const STR_String& scenename,
-                                                                                       class KX_Scene* destinationscene,
+void KX_BlenderSceneConverter::ConvertScene(class KX_Scene* destinationscene,
                                                                                        PyObject* dictobj,
                                                                                        class SCA_IInputDevice* keyinputdev,
                                                                                        class RAS_IRenderTools* rendertools,
                                                                                        class RAS_ICanvas* canvas)
 {
        //find out which physics engine
-       Scene *blenderscene = GetBlenderSceneForName(scenename);
+       Scene *blenderscene = destinationscene->GetBlenderScene();
 
        e_PhysicsEngine physics_engine = UseBullet;
        bool useDbvtCulling = false;
@@ -357,7 +356,6 @@ void KX_BlenderSceneConverter::ConvertScene(const STR_String& scenename,
        }
 
        BL_ConvertBlenderObjects(m_maggie,
-               scenename,
                destinationscene,
                m_ketsjiEngine,
                physics_engine,
index cf8dd5b..820f608 100644 (file)
@@ -92,7 +92,6 @@ public:
         * dictobj: python dictionary (for pythoncontrollers)
         */
        virtual void    ConvertScene(
-                                               const STR_String& scenename,
                                                class KX_Scene* destinationscene,
                                                PyObject* dictobj,
                                                class SCA_IInputDevice* keyinputdev,
index 3709fa8..5c2c0bc 100644 (file)
@@ -47,7 +47,7 @@ public:
        destinationscene: pass an empty scene, everything goes into this
        dictobj: python dictionary (for pythoncontrollers)
        */
-       virtual void ConvertScene(const STR_String& scenename,
+       virtual void ConvertScene(
                class KX_Scene* destinationscene,
                PyObject* dictobj,
                class SCA_IInputDevice* keyinputdev,
index a43ea59..20600be 100644 (file)
@@ -1603,8 +1603,7 @@ KX_Scene* KX_KetsjiEngine::CreateScene(const STR_String& scenename)
                                                                          scenename,
                                                                          scene);
 
-       m_sceneconverter->ConvertScene(scenename,
-                                                         tmpscene,
+       m_sceneconverter->ConvertScene(tmpscene,
                                                          m_pythondictionary,
                                                          m_keyboarddevice,
                                                          m_rendertools,
index 0ae6ad9..0995d5a 100644 (file)
@@ -90,9 +90,8 @@ struct RAS_MeshObject::fronttoback
 
 STR_String RAS_MeshObject::s_emptyname = "";
 
-RAS_MeshObject::RAS_MeshObject(Mesh* mesh, int lightlayer)
-       : //m_lightlayer(lightlayer),
-       m_bModified(true),
+RAS_MeshObject::RAS_MeshObject(Mesh* mesh)
+       : m_bModified(true),
        m_bMeshModified(true),
        m_mesh(mesh),
        m_bDeformed(false)
index bf9c0f7..f34546a 100644 (file)
@@ -55,7 +55,6 @@ class RAS_MeshObject
 {
 private:
        unsigned int                            m_debugcolor;
-       //int                                                   m_lightlayer;
 
        bool                                            m_bModified;
        bool                                            m_bMeshModified;
@@ -77,7 +76,7 @@ protected:
 
 public:
        // for now, meshes need to be in a certain layer (to avoid sorting on lights in realtime)
-       RAS_MeshObject(Mesh* mesh, int lightlayer);
+       RAS_MeshObject(Mesh* mesh);
        virtual ~RAS_MeshObject();