mirror of
https://github.com/JulianGro/overte.git
synced 2025-04-30 23:53:58 +02:00
Fixed Inverse logic and Cleanup
This commit is contained in:
parent
663e8514de
commit
0e3fc64f63
4 changed files with 5 additions and 6 deletions
libraries
entities-renderer/src
entities/src
|
@ -287,7 +287,7 @@ bool RenderableModelEntityItem::getAnimationFrame() {
|
|||
|
||||
auto animation = getAnimation();
|
||||
if (animation && animation->isLoaded()) {
|
||||
|
||||
|
||||
const QVector<FBXAnimationFrame>& frames = animation->getFramesReference(); // NOTE: getFrames() is too heavy
|
||||
auto& fbxJoints = animation->getGeometry().joints;
|
||||
|
||||
|
@ -322,10 +322,10 @@ bool RenderableModelEntityItem::getAnimationFrame() {
|
|||
if (index >= 0) {
|
||||
glm::mat4 translationMat;
|
||||
|
||||
if (allowTranslation){
|
||||
if (!allowTranslation){
|
||||
translationMat = glm::translate(originalFbxJoints[index].translation);
|
||||
}
|
||||
else if (!allowTranslation && index < translations.size()) {
|
||||
else if (allowTranslation && index < translations.size()) {
|
||||
translationMat = glm::translate(translations[index]);
|
||||
}
|
||||
|
||||
|
|
|
@ -206,7 +206,7 @@ bool AnimationPropertyGroup::appendToEditPacket(OctreePacketData* packetData,
|
|||
int& propertyCount,
|
||||
OctreeElement::AppendState& appendState) const {
|
||||
|
||||
bool successPropertyFits = true;
|
||||
bool successPropertyFits = true;
|
||||
|
||||
APPEND_ENTITY_PROPERTY(PROP_ANIMATION_URL, getURL());
|
||||
APPEND_ENTITY_PROPERTY(PROP_ANIMATION_ALLOW_TRANSLATION, getAllowTranslation());
|
||||
|
|
|
@ -156,7 +156,6 @@ int ModelEntityItem::readEntitySubclassDataFromBuffer(const unsigned char* data,
|
|||
READ_ENTITY_PROPERTY(PROP_JOINT_TRANSLATIONS_SET, QVector<bool>, setJointTranslationsSet);
|
||||
READ_ENTITY_PROPERTY(PROP_JOINT_TRANSLATIONS, QVector<glm::vec3>, setJointTranslations);
|
||||
|
||||
|
||||
return bytesRead;
|
||||
}
|
||||
|
||||
|
|
|
@ -152,7 +152,7 @@ protected:
|
|||
bool isAnimatingSomething() const;
|
||||
|
||||
rgbColor _color;
|
||||
QString _modelURL;
|
||||
QString _modelURL;
|
||||
QUrl _parsedModelURL;
|
||||
QString _compoundShapeURL;
|
||||
|
||||
|
|
Loading…
Reference in a new issue