AnimationType flag. AnimationType Enum update.
This commit is contained in:
@@ -681,7 +681,7 @@ void AnimationImporter::translate_Animations_NEW ( COLLADAFW::Node * node ,
|
|||||||
|
|
||||||
const char *bone_name = is_joint ? bc_get_joint_name(node) : NULL;
|
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];
|
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
|
//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<COLLADAFW::UniqueId, const COLLADAFW::Object*> FW_object_map)
|
std::map<COLLADAFW::UniqueId, const COLLADAFW::Object*> FW_object_map)
|
||||||
{
|
{
|
||||||
AnimationImporter::AnimationType type = AnimationImporter::INANIMATE ;
|
int type = INANIMATE ;
|
||||||
//bool exists = false;
|
//bool exists = false;
|
||||||
const COLLADAFW::TransformationPointerArray& nodeTransforms = node->getTransformations();
|
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 ;
|
if (animlist_map.find(listid) == animlist_map.end()) continue ;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
type = AnimationImporter::NODE_TRANSFORM;
|
type = type|NODE_TRANSFORM;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -785,7 +785,7 @@ AnimationImporter::AnimationType AnimationImporter::get_animation_type ( const C
|
|||||||
if (animlist_map.find(listid) == animlist_map.end()) continue ;
|
if (animlist_map.find(listid) == animlist_map.end()) continue ;
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
type = AnimationImporter::LIGHT_COLOR;
|
type = type|LIGHT_COLOR;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -81,11 +81,13 @@ private:
|
|||||||
|
|
||||||
void add_fcurves_to_object(Object *ob, std::vector<FCurve*>& curves, char *rna_path, int array_index, Animation *animated);
|
void add_fcurves_to_object(Object *ob, std::vector<FCurve*>& curves, char *rna_path, int array_index, Animation *animated);
|
||||||
|
|
||||||
|
int typeFlag;
|
||||||
|
|
||||||
enum AnimationType
|
enum AnimationType
|
||||||
{
|
{
|
||||||
NODE_TRANSFORM,
|
INANIMATE = 0,
|
||||||
LIGHT_COLOR,
|
NODE_TRANSFORM = 1,
|
||||||
INANIMATE
|
LIGHT_COLOR = 2,
|
||||||
};
|
};
|
||||||
public:
|
public:
|
||||||
|
|
||||||
@@ -108,7 +110,7 @@ public:
|
|||||||
std::map<COLLADAFW::UniqueId, Object*>& object_map ,
|
std::map<COLLADAFW::UniqueId, Object*>& object_map ,
|
||||||
std::map<COLLADAFW::UniqueId, const COLLADAFW::Object*> FW_object_map);
|
std::map<COLLADAFW::UniqueId, const COLLADAFW::Object*> FW_object_map);
|
||||||
|
|
||||||
AnimationType get_animation_type( const COLLADAFW::Node * node , std::map<COLLADAFW::UniqueId,const COLLADAFW::Object*> FW_object_map ) ;
|
int get_animation_type( const COLLADAFW::Node * node , std::map<COLLADAFW::UniqueId,const COLLADAFW::Object*> FW_object_map ) ;
|
||||||
|
|
||||||
|
|
||||||
void Assign_transform_animations(COLLADAFW::Transformation* transform ,
|
void Assign_transform_animations(COLLADAFW::Transformation* transform ,
|
||||||
|
Reference in New Issue
Block a user