16 #ifndef SURGSIM_BLOCKS_VISUALIZECONSTRAINTS_H 17 #define SURGSIM_BLOCKS_VISUALIZECONSTRAINTS_H 19 #include "SurgSim/Framework/BasicSceneElement.h" 20 #include "SurgSim/Framework/Behavior.h" 21 #include "SurgSim/Physics/PhysicsManagerState.h" 38 class VectorFieldRepresentation;
43 SURGSIM_STATIC_REGISTRATION(VisualizeConstraintsBehavior);
58 void setVectorField(Physics::ConstraintGroupType constraintType,
59 const std::shared_ptr<Framework::Component>& vectorField);
61 typedef std::vector<std::pair<int, std::shared_ptr<Framework::Component>>> FieldsType;
65 void setVectorFields(
const FieldsType& fields);
68 FieldsType getVectorFields()
const;
70 void update(
double dt)
override;
72 int getTargetManagerType()
const override;
77 bool doInitialize()
override;
79 bool doWakeUp()
override;
82 std::weak_ptr<SurgSim::Physics::PhysicsManager> m_manager;
84 std::map<SurgSim::Physics::ConstraintGroupType, std::shared_ptr<SurgSim::Graphics::VectorFieldRepresentation>>
87 boost::mutex m_graphicsMutex;
89 std::shared_ptr<SurgSim::Framework::Logger> m_logger;
103 #endif // SURGSIM_BLOCKS_VISUALIZECONSTRAINTS_H Wraps glewInit() to separate the glew opengl definitions from the osg opengl definitions only imgui n...
Definition: AddRandomSphereBehavior.cpp:36
SceneElement that generates the VisualizeConstraintBehavior and the appropriate graphics Vectorfield...
Definition: VisualizeConstraints.h:93
Behavior to visualize information about the constraints as they are in the physics manager this will ...
Definition: VisualizeConstraints.h:48
Simple concrete implementation of a scene element that does not have any higher logic.
Definition: BasicSceneElement.h:29
Behaviors perform actions.
Definition: Behavior.h:40