diff options
author | Luca Rood <dev@lucarood.com> | 2017-07-21 12:53:13 +0300 |
---|---|---|
committer | Luca Rood <dev@lucarood.com> | 2017-07-21 15:47:26 +0300 |
commit | 1c4c288727214fa0588d66556a1cdf71755d70b4 (patch) | |
tree | 1433952be7e88cc7d09e8563831995290e3013ce /source/gameengine | |
parent | 9edb7e49d7e5e69385f3a0434c568c79fad88cd8 (diff) |
Pass EvaluationContext argument everywhere
Note that some little parts of code have been dissabled because eval_ctx
was not available there. This should be resolved once DerivedMesh is
replaced.
Diffstat (limited to 'source/gameengine')
4 files changed, 18 insertions, 1 deletions
diff --git a/source/gameengine/Converter/BL_ArmatureObject.cpp b/source/gameengine/Converter/BL_ArmatureObject.cpp index 1f6687c2b67..049fd49cab9 100644 --- a/source/gameengine/Converter/BL_ArmatureObject.cpp +++ b/source/gameengine/Converter/BL_ArmatureObject.cpp @@ -470,6 +470,8 @@ bool BL_ArmatureObject::UnlinkObject(SCA_IObject* clientobj) void BL_ArmatureObject::ApplyPose() { + /* TODO: This doesn't work currently because of eval_ctx. */ +#if 0 m_armpose = m_objArma->pose; m_objArma->pose = m_pose; // in the GE, we use ctime to store the timestep @@ -492,6 +494,7 @@ void BL_ArmatureObject::ApplyPose() } m_lastapplyframe = m_lastframe; } +#endif } void BL_ArmatureObject::RestorePose() diff --git a/source/gameengine/Converter/BL_BlenderDataConversion.cpp b/source/gameengine/Converter/BL_BlenderDataConversion.cpp index 6667e6a44c2..71ac6f4fdb1 100644 --- a/source/gameengine/Converter/BL_BlenderDataConversion.cpp +++ b/source/gameengine/Converter/BL_BlenderDataConversion.cpp @@ -45,7 +45,9 @@ * This workaround will make sure that curve_cache for curves * is up-to-date. */ -#define THREADED_DAG_WORKAROUND + +/* TODO: Disabled for now, because of eval_ctx. */ +//#define THREADED_DAG_WORKAROUND #include <math.h> #include <vector> diff --git a/source/gameengine/Converter/BL_ModifierDeformer.cpp b/source/gameengine/Converter/BL_ModifierDeformer.cpp index b40fb7a9f47..3be2c1aff43 100644 --- a/source/gameengine/Converter/BL_ModifierDeformer.cpp +++ b/source/gameengine/Converter/BL_ModifierDeformer.cpp @@ -133,6 +133,8 @@ bool BL_ModifierDeformer::HasArmatureDeformer(Object *ob) // return a deformed mesh that supports mapping (with a valid CD_ORIGINDEX layer) struct DerivedMesh* BL_ModifierDeformer::GetPhysicsMesh() { + /* TODO: This doesn't work currently because of eval_ctx. */ +#if 0 /* we need to compute the deformed mesh taking into account the current * shape and skin deformers, we cannot just call mesh_create_derived_physics() * because that would use the m_transvers already deformed previously by BL_ModifierDeformer::Update(), @@ -152,10 +154,14 @@ struct DerivedMesh* BL_ModifierDeformer::GetPhysicsMesh() /* m_transverts is correct here (takes into account deform only modifiers) */ /* the derived mesh returned by this function must be released by the caller !!! */ return dm; +#endif + return NULL; } bool BL_ModifierDeformer::Update(void) { + /* TODO: This doesn't work currently because of eval_ctx. */ +#if 0 bool bShapeUpdate = BL_ShapeDeformer::Update(); if (bShapeUpdate || m_lastModifierUpdate != m_gameobj->GetLastFrame()) { @@ -208,6 +214,8 @@ bool BL_ModifierDeformer::Update(void) } } return bShapeUpdate; +#endif + return false; } bool BL_ModifierDeformer::Apply(RAS_IPolyMaterial *mat) diff --git a/source/gameengine/Ketsji/KX_NavMeshObject.cpp b/source/gameengine/Ketsji/KX_NavMeshObject.cpp index 5beda2e038a..83accb1d7a5 100644 --- a/source/gameengine/Ketsji/KX_NavMeshObject.cpp +++ b/source/gameengine/Ketsji/KX_NavMeshObject.cpp @@ -113,6 +113,8 @@ bool KX_NavMeshObject::BuildVertIndArrays(float *&vertices, int& nverts, float *&dvertices, int &ndvertsuniq, unsigned short *&dtris, int& ndtris, int &vertsPerPoly) { + /* TODO: This doesn't work currently because of eval_ctx. */ +#if 0 DerivedMesh* dm = mesh_create_derived_no_virtual(GetScene()->GetBlenderScene(), GetBlenderObject(), NULL, CD_MASK_MESH); CustomData *pdata = dm->getPolyDataLayout(dm); @@ -280,6 +282,8 @@ bool KX_NavMeshObject::BuildVertIndArrays(float *&vertices, int& nverts, dm->release(dm); return true; +#endif + return false; } |