Public Member Functions | List of all members
lvr2::AttributeMeshIOBase Class Reference

#include <AttributeMeshIOBase.hpp>

Inheritance diagram for lvr2::AttributeMeshIOBase:
Inheritance graph
[legend]

Public Member Functions

template<typename MapT >
bool addAttributeMap (const MapT &map, const std::string &name)
 addAttributeMap Stores a general attribute map to the persistence layer where the attribute group is defined by the given map type. Note, that the map keys are also stored, if you want to store a dense attribute map, please see addDenseAttributeMap. More...
 
template<typename MapT , typename BaseVecT >
bool addDenseAttributeMap (const BaseMesh< BaseVecT > &mesh, const MapT &map, const std::string &name)
 addDenseAttributeMap Stores a dense attribute map to the persistence layer where the attribute group is defined by the given map type. More...
 
template<typename MapT >
bool addDenseAttributeMap (const MapT &map, const std::string &name)
 addDenseAttributeMap Stores a dense attribute map to the persistence layer where the attribute group is defined by the given map type. More...
 
bool addMesh (const HalfEdgeMesh< BaseVec > &hem)
 Adds a HalfEdgeMesh to the persistence layer. More...
 
template<typename MapT >
boost::optional< MapT > getAttributeMap (const std::string &name)
 getAttributeMap Reads a general attribute map from the persistence layer where the attribute group is defined by the given map type. Note, that the map keys have to be available in the persistence layer. If you want to load a DenseAttributeMap, please use getDenseAttributeMap. More...
 
template<typename MapT >
boost::optional< MapT > getDenseAttributeMap (const std::string &name)
 getDenseAttributeMap Reads a dense attribute map from the persistence layer where the attribute group is defined by the given map type. More...
 
boost::optional< HalfEdgeMesh< BaseVec > > getMesh ()
 Reads a HalfEdgeMesh from the persistence layer. More...
 
- Public Member Functions inherited from lvr2::MeshGeometryIO
virtual bool addIndices (const IndexChannel &channel_ptr)=0
 Persistence layer interface, Writes the face indices of the mesh to the persistence layer. More...
 
virtual bool addVertices (const FloatChannel &channel_ptr)=0
 Persistence layer interface, Writes the vertices of the mesh to the persistence layer. More...
 
virtual IndexChannelOptional getIndices ()=0
 Persistence layer interface, Accesses the face indices of the mesh in the persistence layer. More...
 
virtual FloatChannelOptional getVertices ()=0
 Persistence layer interface, Accesses the vertices of the mesh in the persistence layer. More...
 
- Public Member Functions inherited from lvr2::GroupedChannelIO
virtual bool addChannel (const std::string group, const std::string name, const FloatChannel &channel)=0
 addChannel Writes a float attribute channel from the given group with the given name More...
 
virtual bool addChannel (const std::string group, const std::string name, const FloatChannel &channel)=0
 addChannel Writes a float attribute channel from the given group with the given name More...
 
virtual bool addChannel (const std::string group, const std::string name, const IndexChannel &channel)=0
 addChannel Writes an index attribute channel from the given group with the given name More...
 
virtual bool addChannel (const std::string group, const std::string name, const IndexChannel &channel)=0
 addChannel Writes an index attribute channel from the given group with the given name More...
 
virtual bool addChannel (const std::string group, const std::string name, const UCharChannel &channel)=0
 addChannel Writes an unsigned char attribute channel from the given group with the given name More...
 
virtual bool addChannel (const std::string group, const std::string name, const UCharChannel &channel)=0
 addChannel Writes an unsigned char attribute channel from the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, FloatChannelOptional &channel)=0
 getChannel Reads a float attribute channel in the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, FloatChannelOptional &channel)=0
 getChannel Reads a float attribute channel in the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, IndexChannelOptional &channel)=0
 getChannel Reads an index attribute channel in the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, IndexChannelOptional &channel)=0
 getChannel Reads an index attribute channel in the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, UCharChannelOptional &channel)=0
 getChannel Reads an unsigned char attribute channel in the given group with the given name More...
 
