AGX Dynamics 2.42.3.1
Loading...
Searching...
No Matches
TranslationalUnit.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
19#include <agxModel/export.h>
21#include <agxPowerLine/Unit.h>
22
23namespace agxPowerLine
24{
26 {
27 public:
28
33
34
38 virtual agx::Real getDeliveredForce() const {return m_translationalDimension->getOutputLoad();}
39
43 agxPowerLine::TranslationalDimension* getTranslationalDimension() const;
44
46
48
53
54
58 void setMass( agx::Real mass );
59
64
68 virtual bool preUpdate(agx::Real timeStep) override;
72 virtual bool store(agxStream::StorageStream& str) const override;
73
77 virtual bool restore(agxStream::StorageStream& str) override;
78
80
81 protected:
83
84 protected:
85 agxPowerLine::TranslationalDimensionRef m_translationalDimension;
86 };
87
88
90}
#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:207
#define AGXMODEL_EXPORT
virtual bool store(agxStream::StorageStream &str) const override
Stores internal data into stream.
virtual bool preUpdate(agx::Real timeStep) override
Functions that have to be public since they are called by static functions.
virtual agx::Real getDeliveredForce() const
virtual bool restore(agxStream::StorageStream &str) override
Restores internal data from stream.
agxPowerLine::TranslationalDimensionRef m_translationalDimension
TranslationalUnit()
Create a translational unit.
void setVelocityDamping(agx::Real damping)
Set velocity damping for the local direction.
void setMass(agx::Real mass)
Set the mass for the one dimensional body.
virtual agx::Vec3 getWorldDirection() const
returns a vector in world coordinates that defines the linear axis of the transational unit.
agxPowerLine::TranslationalDimension * getTranslationalDimension() const
Pure virtual class.
Definition: Unit.h:72
Abstract base class for storing/restoring a line/drums with version control.
Definition: StorageStream.h:49
Smart pointer for handling referenced counted objects.
Definition: ref_ptr.h:30
agxPowerLine contains a collection of connected components that transport power across a system.
Definition: MotorUnit.h:24
agx::ref_ptr< TranslationalUnit > TranslationalUnitRef
double Real
Definition: Real.h:41