AGXDynamics  2.35.0.2
WireSandbox.h
Go to the documentation of this file.
1 /*
2 Copyright 2007-2022. Algoryx Simulation AB.
3 
4 All AGX source code, intellectual property, documentation, sample code,
5 tutorials, scene files and technical white papers, are copyrighted, proprietary
6 and confidential material of Algoryx Simulation AB. You may not download, read,
7 store, distribute, publish, copy or otherwise disseminate, use or expose this
8 material unless having a written signed agreement with Algoryx Simulation AB, or having been
9 advised so by Algoryx Simulation AB for a time limited evaluation, or having purchased a
10 valid commercial license from Algoryx Simulation AB.
11 
12 Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
13 from using this software, unless otherwise stated in written agreements with
14 Algoryx Simulation AB.
15 */
16 
17 #pragma once
18 
19 #include <agxWire/Wire.h>
20 
21 
23 
24 namespace agxWire
25 {
27  class AGXPHYSICS_EXPORT WireSandbox : public agxWire::Wire
28  {
29  public:
30  enum Mode
31  {
32  WIRE_WIRE = (1<<0),
33  NEW_CONTACT_HANDLING = (1<<1),
34  DEFAULT_MODE = WIRE_WIRE | NEW_CONTACT_HANDLING
35  };
36 
37  WireSandbox( agx::Real radius, agx::Real resolutionPerUnitLength, Mode mode = DEFAULT_MODE );
38 
43  virtual Wire* clone();
44 
45  protected:
46  virtual ~WireSandbox();
47 
48  virtual void addNotification();
49  virtual void removeNotification();
50 
51  virtual void preCollide( const agx::TimeStamp& );
52  virtual void pre( const agx::TimeStamp& );
53 
54  private:
58 
59  protected:
60  Mode m_mode;
61  };
62 
63  typedef agx::ref_ptr< WireSandbox > WireSandboxRef;
64 
65 }
66 
agx::Real
double Real
Definition: Real.h:42
DOXYGEN_END_INTERNAL_BLOCK
#define DOXYGEN_END_INTERNAL_BLOCK()
Definition: macros.h:97
Wire.h
agxWire::Wire::addNotification
virtual void addNotification() override
Called when this wire is added to a simulation, if this wire hasn't been initialized before this call...
DOXYGEN_START_INTERNAL_BLOCK
#define DOXYGEN_START_INTERNAL_BLOCK()
Definition: macros.h:96
agxWire::Wire::removeNotification
virtual void removeNotification() override
Called when this wire is removed from the simulation.
agxWire::Wire
Interface and placeholder of controllers/helpers for wires.
Definition: Wire.h:61
AGXPHYSICS_EXPORT
#define AGXPHYSICS_EXPORT
agxWire::Wire::pre
virtual void pre(const agx::TimeStamp &t) override
Run stability update.
agx::ref_ptr
Smart pointer for handling referenced counted objects.
Definition: ref_ptr.h:29
agxWire
Implements a Wire model with adaptive resolution.
Definition: MergedBody.h:39
agxWire::Wire::preCollide
virtual void preCollide(const agx::TimeStamp &) override
Update geometries.
agx::TimeStamp
agx::Real TimeStamp
Definition: TimeStamp.h:26
agxWire::Wire::clone
virtual agxWire::Wire * clone(agxWire::Wire *newWire=nullptr)
Clone this wire object and return an empty, uninitialized wire.