virtual bool getChannel (const std::string group, const std::string name, UCharChannelOptional &channel)=0
 getChannel Reads an unsigned char attribute channel in the given group with the given name More...
 

Detailed Description

Definition at line 47 of file AttributeMeshIOBase.hpp.

Member Function Documentation

◆ addAttributeMap()

template<typename MapT >
bool lvr2::AttributeMeshIOBase::addAttributeMap ( const MapT &  map,
const std::string &  name 
)

addAttributeMap Stores a general attribute map to the persistence layer where the attribute group is defined by the given map type. Note, that the map keys are also stored, if you want to store a dense attribute map, please see addDenseAttributeMap.

Template Parameters
MapTThe map type of the map which has to be stored
Parameters
mapThe map which has to be stored
nameThe name under which the map should be stored
Returns
true if the map has been stored successfully, false otherwise

◆ addDenseAttributeMap() [1/2]

template<typename MapT , typename BaseVecT >
bool lvr2::AttributeMeshIOBase::addDenseAttributeMap ( const BaseMesh< BaseVecT > &  mesh,
const MapT &  map,
const std::string &  name 
)

addDenseAttributeMap Stores a dense attribute map to the persistence layer where the attribute group is defined by the given map type.

Template Parameters
MapTThe map type of the map which has to be stored
Parameters
meshThe mesh which correspond to the map
mapThe map which has to be stored
nameThe name under which the map should be stored
Returns
true if the map has been stored successfully, false otherwise

◆ addDenseAttributeMap() [2/2]

template<typename MapT >
bool lvr2::AttributeMeshIOBase::addDenseAttributeMap ( const MapT &  map,
const std::string &  name 
)

addDenseAttributeMap Stores a dense attribute map to the persistence layer where the attribute group is defined by the given map type.

Template Parameters
MapTThe map type of the map which has to be stored
Parameters
mapThe map which has to be stored
nameThe name under which the map should be stored
Returns
true if the map has been stored successfully, false otherwise

◆ addMesh()

bool lvr2::AttributeMeshIOBase::addMesh ( const HalfEdgeMesh< BaseVec > &  hem)

Adds a HalfEdgeMesh to the persistence layer.

Parameters
hemThe HalrfEdgeMesh which has to be stored
Returns
true if the HalfEdgeMesh has been written to the persistence layer, false otherwise

Definition at line 40 of file AttributeMeshIOBase.cpp.

◆ getAttributeMap()

template<typename MapT >
boost::optional<MapT> lvr2::AttributeMeshIOBase::getAttributeMap ( const std::string &  name)

getAttributeMap Reads a general attribute map from the persistence layer where the attribute group is defined by the given map type. Note, that the map keys have to be available in the persistence layer. If you want to load a DenseAttributeMap, please use getDenseAttributeMap.

Template Parameters
MapTThe map type of the map which has to be loaded
Parameters
mapThe map which has to be loaded
nameThe name under which the map values can be found in the persistence layer
Returns
A valid optional to the map if the map has been loaded successfully, a none type otherwise

◆ getDenseAttributeMap()

template<typename MapT >
boost::optional<MapT> lvr2::AttributeMeshIOBase::getDenseAttributeMap ( const std::string &  name)

getDenseAttributeMap Reads a dense attribute map from the persistence layer where the attribute group is defined by the given map type.

Template Parameters
MapTThe map type of the map which has to be loaded
Parameters
mapThe map which has to be loaded
nameThe name under which the map values can be found in the persistence layer
Returns
A valid optional to the map if the map has been loaded successfully, a none type otherwise

◆ getMesh()

boost::optional< HalfEdgeMesh< BaseVec > > lvr2::AttributeMeshIOBase::getMesh ( )

Reads a HalfEdgeMesh from the persistence layer.

Returns
Returns an optional to a HalfEdgeMesh which is valid if the mesh has been read successfully

Definition at line 69 of file AttributeMeshIOBase.cpp.


The documentation for this class was generated from the following files:


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Mon Feb 28 2022 22:46:11