ScenePreprocessor: fix invalid index counter.
parent
dfaea27dfc
commit
499886f89e
|
@ -176,22 +176,22 @@ void ScenePreprocessor::ProcessAnimation (aiAnimation* anim)
|
||||||
if (anim->mDuration == -1.) {
|
if (anim->mDuration == -1.) {
|
||||||
|
|
||||||
// Position keys
|
// Position keys
|
||||||
for (unsigned int i = 0; i < channel->mNumPositionKeys;++i) {
|
for (unsigned int j = 0; j < channel->mNumPositionKeys;++j) {
|
||||||
aiVectorKey& key = channel->mPositionKeys[i];
|
aiVectorKey& key = channel->mPositionKeys[j];
|
||||||
first = std::min (first, key.mTime);
|
first = std::min (first, key.mTime);
|
||||||
last = std::max (last, key.mTime);
|
last = std::max (last, key.mTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Scaling keys
|
// Scaling keys
|
||||||
for (unsigned int i = 0; i < channel->mNumScalingKeys;++i) {
|
for (unsigned int j = 0; j < channel->mNumScalingKeys;++j ) {
|
||||||
aiVectorKey& key = channel->mScalingKeys[i];
|
aiVectorKey& key = channel->mScalingKeys[j];
|
||||||
first = std::min (first, key.mTime);
|
first = std::min (first, key.mTime);
|
||||||
last = std::max (last, key.mTime);
|
last = std::max (last, key.mTime);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Rotation keys
|
// Rotation keys
|
||||||
for (unsigned int i = 0; i < channel->mNumRotationKeys;++i) {
|
for (unsigned int j = 0; j < channel->mNumRotationKeys;++j ) {
|
||||||
aiQuatKey& key = channel->mRotationKeys[i];
|
aiQuatKey& key = channel->mRotationKeys[ j ];
|
||||||
first = std::min (first, key.mTime);
|
first = std::min (first, key.mTime);
|
||||||
last = std::max (last, key.mTime);
|
last = std::max (last, key.mTime);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue