Momentum Scripting v1
Loading...
Searching...
No Matches
Sensor.h
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 without having a written signed agreement with Algoryx Simulation AB.
9
10Algoryx Simulation AB disclaims all responsibilities for loss or damage caused
11from using this software, unless otherwise stated in written agreements with
12Algoryx Simulation AB.
13*/
14#ifndef MOMENTUM_SENSOR_H
15#define MOMENTUM_SENSOR_H
16
17#include "momentum_namespace.h"
18#include "momentum_export.h"
19#include "macros.h"
20
21#include <string>
22
23#include "Vec3.h"
24#include "Vec4.h"
25#include "Geometry.h"
26
27#ifndef SWIG
29namespace agxControl
30{
31 class MeasurementSensor;
32}
34#endif
35
36namespace MOMENTUM_NAMESPACE
37{
38
43 class MOMENTUM_EXPORT Sensor
44 {
45 public:
47 Sensor();
49#ifndef SWIG
51
54 Sensor(agxControl::MeasurementSensor*);
56#endif
57
58#ifndef AGX_MOMENTUM_ANALYSIS_API
59
64 void setEnable(bool enable);
65
66#endif
67
71 bool getEnable() const;
72
77
81 std::vector<unsigned int> getParticlesContactingIds() const;
82
86 std::vector<unsigned int> getParticlesInsideIds() const;
87
91 double getTotalRemovedMass() const;
92
96 double getRemovedParticleMass() const;
97
101 double getRemovedBodyMass() const;
102
106 unsigned int getNumRemovedParticles() const;
107
111 unsigned int getNumRemovedBodies() const;
112
117 std::string getName() const;
118
120 std::string __str__() const;
122
123#ifndef SWIG
125 agxControl::MeasurementSensor* m_sensor;
127#endif
128 };
129
130 V1_DECLARE_CONTAINER_TYPE( Sensor );
131}
132
133#endif
A class that encapsulated the Sensor objects in the simulation that manipulates contacting GranularBo...
Definition: Sensor.h:44
unsigned int getNumRemovedBodies() const
void setEnable(bool enable)
Set enable of the Sensor.
GeometryPtr getGeometry() const
double getRemovedParticleMass() const
double getRemovedBodyMass() const
std::string getName() const
Get the name of the Sensor.
std::vector< unsigned int > getParticlesContactingIds() const
unsigned int getNumRemovedParticles() const
std::vector< unsigned int > getParticlesInsideIds() const
double getTotalRemovedMass() const
Namespace for Momentum Scripting API.
Definition: AffineMatrix4x4.h:29
std::shared_ptr< Geometry > GeometryPtr
Definition: Geometry.h:169