16 #ifndef SURGSIM_PHYSICS_FIXEDREPRESENTATIONLOCALIZATION_H
17 #define SURGSIM_PHYSICS_FIXEDREPRESENTATIONLOCALIZATION_H
46 std::shared_ptr<FixedRepresentation> fixed = std::dynamic_pointer_cast<
FixedRepresentation>(representation);
47 SURGSIM_ASSERT(fixed !=
nullptr) <<
"Unexpected representation type" << std::endl;
88 else if (currentPose.isApprox(previousPose))
105 #endif // SURGSIM_PHYSICS_FIXEDREPRESENTATIONLOCALIZATION_H
SurgSim::Math::Vector3d doCalculatePosition(double time)
Calculates the global position of this localization.
Definition: FixedRepresentationLocalization.h:74
Definitions of quaternion types.
Definition: DriveElementFromInputBehavior.cpp:27
FixedRepresentationLocalization(std::shared_ptr< Representation > representation)
Constructor.
Definition: FixedRepresentationLocalization.h:43
const SurgSim::Math::RigidTransform3d & getPose() const
Get the rigid representation pose.
Definition: RigidRepresentationState.cpp:108
virtual ~FixedRepresentationLocalization()
Destructor.
Definition: FixedRepresentationLocalization.h:51
The FixedRepresentation class represents a physics entity without any motion nor compliance against w...
Definition: FixedRepresentation.h:33
#define SURGSIM_ASSERT(condition)
Assert that condition is true.
Definition: Assert.h:77
std::shared_ptr< Representation > getRepresentation() const
Gets the representation.
Definition: Localization.h:62
Eigen::Quaternion< T, QOpt > interpolate(const Eigen::Quaternion< T, QOpt > &q0, const Eigen::Quaternion< T, QOpt > &q1, T t)
Interpolate (slerp) between 2 quaternions.
Definition: Quaternion.h:149
void setLocalPosition(const SurgSim::Math::Vector3d &p)
Sets the local position.
Definition: FixedRepresentationLocalization.h:57
This class implement the localization on a FixedRepresentation, as a local position.
Definition: FixedRepresentationLocalization.h:32
FixedRepresentationLocalization()
Default constructor.
Definition: FixedRepresentationLocalization.h:36
Eigen::Transform< double, 3, Eigen::Isometry > RigidTransform3d
A 3D rigid (isometric) transform, represented as doubles.
Definition: RigidTransform.h:46
const RigidRepresentationState & getCurrentState() const
Get the current state of the rigid representation.
Definition: RigidRepresentationBase.cpp:111
const SurgSim::Math::Vector3d & getLocalPosition() const
Gets the local position.
Definition: FixedRepresentationLocalization.h:64
This class localize a point on a representation (representation specific)
Definition: Localization.h:33
Eigen::Matrix< double, 3, 1 > Vector3d
A 3D vector of doubles.
Definition: Vector.h:56
SurgSim::Math::Vector3d m_position
3D position in local coordinates
Definition: FixedRepresentationLocalization.h:98