libigl v2.5.0
Loading...
Searching...
No Matches
igl::MshLoader Class Reference

Class for loading information from .msh file depends only on c++stl library. More...

#include <MshLoader.h>

Classes

struct  msh_struct
 

Public Types

enum  {
  ELEMENT_LINE =1 , ELEMENT_TRI =2 , ELEMENT_QUAD =3 , ELEMENT_TET =4 ,
  ELEMENT_HEX =5 , ELEMENT_PRISM =6 , ELEMENT_PYRAMID =7 , ELEMENT_LINE_2ND_ORDER =8 ,
  ELEMENT_TRI_2ND_ORDER =9 , ELEMENT_QUAD_2ND_ORDER =10 , ELEMENT_TET_2ND_ORDER =11 , ELEMENT_HEX_2ND_ORDER =12 ,
  ELEMENT_PRISM_2ND_ORDER =13 , ELEMENT_PYRAMID_2ND_ORDER =14 , ELEMENT_POINT =15
}
 
typedef double Float
 
typedef std::vector< int > IndexVector
 
typedef std::vector< int > IntVector
 
typedef std::vector< FloatFloatVector
 
typedef std::vector< FloatVectorFloatField
 
typedef std::vector< IntVectorIntField
 
typedef std::vector< std::string > FieldNames
 
typedef std::multimap< msh_struct, int > StructIndex
 
typedef std::vector< msh_structStructVector
 

Public Member Functions

 MshLoader (const std::string &filename)
 Load a .msh file from a given path.
 
const FloatVectorget_nodes () const
 
const IndexVectorget_elements () const
 
const IntVectorget_elements_types () const
 
const IntVectorget_elements_lengths () const
 
const IntFieldget_elements_tags () const
 
const IntVectorget_elements_ids () const
 
const IndexVectorget_elements_nodes_idx () const
 
const FloatFieldget_node_fields () const
 
const FieldNamesget_node_fields_names () const
 
const IntVectorget_node_fields_components () const
 
int get_node_field_components (size_t c) const
 
const FloatFieldget_element_fields () const
 
const FieldNamesget_element_fields_names () const
 
const IntVectorget_element_fields_components () const
 
int get_element_field_components (size_t c) const
 
bool is_node_field (const std::string &fieldname) const
 
bool is_element_field (const std::string &fieldname) const
 
bool is_element_map_identity () const
 
void index_structures (int tag_column)
 
const StructIndexget_structure_index () const
 
const StructIndexget_structure_length () const
 
const StructVectorget_structures () const
 get list of structures
 

Static Public Member Functions

static int num_nodes_per_elem_type (int elem_type)
 

Detailed Description

Class for loading information from .msh file depends only on c++stl library.

Member Typedef Documentation

◆ Float

typedef double igl::MshLoader::Float

◆ IndexVector

typedef std::vector<int> igl::MshLoader::IndexVector

◆ IntVector

typedef std::vector<int> igl::MshLoader::IntVector

◆ FloatVector

typedef std::vector<Float> igl::MshLoader::FloatVector

◆ FloatField

◆ IntField

typedef std::vector<IntVector> igl::MshLoader::IntField

◆ FieldNames

typedef std::vector<std::string> igl::MshLoader::FieldNames

◆ StructIndex

typedef std::multimap<msh_struct,int> igl::MshLoader::StructIndex

◆ StructVector

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
ELEMENT_LINE 
ELEMENT_TRI 
ELEMENT_QUAD 
ELEMENT_TET 
ELEMENT_HEX 
ELEMENT_PRISM 
ELEMENT_PYRAMID 
ELEMENT_LINE_2ND_ORDER 
ELEMENT_TRI_2ND_ORDER 
ELEMENT_QUAD_2ND_ORDER 
ELEMENT_TET_2ND_ORDER 
ELEMENT_HEX_2ND_ORDER 
ELEMENT_PRISM_2ND_ORDER 
ELEMENT_PYRAMID_2ND_ORDER 
ELEMENT_POINT 

Constructor & Destructor Documentation

◆ MshLoader()

igl::MshLoader::MshLoader ( const std::string &  filename)

Load a .msh file from a given path.

Parameters
[in]filenamepath to .msh

Member Function Documentation

◆ get_nodes()

const FloatVector & igl::MshLoader::get_nodes ( ) const
inline

◆ get_elements()

const IndexVector & igl::MshLoader::get_elements ( ) const
inline

◆ get_elements_types()

const IntVector & igl::MshLoader::get_elements_types ( ) const
inline

◆ get_elements_lengths()

const IntVector & igl::MshLoader::get_elements_lengths ( ) const
inline

◆ get_elements_tags()

const IntField & igl::MshLoader::get_elements_tags ( ) const
inline

◆ get_elements_ids()

const IntVector & igl::MshLoader::get_elements_ids ( ) const
inline

◆ get_elements_nodes_idx()

const IndexVector & igl::MshLoader::get_elements_nodes_idx ( ) const
inline

◆ get_node_fields()

const FloatField & igl::MshLoader::get_node_fields ( ) const
inline

◆ get_node_fields_names()

const FieldNames & igl::MshLoader::get_node_fields_names ( ) const
inline

◆ get_node_fields_components()

const IntVector & igl::MshLoader::get_node_fields_components ( ) const
inline

◆ get_node_field_components()

int igl::MshLoader::get_node_field_components ( size_t  c) const
inline

◆ get_element_fields()

const FloatField & igl::MshLoader::get_element_fields ( ) const
inline

◆ get_element_fields_names()

const FieldNames & igl::MshLoader::get_element_fields_names ( ) const
inline

◆ get_element_fields_components()

const IntVector & igl::MshLoader::get_element_fields_components ( ) const
inline

◆ get_element_field_components()

int igl::MshLoader::get_element_field_components ( size_t  c) const
inline

◆ is_node_field()

bool igl::MshLoader::is_node_field ( const std::string &  fieldname) const
inline

◆ is_element_field()

bool igl::MshLoader::is_element_field ( const std::string &  fieldname) const
inline

◆ is_element_map_identity()

bool igl::MshLoader::is_element_map_identity ( ) const

◆ index_structures()

void igl::MshLoader::index_structures ( int  tag_column)

◆ get_structure_index()

const StructIndex & igl::MshLoader::get_structure_index ( ) const
inline

◆ get_structure_length()

const StructIndex & igl::MshLoader::get_structure_length ( ) const
inline

◆ get_structures()

const StructVector & igl::MshLoader::get_structures ( ) const
inline

get list of structures

◆ num_nodes_per_elem_type()

static int igl::MshLoader::num_nodes_per_elem_type ( int  elem_type)
static

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