AGX Dynamics 2.41.3.2
Loading...
Searching...
No Matches
ElectricMotorConstraint.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
9having been advised so by Algoryx Simulation AB for a time limited evaluation,
10or having purchased a valid 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
18#pragma once
19
20#include <agx/Constraint.h>
22
24
25namespace agxDriveTrain {
33 {
34 public:
40
41 virtual void storeLightData(agxStream::StorageStream& str) const override;
42
43 virtual void restoreLightData(agxStream::StorageStream& str) override;
44
46
47 protected:
49
50 private:
52 agx::TargetSpeedController* m_electricMotorConstraint;
53 agxPowerLine::RotationalDimension* m_rotationalDimension;
54 };
55
56
62 {
63 public:
69
75 void setSpeed(agx::Real speed);
76
82 void setCompliance(agx::Real compliance);
84
85 virtual void render(agxRender::RenderManager* /*canvas*/, float /*scale*/) const override {}
86
88
89 protected:
92 virtual int getNumDOF() const override;
93
94 private:
95 ElectricMotorConstraintImplementation* m_electricMotorConstraint;
96 };
97
99}
100
101
#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
virtual void restoreLightData(agxStream::StorageStream &str) override
ElectricMotorConstraintImplementation(agxPowerLine::RotationalDimensionRef rotationalDimension)
virtual void storeLightData(agxStream::StorageStream &str) const override
ElectricMotorConstraint(agxPowerLine::RotationalDimensionRef rotationalDimension)
virtual void render(agxRender::RenderManager *, float) const override
Inherited method of how to render this constraint into DebugRenderer.
virtual int getNumDOF() const override
void setCompliance(agx::Real compliance)
The rotational has one rotational degree of freedom.
Class for managing the rendering of geometries, shapes, rigid bodies, constraints etc.
Abstract base class for storing/restoring a line/drums with version control.
Definition: StorageStream.h:49
The base class for a constraint.
Definition: Constraint.h:89
virtual void setCompliance(agx::Real compliance, agx::Int dof)
Set the compliance of this constraint for the i:th DOF.
Elementary secondary constraint to drive something given target speed (translational or rotational).
A library of agxPowerLine components designed to model the various parts of a vehicle drive train.
double Real
Definition: Real.h:42