From 4877c9362aae969a74744dcb4038e088cd56b65f Mon Sep 17 00:00:00 2001 From: Gaia Clary Date: Tue, 14 Mar 2017 15:07:31 +0100 Subject: Collada simplify: avoid duplicate negation in boolean --- source/blender/collada/ArmatureImporter.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'source/blender/collada') diff --git a/source/blender/collada/ArmatureImporter.cpp b/source/blender/collada/ArmatureImporter.cpp index 17334ca326c..f4ce3992771 100644 --- a/source/blender/collada/ArmatureImporter.cpp +++ b/source/blender/collada/ArmatureImporter.cpp @@ -106,7 +106,7 @@ int ArmatureImporter::create_bone(SkinInfo *skin, COLLADAFW::Node *node, EditBon */ std::map::iterator skin_it; - bool bone_is_not_skinned = true; + bool bone_is_skinned = false; for (skin_it = skin_by_data_uid.begin(); skin_it != skin_by_data_uid.end(); skin_it++) { SkinInfo *b = &skin_it->second; @@ -123,13 +123,13 @@ int ArmatureImporter::create_bone(SkinInfo *skin, COLLADAFW::Node *node, EditBon mul_m4_m4m4(mat, invmat, mat); } - bone_is_not_skinned = false; + bone_is_skinned = true; break; } } // create a bone even if there's no joint data for it (i.e. it has no influence) - if (bone_is_not_skinned) { + if (!bone_is_skinned) { float obmat[4][4]; // bone-space get_node_mat(obmat, node, NULL, NULL); @@ -141,6 +141,7 @@ int ArmatureImporter::create_bone(SkinInfo *skin, COLLADAFW::Node *node, EditBon else { copy_m4_m4(mat, obmat); } + } if (parent) bone->parent = parent; -- cgit v1.2.3