- fbx: switch to always generating a full transformation chain (temporary solution to get the transformation order right for now!).

pull/14/head
Alexander Gessler 2012-07-27 19:41:14 +02:00
parent 6efe9517f0
commit 4c58328c98
1 changed files with 5 additions and 2 deletions

View File

@ -337,6 +337,8 @@ private:
/** checks if a node has more than just scaling, rotation and translation components */
bool NeedsComplexTransformationChain(const Model& model)
{
return true;
const PropertyTable& props = model.Props();
bool ok;
@ -444,6 +446,7 @@ private:
GetRotationMatrix(rot, Rotation, chain[TransformationComp_Rotation]);
}
is_complex = true;
// is_complex needs to be consistent with NeedsComplexTransformationChain()
// or the interplay between this code and the animation converter would
@ -469,7 +472,7 @@ private:
const TransformationComp comp = static_cast<TransformationComp>(i);
if (chain[i].IsIdentity() && (anim_chain_bitmask & bit) == 0) {
continue;
//continue;
}
aiNode* nd = new aiNode();
@ -490,7 +493,7 @@ private:
nd->mName.Set(name);
for (size_t i = 0; i < TransformationComp_MAXIMUM; ++i) {
nd->mTransformation *= chain[i];
nd->mTransformation = nd->mTransformation * chain[i];
}
}