RobWorkProject
24.12.4-
|
the TactileArrayModel describes tactile sensor consisting of arrays of tactile cells that can be placed on a defined shape. The shape is described with a matrix of 3d vertices. Such that tactil (0,0) maps to the quad defined by the four vertices {(0,0),(0,1),(1,1),(1,0)}. Notice that the normal is defined by sequence of the vertices and that the normal defines the direction of tactile sensing. More...
#include <TactileArrayModel.hpp>
Inherits SensorModel.
Classes | |
class | TactileModelCache |
cache to store state information More... | |
Public Types | |
typedef rw::core::Ptr< TactileArrayModel > | Ptr |
smart pointer type | |
typedef Eigen::MatrixXf | ValueMatrix |
type of tactile array readings | |
typedef boost::multi_array< rw::math::Vector3D<>, 2 > | VertexMatrix |
type of vertices describing geometry of sensor | |
Public Types inherited from SensorModel | |
typedef rw::core::Ptr< SensorModel > | Ptr |
smart pointer type | |
Public Types inherited from Stateless | |
typedef rw::core::Ptr< Stateless > | Ptr |
Smart pointer type for Stateless. | |
Public Member Functions | |
TactileArrayModel (const std::string &name, rw::core::Ptr< rw::kinematics::Frame > sensorframe, const rw::math::Transform3D<> &fThmap, const ValueMatrix &heightMap, double cell_width, double cell_height) | |
constructor More... | |
virtual | ~TactileArrayModel () |
destructor | |
rw::math::Vector2D | getTexelSize (int x, int y) const |
gets the size of an individual tactile cell with coordinates (x,y) More... | |
std::pair< double, double > | getPressureLimit () const |
get the minimum and maximum pressure capability of any tactile cell in the TactileArray More... | |
void | setPressureLimit (double min, double max) |
set pressure limits. should define min max of any tactile cell in array More... | |
void | setPressureLimit (std::pair< double, double > range) |
const VertexMatrix & | getVertexGrid () const |
gets the 3d geometry of this tactilearray. The vertexes are expressed realtive to the transform. More... | |
const rw::math::Transform3D & | getTransform () const |
a transformation from the sensor frame to the geometric data of the tactile array. More... | |
const VertexMatrix & | getCenters () const |
a matrix with position of each tactile cell center. The coordinates are described relative to the TactileArray transform (see getTransform()) More... | |
const VertexMatrix & | getNormals () const |
a matrix of normals that are described relative to each tactile cell center. More... | |
int | getWidth () const |
get width of tactile array | |
int | getHeight () const |
get height of tactile array | |
ValueMatrix & | getTexelData (rw::kinematics::State &state) const |
returns the pressure on each texel of the TactileArray in the unit Pa (N/m^2). More... | |
const ValueMatrix & | getTexelData (const rw::kinematics::State &state) const |
void | setTexelData (const ValueMatrix &data, rw::kinematics::State &state) const |
set the pressure on each texel of the TactileArray in the unit Pa (N/m^2). More... | |
Public Member Functions inherited from SensorModel | |
SensorModel (const std::string &name, rw::core::Ptr< kinematics::Frame > frame) | |
constructor More... | |
SensorModel (const std::string &name, rw::core::Ptr< kinematics::Frame > frame, const std::string &description) | |
constructor More... | |
virtual | ~SensorModel () |
destructor | |
void | setName (const std::string &name) |
sets the name of this sensor More... | |
void | setDescription (const std::string &description) |
sets the description of this sensor More... | |
const std::string & | getName () const |
returns the name of this sensor More... | |
const std::string & | getDescription () const |
returns a description of this sensor More... | |
kinematics::Frame * | getFrame () const |
The frame to which the sensor is attached. More... | |
virtual void | attachTo (rw::core::Ptr< kinematics::Frame > frame) |
Sets the frame to which the sensor should be attached. More... | |
rw::core::PropertyMap & | getPropertyMap () |
gets the propertymap of this sensor | |
const rw::core::PropertyMap & | getPropertyMap () const |
gets the propertymap of this sensor | |
Public Member Functions inherited from Stateless | |
virtual | ~Stateless () |
destructor | |
virtual void | registerIn (State &state) |
initialize this stateless data to a specific state More... | |
virtual void | registerIn (StateStructure::Ptr state) |
register this stateless object in a statestructure. | |
virtual void | unregister () |
unregisters all state data of this stateless object | |
StateStructure::Ptr | getStateStructure () |
Get the state structure. More... | |
const StateStructure::Ptr | getStateStructure () const |
Get the state structure. More... | |
bool | isRegistered () |
Check if object has registered its state. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Stateless | |
Stateless () | |
constructor | |
template<class T > | |
void | add (StatelessData< T > &data) |
implementations of sensor should add all their stateless data on initialization | |
void | add (StateData *data) |
Add data. More... | |
void | add (rw::core::Ptr< StateData > data) |
implementations of sensor should add all their state data on initialization | |
Protected Attributes inherited from Stateless | |
bool | _registered |
True if object has registered its state. | |
std::vector< rw::core::Ptr< StateData > > | _datas |
Data. | |
StateStructure::Ptr | _stateStruct |
The state structure. | |
the TactileArrayModel describes tactile sensor consisting of arrays of tactile cells that can be placed on a defined shape. The shape is described with a matrix of 3d vertices. Such that tactil (0,0) maps to the quad defined by the four vertices {(0,0),(0,1),(1,1),(1,0)}. Notice that the normal is defined by sequence of the vertices and that the normal defines the direction of tactile sensing.
TactileArrayModel | ( | const std::string & | name, |
rw::core::Ptr< rw::kinematics::Frame > | sensorframe, | ||
const rw::math::Transform3D<> & | fThmap, | ||
const ValueMatrix & | heightMap, | ||
double | cell_width, | ||
double | cell_height | ||
) |
constructor
name | [in] name of sensor |
sensorframe | [in] the frame to which the sensor is attached |
fThmap | [in] transformation from sensor frame to the heightmap definition |
heightMap | [in] a height map defining the height of each corner in the tactile array |
cell_width | [in] width of cell |
cell_height | [in] height of cell |
const VertexMatrix& getCenters | ( | ) | const |
a matrix with position of each tactile cell center. The coordinates are described relative to the TactileArray transform (see getTransform())
const VertexMatrix& getNormals | ( | ) | const |
a matrix of normals that are described relative to each tactile cell center.
std::pair<double, double> getPressureLimit | ( | ) | const |
get the minimum and maximum pressure capability of any tactile cell in the TactileArray
ValueMatrix& getTexelData | ( | rw::kinematics::State & | state | ) | const |
returns the pressure on each texel of the TactileArray in the unit Pa (N/m^2).
state | [in] state to get the values from |
rw::math::Vector2D getTexelSize | ( | int | x, |
int | y | ||
) | const |
gets the size of an individual tactile cell with coordinates (x,y)
x | |
y |
const rw::math::Transform3D& getTransform | ( | ) | const |
a transformation from the sensor frame to the geometric data of the tactile array.
const VertexMatrix& getVertexGrid | ( | ) | const |
gets the 3d geometry of this tactilearray. The vertexes are expressed realtive to the transform.
void setPressureLimit | ( | double | min, |
double | max | ||
) |
set pressure limits. should define min max of any tactile cell in array
min | [in] min pressure in Pa |
max | [in] max pressure in Pa |
void setTexelData | ( | const ValueMatrix & | data, |
rw::kinematics::State & | state | ||
) | const |
set the pressure on each texel of the TactileArray in the unit Pa (N/m^2).
data | [in] pressure values |
state | [in] state to set the values in |