16 #ifndef SURGSIM_BLOCKS_TRANSFERPHYSICSTOPOINTCLOUDBEHAVIOR_H
17 #define SURGSIM_BLOCKS_TRANSFERPHYSICSTOPOINTCLOUDBEHAVIOR_H
32 class PointCloudRepresentation;
37 class DeformableRepresentation;
56 void setSource(
const std::shared_ptr<SurgSim::Framework::Component>& source);
60 void setTarget(
const std::shared_ptr<SurgSim::Framework::Component>& target);
64 std::shared_ptr<SurgSim::Physics::DeformableRepresentation>
getSource()
const;
68 std::shared_ptr<SurgSim::Graphics::PointCloudRepresentation>
getTarget()
const;
70 virtual void update(
double dt)
override;
77 std::shared_ptr<SurgSim::Physics::DeformableRepresentation>
m_source;
80 std::shared_ptr<SurgSim::Graphics::PointCloudRepresentation>
m_target;
86 #endif // SURGSIM_BLOCKS_TRANSFERPHYSICSTOPOINTCLOUDBEHAVIOR_H
void setSource(const std::shared_ptr< SurgSim::Framework::Component > &source)
Set the representation from which the positions are from.
Definition: TransferPhysicsToPointCloudBehavior.cpp:45
Definition: DriveElementFromInputBehavior.cpp:27
std::shared_ptr< SurgSim::Physics::DeformableRepresentation > getSource() const
Get the Physics representation which sends the positions.
Definition: TransferPhysicsToPointCloudBehavior.cpp:65
std::shared_ptr< SurgSim::Graphics::PointCloudRepresentation > m_target
The Graphics PointCloud Representation to which the vertices' positions are set.
Definition: TransferPhysicsToPointCloudBehavior.h:80
TransferPhysicsToPointCloudBehavior(const std::string &name)
Constructor.
Definition: TransferPhysicsToPointCloudBehavior.cpp:36
virtual bool doWakeUp() override
Interface to be implemented by derived classes.
Definition: TransferPhysicsToPointCloudBehavior.cpp:91
void setTarget(const std::shared_ptr< SurgSim::Framework::Component > &target)
Set the point cloud representation which will receive the positions.
Definition: TransferPhysicsToPointCloudBehavior.cpp:55
std::shared_ptr< SurgSim::Graphics::PointCloudRepresentation > getTarget() const
Get the point cloud representation which receives the positions.
Definition: TransferPhysicsToPointCloudBehavior.cpp:70
Behavior to copy positions of a PhysicsRepresentation to a PointCloud.
Definition: TransferPhysicsToPointCloudBehavior.h:45
Behaviors perform actions.
Definition: Behavior.h:40
virtual void update(double dt) override
Update the behavior.
Definition: TransferPhysicsToPointCloudBehavior.cpp:75
SURGSIM_CLASSNAME(SurgSim::Blocks::TransferPhysicsToPointCloudBehavior)
std::shared_ptr< SurgSim::Physics::DeformableRepresentation > m_source
The DeformableRepresentation from which the Ode state comes.
Definition: TransferPhysicsToPointCloudBehavior.h:77
virtual bool doInitialize() override
Interface to be implemented by derived classes.
Definition: TransferPhysicsToPointCloudBehavior.cpp:86
SURGSIM_STATIC_REGISTRATION(DriveElementFromInputBehavior)