From 299ff91ea1fe5623bea1c6775cb8250d5e4ec3a0 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 5 May 2012 14:33:36 +0000 Subject: code cleanup: BKE_scene api naming. also stop numpy from being found in /usr/include with cmake. --- source/blender/collada/AnimationExporter.cpp | 4 ++-- source/blender/collada/AnimationImporter.cpp | 2 +- source/blender/collada/DocumentImporter.cpp | 6 +++--- source/blender/collada/collada_utils.cpp | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) (limited to 'source/blender/collada') diff --git a/source/blender/collada/AnimationExporter.cpp b/source/blender/collada/AnimationExporter.cpp index 6565a9e0c2e..3c90c5ad055 100644 --- a/source/blender/collada/AnimationExporter.cpp +++ b/source/blender/collada/AnimationExporter.cpp @@ -753,7 +753,7 @@ std::string AnimationExporter::create_4x4_source(std::vector &frames, Obj for (it = frames.begin(); it != frames.end(); it++) { float mat[4][4], ipar[4][4]; - float ctime = BKE_frame_to_ctime(scene, *it); + float ctime = BKE_scene_frame_get_from_ctime(scene, *it); BKE_animsys_evaluate_animdata(scene, &ob_arm->id, ob_arm->adt, ctime, ADT_RECALC_ANIM); where_is_pose_bone(scene, ob_arm, pchan, ctime, 1); @@ -1278,7 +1278,7 @@ void AnimationExporter::sample_animation(float *v, std::vector &frames, i for (it = frames.begin(); it != frames.end(); it++) { float mat[4][4], ipar[4][4]; - float ctime = BKE_frame_to_ctime(scene, *it); + float ctime = BKE_scene_frame_get_from_ctime(scene, *it); BKE_animsys_evaluate_animdata(scene, &ob_arm->id, ob_arm->adt, ctime, ADT_RECALC_ANIM); diff --git a/source/blender/collada/AnimationImporter.cpp b/source/blender/collada/AnimationImporter.cpp index 34f7efa9de0..d6b6bfeb73d 100644 --- a/source/blender/collada/AnimationImporter.cpp +++ b/source/blender/collada/AnimationImporter.cpp @@ -1772,7 +1772,7 @@ Object *AnimationImporter::get_joint_object(COLLADAFW::Node *root, COLLADAFW::No if (joint_objects.find(node->getUniqueId()) == joint_objects.end()) { Object *job = bc_add_object(scene, OB_EMPTY, (char*)get_joint_name(node)); - job->lay = object_in_scene(job, scene)->lay = 2; + job->lay = BKE_scene_base_find(scene, job)->lay = 2; mul_v3_fl(job->size, 0.5f); job->recalc |= OB_RECALC_OB; diff --git a/source/blender/collada/DocumentImporter.cpp b/source/blender/collada/DocumentImporter.cpp index 9216d7fa30e..3976d8115c1 100644 --- a/source/blender/collada/DocumentImporter.cpp +++ b/source/blender/collada/DocumentImporter.cpp @@ -122,7 +122,7 @@ bool DocumentImporter::import() loader.registerExtraDataCallbackHandler(ehandler); // deselect all to select new objects - scene_deselect_all(CTX_data_scene(mContext)); + BKE_scene_base_deselect_all(CTX_data_scene(mContext)); if (!root.loadDocument(mFilename)) { fprintf(stderr, "COLLADAFW::Root::loadDocument() returned false on 1st pass\n"); @@ -227,7 +227,7 @@ void DocumentImporter::finish() for (it = libnode_ob.begin(); it != libnode_ob.end(); it++) { Object *ob = *it; - Base *base = object_in_scene(ob, sce); + Base *base = BKE_scene_base_find(sce, ob); if (base) { BLI_remlink(&sce->base, base); BKE_libblock_free_us(&G.main->object, base->object); @@ -340,7 +340,7 @@ Object* DocumentImporter::create_instance_node(Object *source_ob, COLLADAFW::Nod Object *obn = BKE_object_copy(source_ob); obn->recalc |= OB_RECALC_OB|OB_RECALC_DATA|OB_RECALC_TIME; - scene_add_base(sce, obn); + BKE_scene_base_add(sce, obn); if (instance_node) { anim_importer.read_node_transform(instance_node, obn); diff --git a/source/blender/collada/collada_utils.cpp b/source/blender/collada/collada_utils.cpp index d7ea74b7b04..8b7a28e5fbe 100644 --- a/source/blender/collada/collada_utils.cpp +++ b/source/blender/collada/collada_utils.cpp @@ -120,7 +120,7 @@ Object *bc_add_object(Scene *scene, int type, const char *name) ob->lay= scene->lay; ob->recalc |= OB_RECALC_OB|OB_RECALC_DATA|OB_RECALC_TIME; - scene_select_base(scene, scene_add_base(scene, ob)); + BKE_scene_base_select(scene, BKE_scene_base_add(scene, ob)); return ob; } -- cgit v1.2.3