AGX Dynamics 2.42.1.1
Loading...
Searching...
No Matches
IMU.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#pragma once
18#include <agxSensor/IMUModel.h>
20
21#include <agxSDK/Simulation.h>
22
23#include <agx/Frame.h>
24
25namespace agxSensor
26{
29
35 {
36 public:
39
40 public:
47 static IMU* find( const agxSDK::Simulation* simulation, const agx::Name& name );
48
55 static IMU* find( const Environment* environment, const agx::Name& name );
56
63 static IMUPtrVector findAll( const agxSDK::Simulation* simulation, const agx::Name& name );
64
71 static IMUPtrVector findAll( const Environment* environment, const agx::Name& name );
72
78 static IMUPtrVector findAll( const agxSDK::Simulation* simulation );
79
85 static IMUPtrVector findAll( const Environment* environment );
86
87 public:
97 IMU( agx::Frame* frame, IMUModel* model );
98
104 virtual void setFrame( agx::Frame* frame ) override;
105
109 virtual agx::Frame* getFrame() const override;
110
115
120
125
130
132
133 public:
134 virtual void synchronizeGraphics(const agxRender::RenderManager& renderManager) override;
135 virtual void cleanup() override;
136
138
139 protected:
140 IMU();
141
143
144 private:
145 bool add( SensorAttachment&& sensorAttachment );
146
147 private:
148 agx::FrameRef m_frame;
149 IMUModelRef m_model;
150 SensorAttachmentVector m_sensorAttachments;
151 };
152}
#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:207
#define AGXSENSOR_EXPORT
#define AGX_DECLARE_VECTOR_TYPES(type)
Definition: agx/Vector.h:34
Simulation is a class that bridges the collision space agxCollide::Space and the dynamic simulation s...
Definition: Simulation.h:131
Sensor environment implementation where different sensors collects data given a set of added objects,...
Common base type for all sensors attached to a frame of reference, such as that of a rigid body.
IMU model describing which sensors are attached on this certain kind of IMU.
Definition: IMUModel.h:28
Handler responsible for how the IMU readings are assembled and provided to the user.
Inertial measurement unit (IMU) instance class defined by a frame/transform and a model.
Definition: IMU.h:35
IMUOutputHandler * getOutputHandler() const
static IMUPtrVector findAll(const Environment *environment)
Find all IMUs.
static IMUPtrVector findAll(const agxSDK::Simulation *simulation)
Find all IMUs.
virtual ISensorOutputHandler * getOutputHandlerBase() const override
static IMUPtrVector findAll(const agxSDK::Simulation *simulation, const agx::Name &name)
Find all IMUs, given name.
const SensorAttachmentVector & getSensorAttachments() const
IMUModel * getModel() const
virtual void setFrame(agx::Frame *frame) override
Assign a new parent frame to attach this IMU to.
static IMU * find(const agxSDK::Simulation *simulation, const agx::Name &name)
Find IMU given name.
virtual agx::Frame * getFrame() const override
static IMUPtrVector findAll(const Environment *environment, const agx::Name &name)
Find all IMUs, given name.
IMU(agx::Frame *frame, IMUModel *model)
Construct an inertial measurement unit (IMU) of the given model and attached to the specified frame.
static IMU * find(const Environment *environment, const agx::Name &name)
Find IMU given name.
Common interface for sensor output handlers.
The object defining a frame of reference and providing transformations operations.
Definition: agx/Frame.h:68
Representation of a name string.
Definition: Name.h:33
Vector containing 'raw' data.
Definition: agx/Vector.h:246
Templated vector class.
Definition: agx/Vector.h:53
#define DOXYGEN_END_INTERNAL_BLOCK()
Definition: macros.h:89
#define DOXYGEN_START_INTERNAL_BLOCK()
Definition: macros.h:88
Namespace containing classes for handling debug rendering of collision geometries,...
Definition: Constraint.h:36
The agxSensor namespace contains components to model real-time sensors connected to the physics of AG...
The agx namespace contains the dynamics/math part of the AGX Dynamics API.
Specification of a sensor attachment onto the IMU.