diff --git a/source/blender/collada/AnimationImporter.cpp b/source/blender/collada/AnimationImporter.cpp index 15bebbe8e20..234a6084356 100644 --- a/source/blender/collada/AnimationImporter.cpp +++ b/source/blender/collada/AnimationImporter.cpp @@ -681,7 +681,7 @@ void AnimationImporter::translate_Animations_NEW ( COLLADAFW::Node * node , const char *bone_name = is_joint ? bc_get_joint_name(node) : NULL; - AnimationType type = get_animation_type(node, FW_object_map ); + int animType = get_animation_type(node, FW_object_map ); char joint_path[200]; @@ -754,10 +754,10 @@ void AnimationImporter::translate_Animations_NEW ( COLLADAFW::Node * node , } //Check if object is animated by checking if animlist_map holds the animlist_id of node transforms -AnimationImporter::AnimationType AnimationImporter::get_animation_type ( const COLLADAFW::Node * node , +int AnimationImporter::get_animation_type ( const COLLADAFW::Node * node , std::map FW_object_map) { - AnimationImporter::AnimationType type = AnimationImporter::INANIMATE ; + int type = INANIMATE ; //bool exists = false; const COLLADAFW::TransformationPointerArray& nodeTransforms = node->getTransformations(); @@ -770,7 +770,7 @@ AnimationImporter::AnimationType AnimationImporter::get_animation_type ( const C if (animlist_map.find(listid) == animlist_map.end()) continue ; else { - type = AnimationImporter::NODE_TRANSFORM; + type = type|NODE_TRANSFORM; break; } } @@ -785,7 +785,7 @@ AnimationImporter::AnimationType AnimationImporter::get_animation_type ( const C if (animlist_map.find(listid) == animlist_map.end()) continue ; else { - type = AnimationImporter::LIGHT_COLOR; + type = type|LIGHT_COLOR; break; } } diff --git a/source/blender/collada/AnimationImporter.h b/source/blender/collada/AnimationImporter.h index 54ede656ea7..cc3ffe65735 100644 --- a/source/blender/collada/AnimationImporter.h +++ b/source/blender/collada/AnimationImporter.h @@ -80,12 +80,14 @@ private: void fcurve_deg_to_rad(FCurve *cu); void add_fcurves_to_object(Object *ob, std::vector& curves, char *rna_path, int array_index, Animation *animated); + + int typeFlag; enum AnimationType { - NODE_TRANSFORM, - LIGHT_COLOR, - INANIMATE + INANIMATE = 0, + NODE_TRANSFORM = 1, + LIGHT_COLOR = 2, }; public: @@ -108,7 +110,7 @@ public: std::map& object_map , std::map FW_object_map); - AnimationType get_animation_type( const COLLADAFW::Node * node , std::map FW_object_map ) ; + int get_animation_type( const COLLADAFW::Node * node , std::map FW_object_map ) ; void Assign_transform_animations(COLLADAFW::Transformation* transform ,