]> git.mxchange.org Git - simgear.git/commitdiff
Support constant scaling factor
authorfredb <fredb>
Sun, 21 Jan 2007 10:33:34 +0000 (10:33 +0000)
committerfredb <fredb>
Sun, 21 Jan 2007 10:33:34 +0000 (10:33 +0000)
simgear/scene/model/animation.cxx

index 4f33f8ce573c4983eb769da59b099050e20813da..59e6073790554f7c10b2f44646a9a6c4fda30d28 100644 (file)
@@ -1050,9 +1050,9 @@ public:
     if (!_condition || _condition->test()) {
       SGScaleAnimation::Transform* transform;
       transform = static_cast<SGScaleAnimation::Transform*>(node);
-      SGVec3d scale(_animationValue[0]->getValue(),
-                    _animationValue[1]->getValue(),
-                    _animationValue[2]->getValue());
+      SGVec3d scale(_animationValue[0] ? _animationValue[0]->getValue() : 1.0,
+                    _animationValue[1] ? _animationValue[1]->getValue() : 1.0,
+                    _animationValue[2] ? _animationValue[2]->getValue() : 1.0);
       transform->setScaleFactor(scale);
     }
     traverse(node, nv);