AGX Dynamics
2.37.2.0
AngularJointBase.h
Go to the documentation of this file.
1
/*
2
Copyright 2007-2024. 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
#ifndef AGX_ANGULAR_JOINT_BASE_H
18
#define AGX_ANGULAR_JOINT_BASE_H
19
20
#include <
agx/Constraint.h
>
21
22
namespace
agx
23
{
24
typedef
agx::Bool
(*
CreateElementaryConstraintsFunction
)(
class
HighLevelConstraintImplementation
* );
25
31
class
AGXPHYSICS_EXPORT
AngularJointBase
:
public
agx::Constraint
32
{
33
public
:
34
43
AngularJointBase
(
CreateElementaryConstraintsFunction
createFunc,
agx::RigidBody
* rb1,
agx::Frame
* rb1AttachmentFrame,
agx::RigidBody
* rb2 =
nullptr
,
agx::Frame
* rb2AttachmentFrame =
nullptr
);
44
48
agx::Lock1D
* getLock1D(
UInt
dof );
49
53
const
agx::Lock1D
* getLock1D(
UInt
dof )
const
;
54
58
agx::Motor1D
* getMotor1D(
UInt
dof );
59
63
const
agx::Motor1D
* getMotor1D(
UInt
dof )
const
;
64
68
agx::ElectricMotorController
* getElectricMotorController(
UInt
dof );
69
73
const
agx::ElectricMotorController
* getElectricMotorController(
UInt
dof )
const
;
74
78
agx::Range1D
* getRange1D(
UInt
dof );
79
83
const
agx::Range1D
* getRange1D(
UInt
dof )
const
;
84
88
agx::Real
getAngle
(
UInt
dof )
const
;
89
93
agx::Real
getCurrentSpeed(
UInt
dof )
const
;
94
98
virtual
int
getNumDOF()
const override
= 0;
99
112
virtual
UInt
getNumControllerOffset()
const
= 0;
113
117
virtual
int
getNumControllers()
const
= 0;
118
122
agx::Real
getTheta()
const
;
123
127
agx::Real
getPhi()
const
;
128
132
agx::Real
getPsi()
const
;
133
134
AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE
(
agx::AngularJointBase
);
135
136
protected
:
137
AngularJointBase
();
138
AngularJointBase
(
bool
);
139
virtual
~
AngularJointBase
();
140
144
virtual
void
render(
agxRender::RenderManager
* mgr,
float
scale )
const override
;
145
146
protected
:
147
class
AngularJointBaseImplementation*
m_implementation
;
148
};
149
150
typedef
ref_ptr<AngularJointBase>
AngularJointBaseRef
;
151
152
153
154
}
// namespace agx
155
#endif
agx::CreateElementaryConstraintsFunction
agx::Bool(* CreateElementaryConstraintsFunction)(class HighLevelConstraintImplementation *)
Definition:
AngularJointBase.h:24
agx::AngularJointBase::m_implementation
class AngularJointBaseImplementation * m_implementation
Definition:
AngularJointBase.h:147
agx::AngularJointBase
An angular joint is defined by having 2 rotational degrees of freedom.
Definition:
AngularJointBase.h:31
agx::AngularJointBaseRef
ref_ptr< AngularJointBase > AngularJointBaseRef
Definition:
AngularJointBase.h:150
agx::HighLevelConstraintImplementation
Definition:
ConstraintImplementation.h:1028
agx::ElectricMotorController
Implementation of a electric motor controller.
Definition:
ElementaryConstraint.h:939
agx::Bool
bool Bool
Definition:
Integer.h:48
AGXPHYSICS_EXPORT
#define AGXPHYSICS_EXPORT
agx::Constraint
The base class for a constraint.
Definition:
Constraint.h:88
agxRender::RenderManager
Class for managing the rendering of geometries, shapes, rigid bodies, constraints etc...
Definition:
RenderManager.h:106
agx::LockController
Elementary secondary constraint to keep constraint angle at a given target position.
Definition:
ElementaryConstraint.h:1111
agx::UInt
uint32_t UInt
Definition:
Integer.h:34
agx::RangeController
Elementary secondary constraint to keep constraint angle within two given values. ...
Definition:
ElementaryConstraint.h:1031
agx
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Definition:
AddedMassInteraction.h:22
agx::ref_ptr
Smart pointer for handling referenced counted objects.
Definition:
ref_ptr.h:29
Constraint.h
agx::RigidBody
The rigid body class, combining a geometric model and a frame of reference.
Definition:
RigidBody.h:54
agx::Frame
The object defining a frame of reference and providing transformations operations.
Definition:
Frame.h:67
agx::TargetSpeedController
Elementary secondary constraint to drive something given target speed (translational or rotational)...
Definition:
ElementaryConstraint.h:710
AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE
#define AGXSTREAM_DECLARE_ABSTRACT_SERIALIZABLE(T)
Use this in a pure abstract Serializable class to add the required methods Important: Use full namesp...
Definition:
Serializable.h:221
agx::Real
double Real
Definition:
Real.h:42
agx::getAngle
Real getAngle(const Vec3 &a, const Vec3 &b, const Vec3 &c)
a and b should be orthogonal
Definition:
ConstraintImplementation.h:1419
include
agx
AngularJointBase.h
Generated on Sun Jan 28 2024 11:19:11 for AGX Dynamics by
1.8.13