#include "X3D_Transform.h" #include using namespace std; namespace X3DTK { namespace X3D { Transform::Transform() : X3DGroupingNode(), X3DBoundedObject() { define(Recorder::getTypeName("Transform", "Grouping")); define(Recorder::getAttribute("center", &Transform::_center, SFVec3f(0.0f, 0.0f, 0.0f))); define(Recorder::getAttribute("rotation", &Transform::_rotation, SFRotation(0.0f, 0.0f, 1.0f, 0.0f))); define(Recorder::getAttribute("scale", &Transform::_scale, SFVec3f(1.0f, 1.0f, 1.0f))); define(Recorder::getAttribute("scaleOrientation", &Transform::_scaleOrientation, SFRotation(0.0f, 0.0f, 1.0f, 0.0f))); define(Recorder::getAttribute("translation", &Transform::_translation, SFVec3f(0.0f, 0.0f, 0.0f))); } Transform::~Transform() { } void Transform::setCenter(const SFVec3f ¢er) { _center = center; } void Transform::setRotation(const SFRotation &rotation) { _rotation = rotation; } void Transform::setScale(const SFVec3f &scale) { _scale = scale; } void Transform::setScaleOrientation(const SFRotation &scaleOrientation) { _scaleOrientation = scaleOrientation; } void Transform::setTranslation(const SFVec3f &translation) { _translation = translation; } } }