AGX Dynamics 2.41.2.0
Loading...
Searching...
No Matches
Wire.h
Go to the documentation of this file.
1/*
2Copyright 2007-2025. Algoryx Simulation AB.
3
4All AGX source code, intellectual property, documentation, sample code,
5tutorials, scene files and technical white papers, are copyrighted, proprietary
6and confidential material of Algoryx Simulation AB. You may not download, read,
7store, distribute, publish, copy or otherwise disseminate, use or expose this
8material unless having a written signed agreement with Algoryx Simulation AB, or having been
9advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10valid commercial license from Algoryx Simulation AB.
11
12Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13from using this software, unless otherwise stated in written agreements with
14Algoryx Simulation AB.
15*/
16
17#pragma once
18
20
30
33
34#include <agx/ICloneable.h>
35
36namespace agxUtil
37{
38 class SmoothingFilter;
39}
40
41namespace agx
42{
43 class SolveIslandSplitAlgorithm;
44
45 namespace Physics
46 {
47 class GraphNodeData;
48 }
49}
50
52namespace agxWire
53{
54 class Winch;
57
61 class AGXPHYSICS_EXPORT Wire : public SimulationProxyT< agxSDK::StepEventListener >
62 {
63 public:
64 typedef SimulationProxyT< agxSDK::StepEventListener > base;
65
66 public:
71 {
73 TensionData( agx::Real rawTension, agx::Real smoothedTension );
74 TensionData( const agxWire::Node::Tension* tension );
75
78 };
79
80 public:
81
83
89
95
101
107
112 static const agxWire::Wire* getWire( const agx::RigidBody* rb );
113
119
124 static const agxWire::Wire* getWire( const agxCollide::Geometry* geometry );
125
132 static agxWire::Wire* find( agxSDK::Simulation* simulation, const agx::Name& name );
133
140 static agxWire::Wire* find( agxSDK::Simulation* simulation, const agx::Uuid& uuid );
141
148
155 static agxWire::WirePtrVector findAll( const agxSDK::Simulation* simulation, const agx::Name& name );
156
157 public:
164 Wire( agx::Real radius, agx::Real resolutionPerUnitLength, bool enableCollisions = true );
165
171 virtual agxWire::Wire* clone( agxWire::Wire* newWire = nullptr );
172
179 virtual bool add( agxWire::Node* node );
180
187 virtual bool add( agxWire::WireWinchController* winchController );
188
196 virtual bool add( agxWire::WireWinchController* winchController, agx::Real pulledInLength );
197
206 virtual bool add( agxWire::Link* link, bool updateConnectionType = true );
207
218 virtual bool add( agxWire::Link* link, const agx::Vec3& relativeTranslate );
219
225 virtual bool remove( agxWire::Node* node );
226
233 virtual bool remove( agxWire::WireWinchController* winchController );
234
245 bool insert( agxWire::Node* node, agx::Real distanceFromStart, bool includeWinchPulledInLength = true );
246
254 bool insert( agxWire::Node* node, const agx::Vec3& worldPoint );
255
260 bool reverse();
261
272 bool merge( agxWire::WireRef other );
273
283 agxWire::WireRef cut(agx::Real distanceAlongWire, size_t minimumResolution, bool includeWinchPulledInLength = true);
284
293 agxWire::WireRef cut( const agx::Vec3& worldPoint, size_t minimumResolution );
294
304 virtual bool attach( agxWire::Node* node, bool begin );
305
313 virtual bool attach( agxWire::WireWinchController* winchController, bool begin );
314
320 virtual bool detach( bool begin );
321
326 const agxWire::WireAttachmentController* getBeginAttachment() const;
327
332 const agxWire::WireAttachmentController* getEndAttachment() const;
333
337 bool initialized() const;
338
344 void setInitializationController( agxWire::WireInitializationController* initializationController );
345
355 bool setRouteController( agxWire::WireRouteController* routeController, bool copyCurrentRouteToNew = false );
356
360 agxWire::WireRouteController* getRouteController() const;
361
365 agxWire::WireParameterController* getParameterController() const;
366
370 agxWire::WireStabilityController* getStabilityController() const;
371
375 agxWire::WireMaterialController* getMaterialController() const;
376
380 agxWire::WireGeometryController* getGeometryController() const;
381
385 agxWire::WireContactController* getActiveContactController() const;
386
393 virtual agx::Real getRestLength( bool includeWinches = true ) const;
394
405 agx::Real getRestLength( const agxWire::Node* node1, const agxWire::Node* node2 ) const;
406
417 agx::Real findRestLength( bool includeWinches = true ) const;
418
425 agx::Real getCurrentLength( bool includeWinches = true ) const;
426
435 agx::Real getCurrentLength( const agxWire::Node* node1, const agxWire::Node* node2 ) const;
436
443 agx::Real scaleToRestlength( agx::Real currentLength, const agxWire::Node* node ) const;
444
451
458 agx::Real scaleToCurrentlength( agx::Real restLength, const agxWire::Node* node ) const;
459
466
472
477
478
485
492
496 bool getRenderListEmpty() const;
497
504 agx::Real findRestLengthFromStart( const agx::Vec3& point, bool includeWinchesPulledInLength = true ) const;
505
513 agx::Vec3 findPoint( agx::Real distanceFromStart ) const;
514
525 agx::Vec3 findPoint( agx::Real distanceFromStart, bool includesWinchesPulledInLength ) const;
526
532 agx::Vec3 findPoint( const agx::Vec3& point ) const;
533
541
550
555
560
565 virtual void setMaterial( agx::Material* material );
566
571 void setIsBendResistent( bool isBendResistant );
572
578
580 agx::PropertyContainer* getPropertyContainer();
581
583 const agx::PropertyContainer* getPropertyContainer() const;
584
586 bool hasPropertyContainer() const;
587
592
597
602 virtual void setRadius( agx::Real radius );
603
611 void setResolutionPerUnitLength( agx::Real resolutionPerUnitLength );
612
617
624 void setEnableCollisions( agxCollide::Geometry* geometry, bool enable, bool forceContactUpdate = false );
625
631 void setEnableCollisions( agx::RigidBody* rb, bool enable );
632
637 void setEnableCollisions( bool enable );
638
644 void setActiveContactControllerType(const WireContactControllerType type);
645 WireContactControllerType getActiveContactControllerType() const;
646
651
655 bool getEnableCollisions( const agxCollide::Geometry* geometry ) const;
656
660 bool getEnableCollisions( const agx::RigidBody* rb ) const;
661
665 static void setEnableGroupWireCollision(agxCollide::Space* space,const agx::UInt32 group, bool enable);
666
673 void setEnableSplitting( bool splitting );
674
678 bool getEnableSplitting() const;
679
684 void addGroup( uint32_t id );
685
690 void addGroup( const agx::Name& name );
691
695 bool hasGroup( const uint32_t id ) const;
696
700 bool hasGroup( const agx::Name& name ) const;
701
706 void removeGroup( uint32_t id );
707
712 void removeGroup( const agx::Name& name );
713
717 bool hasGeometry( const agxCollide::Geometry* geometry ) const;
718
722 bool hasNode( const agxWire::Node* node ) const;
723
728
733
737 agxWire::WireDistanceCompositeConstraint* getConstraint() const;
738
744
749
754
760
764 void setFrame( agx::Frame* frame );
765
771 void setLinearVelocityDamping( agx::Real linearVelocityDamping );
772
777
781 bool hasContactNodesOn( const agx::RigidBody* rb ) const;
782
786 bool hasContactNodesOn( const agxCollide::Geometry* geometry ) const;
787
796 bool replaceBodyInNodes( agx::RigidBody* currentBody, agx::RigidBody* newBody, agxCollide::Geometry* geometry = nullptr );
797
813 bool changeRigidBody( agxWire::Node* node, agx::RigidBody* newRigidBody ) const;
814
819 void setSmoothedTension( agx::Real newSmoothedTension );
820
828
835
840
844 virtual void preCollide( const agx::TimeStamp& ) override;
845
849 virtual void pre( const agx::TimeStamp& t ) override;
850
854 virtual void post( const agx::TimeStamp& t ) override;
855
860 bool simplify( const agx::Frame* parentFrame = nullptr );
861
867
871 bool isSimplified() const;
872
876 agxWire::WireSimplifyController* getSimplifyController() const;
877
882
887
896 bool shorten( const agxWire::Node* toNode, bool fromBegin );
897
902
904
905
909 void uninitializeConstraint();
910
917 bool isStatic() const;
918
922 agx::UInt getNumNodes() const;
923
934 bool explicitReplaceWinchController( agxWire::ConnectingNode* connectingNode, bool begin );
935
940 void onCreateMergeSplitProperties();
941
946 agxWire::WirePropertyController* getPropertyController() const;
947
950
951 protected:
956
960 virtual ~Wire();
961
966 virtual void addNotification() override;
967 using SimulationProxyT< agxSDK::StepEventListener >::addNotification;
968
972 virtual void removeNotification() override;
973 using SimulationProxyT< agxSDK::StepEventListener >::removeNotification;
974
978 void updateMaterial();
979
983#ifndef SWIG
985#endif
986
987 friend class agxWire::Winch;
993 virtual void setWinchController( agxWire::WireWinchController* winchController, bool begin );
994
999 agxWire::WireAttachmentController* getBeginAttachment();
1000
1005 agxWire::WireAttachmentController* getEndAttachment();
1006
1007 protected:
1008 WireDistanceCompositeConstraintRef m_constraint;
1009
1010 // Controllers
1011 WireRouteControllerRef m_routeController;
1012 WireInitializationControllerRef m_initializationController;
1015 WireMaterialControllerRef m_materialController;
1016 WireStabilityControllerRef m_stabilityController;
1017 WireGeometryControllerRef m_geometryController;
1018 WireFrictionControllerRef m_frictionController;
1019 WireSimplifyControllerRef m_simplifyController;
1020
1027
1032
1033 private:
1035 friend class agx::InternalData;
1040 agx::Referenced* getInternalData() const;
1041
1046 void setInternalData( agx::Referenced* data );
1048 };
1049
1050 // Inline methods *******************************************************************************************
1051
1052 inline bool Wire::initialized() const
1053 {
1054 return m_initialized;
1055 }
1056
1057 inline WireParameterController* Wire::getParameterController() const
1058 {
1059 return const_cast< WireParameterController* >( &m_parameterController );
1060 }
1061
1062 inline WireRouteController* Wire::getRouteController() const
1063 {
1064 return m_routeController;
1065 }
1066
1067 inline WireStabilityController* Wire::getStabilityController() const
1068 {
1069 return m_stabilityController;
1070 }
1071
1072 inline WireMaterialController* Wire::getMaterialController() const
1073 {
1074 return m_materialController;
1075 }
1076
1077 inline WireGeometryController* Wire::getGeometryController() const
1078 {
1079 return m_geometryController;
1080 }
1081
1082 inline WireDistanceCompositeConstraint* Wire::getConstraint() const
1083 {
1084 return m_constraint;
1085 }
1086
1087 inline agx::Referenced* Wire::getInternalData() const
1088 {
1089 return m_internalData;
1090 }
1091
1092 AGX_FORCE_INLINE agx::PropertyContainer* Wire::getPropertyContainer()
1093 {
1094 if (!m_propertyContainer)
1095 m_propertyContainer = new agx::PropertyContainer;
1096 return m_propertyContainer;
1097 }
1098
1099 AGX_FORCE_INLINE bool Wire::hasPropertyContainer() const
1100 {
1101 return (m_propertyContainer.isValid());
1102 }
1103
1104 AGX_FORCE_INLINE const agx::PropertyContainer* Wire::getPropertyContainer() const
1105 {
1106 if (!m_propertyContainer)
1107 m_propertyContainer = new agx::PropertyContainer;
1108
1109 return m_propertyContainer;
1110 }
1111
1112 // **********************************************************************************************************
1113
1114 // Static utility functions *********************************************************************************
1121 // **********************************************************************************************************
1122}
1123
#define AGX_DECLARE_POINTER_TYPES(type)
Definition: Referenced.h:254
#define AGXSTREAM_DECLARE_SERIALIZABLE(T)
Use this in a Serializable class to add the required methods Important: Use full namespace in the dec...
Definition: Serializable.h:208
#define AGXPHYSICS_EXPORT
#define AGX_DECLARE_VECTOR_TYPES(type)
Definition: agx/Vector.h:34
The geometry representation used by the collision detection engine.
Definition: Geometry.h:92
This class contains all Geometries and performs Broad Phase and Narrow Phase collision detection to c...
Definition: Space.h:86
Type
Type of EventListener.
Definition: EventListener.h:44
Simulation is a class that bridges the collision space agxCollide::Space and the dynamic simulation s...
Definition: Simulation.h:131
The body fixed node is attached to a body at a given offset.
Connecting nodes contains two nodes, one at center of mass and the other at the user defined position...
Class defining a node that is part of a wire.
Definition: agxWire/Node.h:512
Proxy class for wire iterators.
Winch object which works like agxWire::WireWinchController but enables the features of having stored,...
Definition: Winch.h:31
Class to hold specific parameters for the wire - this makes the wires highly configurable.
Winch class for handling in and out hauling of wires.
Interface and placeholder of controllers/helpers for wires.
Definition: Wire.h:62
static agxWire::Wire * getWire(agxCollide::Geometry *geometry)
agx::Real scaleToRestlength(agx::Real currentLength, const agxWire::Node *node) const
Scale current length in world coordinates to rest length.
virtual bool remove(agxWire::Node *node)
Remove node from this wire.
const agxWire::WireAttachmentController * getBeginAttachment() const
Return pointer to the attachment controller used at begin of the wire constraint.
bool hasGroup(const uint32_t id) const
Find if wire geometries contains group.
agx::FrameRef m_frame
Definition: Wire.h:1023
WireFrictionControllerRef m_frictionController
Definition: Wire.h:1018
agx::Real getRadiusIncludingContactNodeOffsetDistanceMultiplier() const
static agxWire::Wire * find(agxSDK::Simulation *simulation, const agx::Uuid &uuid)
Find wire instance given simulation and unique id.
agx::Material * getMaterial() const
WireInitializationControllerRef m_initializationController
Definition: Wire.h:1012
agx::Vec3 findPoint(agx::Real distanceFromStart) const
Returns a point on this wire distanceFromStart meters from the beginning of this wire.
void setResolutionPerUnitLength(agx::Real resolutionPerUnitLength)
Assign new resolution per unit length.
bool m_splitEnabled
Definition: Wire.h:1025
bool merge(agxWire::WireRef other)
Merge this wire with other wire.
agx::Real getContactNodeMomentum() const
static agxWire::Wire * getWire(agx::RigidBody *rb)
virtual void post(const agx::TimeStamp &t) override
Clean up after splitting.
agx::Frame * getFrame() const
This wire has a frame which is the parent frame of all internal bodies.
static const agxWire::Wire * getWire(const agx::RigidBody *rb)
void setSolveType(agx::Constraint::SolveType solveType)
Set solve type, either DIRECT, ITERATIVE or DIRECT_AND_ITERATIVE.
bool setRouteController(agxWire::WireRouteController *routeController, bool copyCurrentRouteToNew=false)
Associate new, own implemented, route controller to this wire.
agx::Real getCurrentLength(const agxWire::Node *node1, const agxWire::Node *node2) const
Calculates the current length between node1 and node2 in wire coordinates.
bool getEnableCollisions(const agx::RigidBody *rb) const
agx::Vec3 findPoint(const agx::Vec3 &point) const
Given any point in 3D, this method will find a point on this wire which is closest to the given point...
agxWire::WireAttachmentController * getEndAttachment()
Return pointer to the attachment controller used at end of the wire constraint.
agx::Real getRadius() const
bool hasContactNodesOn(const agxCollide::Geometry *geometry) const
bool getEnableCollisions() const
void addGroup(const agx::Name &name)
Add group for all geometries handled by this collision controller.
bool getRenderListEmpty() const
agx::Constraint::SolveType m_solveType
Definition: Wire.h:1026
static const agxWire::Wire * getWire(const agxCollide::Geometry *geometry)
agxWire::WireSegmentTensionData getTension(const agx::Vec3 &point) const
Given any point in 3D, this method will find a point on this wire which is closest to the given point...
void setActiveContactControllerType(const WireContactControllerType type)
Choose the type of WireContactController to use Default is the WireShapeContactController.
agx::Real getResolutionPerUnitLength() const
bool simplify(const agx::Frame *parentFrame=nullptr)
Simplify this wire.
void getGeometries(agxCollide::GeometryPtrVector &geoms) const
Fills geoms with all geometries used by this wire.
agxWire::WireRef cut(agx::Real distanceAlongWire, size_t minimumResolution, bool includeWinchPulledInLength=true)
Cut this wire given distance from start (including winches).
static const agxWire::BodyFixedNode * getLumpedNode(const agx::RigidBody *rb)
void setEnableCollisions(agxCollide::Geometry *geometry, bool enable, bool forceContactUpdate=false)
Enable or disable collisions between a geometry and this wire.
bool hasGeometry(const agxCollide::Geometry *geometry) const
agx::Real getCurrentLength(bool includeWinches=true) const
Calculates the current length of this wire (stretched/compressed included).
agx::ref_ptr< agx::Referenced > m_propertyController
Definition: Wire.h:1030
agx::Real getMass() const
bool insert(agxWire::Node *node, agx::Real distanceFromStart, bool includeWinchPulledInLength=true)
Insert a node in this given distance along this wire.
static void setEnableGroupWireCollision(agxCollide::Space *space, const agx::UInt32 group, bool enable)
Enable/Disable a group (unique group id) against all wires.
agxWire::RenderIterator getRenderBeginIterator() const
agxWire::Node * getLastNode() const
virtual bool attach(agxWire::WireWinchController *winchController, bool begin)
Attach a winch to a free end of this wire.
virtual bool remove(agxWire::WireWinchController *winchController)
Remove winch from this wire.
void removeGeometries()
Removes all geometries.
const agxWire::WireAttachmentController * getEndAttachment() const
Return pointer to the attachment controller used at end of the wire constraint.
WireDistanceCompositeConstraintRef m_constraint
Definition: Wire.h:1008
virtual void setWinchController(agxWire::WireWinchController *winchController, bool begin)
Assign new winch controller to this wire.
void setFrame(agx::Frame *frame)
Assign new parent frame to this wire.
virtual void preCollide(const agx::TimeStamp &) override
Update geometries.
agx::PropertyContainerRef m_propertyContainer
Definition: Wire.h:1031
virtual void pre(const agx::TimeStamp &t) override
Run stability update.
void setIsBendResistent(bool isBendResistant)
This determines if the wire should have a bend constraint or not.
void addGroup(uint32_t id)
Add group for all geometries handled by this collision controller.
bool getEnableSplitting() const
bool isSimplified() const
void setEnableCollisions(agx::RigidBody *rb, bool enable)
Enable or disable collisions between all geometries in a rigid body and this wire.
WireMaterialControllerRef m_materialController
Definition: Wire.h:1015
agx::Real scaleToCurrentlength(agx::Real restLength, const agxWire::Node *node) const
Scale rest length to current length.
bool hasContactNodesOn(const agx::RigidBody *rb) const
void setSmoothedTension(agx::Real newSmoothedTension, agxWire::NodeIterator from, agxWire::NodeIterator to)
Assign smoothed tension (can be useful after certain events, like cut) to part of this wire.
bool reverse()
Reverse this wire - use to match merge where first wire end is connected to second wire begin.
bool hasNode(const agxWire::Node *node) const
void setEnableCollisions(bool enable)
Enable or disable this wire collision handling (i.e., if false, this wire will only contain bodies an...
virtual bool add(agxWire::Node *node)
Add node to this wire.
void setEnableSplitting(bool splitting)
enable/disable the ability to automatically split the wire at a body fixed node.
void setSmoothingFilter(agxUtil::SmoothingFilter *filter)
Assign filter that will be used to filter out the tension values for smoothed tension readings.
bool insert(agxWire::Node *node, const agx::Vec3 &worldPoint)
Insert a node given a point in world coordinate system.
agxWire::Node * getFirstNode() const
void setLinearVelocityDamping(agx::Real linearVelocityDamping)
Assigns linear velocity damping to all lumped nodes (i.e., rigid bodies owned by this wire) in this w...
void updateNodeTransforms()
Updates all node transforms.
virtual bool attach(agxWire::Node *node, bool begin)
Attach this wire to a new object given new begin or end node and at which end.
agxWire::WireSegmentTensionData getTension(agx::Real distanceFromStart) const
Returns the current tension in a point given distance from start of this wire.
agx::Real getRestLength(const agxWire::Node *node1, const agxWire::Node *node2) const
Calculates the rest length between two nodes (node1 and node2).
virtual bool add(agxWire::WireWinchController *winchController)
Add winch to this wire.
virtual agx::Real getRestLength(bool includeWinches=true) const
Calculates the rest length of this wire.
agx::Real findRestLengthFromStart(const agx::Vec3 &point, bool includeWinchesPulledInLength=true) const
Given any point in 3D, this method will find the distance along this wire which is closest to the giv...
virtual bool add(agxWire::WireWinchController *winchController, agx::Real pulledInLength)
Add winch to this wire.
void setPropertyContainer(agx::PropertyContainer *propertyContainer)
Property container for all rigid bodies and geometries that are owned by this wire.
virtual bool detach(bool begin)
Detach begin or end of this wire (if attached to something).
virtual bool add(agxWire::Link *link, bool updateConnectionType=true)
Add link to the route.
agxWire::WireContactController * getActiveContactController() const
virtual void setRadius(agx::Real radius)
Set the radius of this wire.
agx::Real findRestLength(bool includeWinches=true) const
Extended functionality, compared to getRestLength, to find rest length of this wire in a agxWire::Win...
agxWire::WireNodeTensionData getTension(const agxWire::Node *node) const
WireRouteControllerRef m_routeController
Definition: Wire.h:1011
agx::ref_ptr< agx::Referenced > m_splitAlgorithm
Definition: Wire.h:1028
agx::Real getCurrentLengthScaler(const agxWire::Node *node) const
Given node on this wire, calculates the transform from rest length to current length.
virtual bool add(agxWire::Link *link, const agx::Vec3 &relativeTranslate)
Add link to the route.
WireWinchControllerRefVector m_winchControllers
Winch controller vector, always of size 2, default both 0.
Definition: Wire.h:1014
bool hasGroup(const agx::Name &name) const
Find if wire geometries contains group.
WireStabilityControllerRef m_stabilityController
Definition: Wire.h:1016
agxWire::WireAttachmentController * getBeginAttachment()
Return pointer to the attachment controller used at begin of the wire constraint.
void setInitializationController(agxWire::WireInitializationController *initializationController)
Assign initialization controller for this wire.
bool shorten(const agxWire::Node *toNode, bool fromBegin)
Shorten this wire to a given node.
agxWire::WireWinchController * getWinchController(size_t i) const
const agxUtil::SmoothingFilter * getSmoothingFilter() const
static agx::Bool isLumpedNode(const agx::RigidBody *rb)
WireSimplifyControllerRef m_simplifyController
Definition: Wire.h:1019
agx::SolveIslandSplitAlgorithm * getSplitAlgorithm() const
Get pointer to solve algorithm.
bool changeRigidBody(agxWire::Node *node, agx::RigidBody *newRigidBody) const
Utility method to change rigid body in any node, given it has a valid node type.
void setSmoothedTension(agx::Real newSmoothedTension)
Assign smoothed tension (can be useful after certain events, like cut) to this wire.
WireGeometryControllerRef m_geometryController
Definition: Wire.h:1017
agxUtil::SmoothingFilterRef m_smoothingFilter
Definition: Wire.h:1021
static agxWire::BodyFixedNode * getLumpedNode(agx::RigidBody *rb)
agx::ref_ptr< agx::Referenced > m_internalData
Definition: Wire.h:1029
void removeGroup(uint32_t id)
Remove group for all geometries handled by this collision controller.
bool replaceBodyInNodes(agx::RigidBody *currentBody, agx::RigidBody *newBody, agxCollide::Geometry *geometry=nullptr)
Given currentBody, go through all bodies related to this Wire and replace them with newBody.
WireParameterController m_parameterController
Definition: Wire.h:1013
agxWire::RenderIterator getRenderEndIterator() const
agx::Real getRestLengthScaler(const agxWire::Node *node) const
Given node on this wire, calculates the transform from current length to rest length.
agxWire::WireSimplifyController * getSimplifyController() const
agxSDK::EventListener::Type getType() const
Hide eventListenerType getType()
bool unsimplify()
Unsimplify this wire.
virtual agxWire::Wire * clone(agxWire::Wire *newWire=nullptr)
Clone this wire object and return an empty, uninitialized wire.
static agxWire::Wire * find(agxSDK::Simulation *simulation, const agx::Name &name)
Find wire instance given simulation and name.
WireContactControllerType getActiveContactControllerType() const
static agxWire::WirePtrVector findAll(const agxSDK::Simulation *simulation)
Finds all agxWire::Wire instances in the given simulation.
agx::Real m_linearVelocityDamping
Only linear velocity damping as real is defined for lumped nodes.
Definition: Wire.h:1024
virtual void setMaterial(agx::Material *material)
Sets the material for this wire.
agx::Real getLinearVelocityDamping() const
Wire(agx::Real radius, agx::Real resolutionPerUnitLength, bool enableCollisions=true)
Constructor given the basic parameters to create a wire.
static agxWire::WirePtrVector findAll(const agxSDK::Simulation *simulation, const agx::Name &name)
Finds all wire instances given simulation and name.
SimulationProxyT< agxSDK::StepEventListener > base
Definition: Wire.h:64
void removeGroup(const agx::Name &name)
Remove group for all geometries handled by this collision controller.
void replaceContactNodesWithShapeContacts()
Replace all contact nodes with shape contact nodes.
bool m_initialized
Definition: Wire.h:1022
agxWire::WireRef cut(const agx::Vec3 &worldPoint, size_t minimumResolution)
Cut this wire given any point in world.
agx::Vec3 findPoint(agx::Real distanceFromStart, bool includesWinchesPulledInLength) const
Returns a point on this wire distanceFromStart meters from the beginning of this wire.
bool getEnableCollisions(const agxCollide::Geometry *geometry) const
SolveType
Specifies in what solvers the constraint will be solved.
Definition: Constraint.h:93
The object defining a frame of reference and providing transformations operations.
Definition: agx/Frame.h:68
Main material class which acts as a holder of a Surface Material and a Bulk material.
Definition: Material.h:376
Representation of a name string.
Definition: Name.h:33
Class that is a container of named properties.
Definition: Property.h:129
Base class providing referencing counted objects.
Definition: Referenced.h:120
The rigid body class, combining a geometric model and a frame of reference.
Definition: RigidBody.h:52
The rigid body class, combining a geometric model and a frame of reference.
A UUID, or Universally unique identifier, is intended to uniquely identify information in a distribut...
Definition: Uuid.h:42
Vector containing 'raw' data.
Definition: agx/Vector.h:246
bool isValid() const
Definition: ref_ptr.h:268
#define DOXYGEN_END_INTERNAL_BLOCK()
Definition: macros.h:89
#define DOXYGEN_START_INTERNAL_BLOCK()
Definition: macros.h:88
#define AGX_FORCE_INLINE
Definition: macros.h:58
The agxSDK namespace contain classes to bridge the collision detection system and the dynamical simul...
Definition: Constraint.h:31
The agxUtil namespace contain classes and methods for utility functionality.
Implements a Wire model with adaptive resolution.
Definition: MergedBody.h:40
AGXPHYSICS_EXPORT void extractNodes(NodePtrVector &nodes, const Wire *wire)
Extracts all the nodes given the render list in the wire.
NodeContainer::iterator NodeIterator
Definition: agxWire/Node.h:54
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
uint32_t UInt32
Definition: Integer.h:32
bool Bool
Definition: Integer.h:40
double Real
Definition: Real.h:42
agx::Real TimeStamp
Definition: TimeStamp.h:26
Structure containing relevant tension data for a node.
Structure containing relevant tension data for a wire element/segment.
Structure containing relevant tension data given one look-up.
Definition: Wire.h:71
TensionData(agx::Real rawTension, agx::Real smoothedTension)
TensionData(const agxWire::Node::Tension *tension)
agx::Real smoothed
Definition: Wire.h:77