|
TexGen
|
Create a rectangular mesh, the number of layers can be specified or set as -1 for automatic determination. More...
#include <SectionMeshRectangleSection.h>

Public Member Functions | |
| CSectionMeshRectangleSection (int iNumLayers=-1) | |
| CSectionMeshRectangleSection (TiXmlElement &Element) | |
| ~CSectionMeshRectangleSection (void) | |
| CSectionMesh * | Copy () const |
| This is a function to allow copying of derived classes correctly. More... | |
| string | GetType () const |
| Derived class should return the class name. More... | |
| void | PopulateTiXmlElement (TiXmlElement &Element, OUTPUT_TYPE OutputType) const |
| Used for saving data to XML. More... | |
| void | SetNumLayers (int iNum) |
| int | GetNumLayers () const |
| int | CalculateNumberofLayers (const vector< XY > &Section) const |
| const CMesh & | GetMesh (const vector< XY > &Section) const |
| Accessor methods. More... | |
| virtual int | GetNumLayers () |
Static Public Member Functions | |
| static CObjectContainer< CSectionMesh > | CreateSectionMesh (TiXmlElement &Element) |
| Create a section from TiXmlElement. More... | |
Protected Member Functions | |
| bool | CreateMesh (const vector< XY > &Section) const |
| Create a mesh out of given list of points representing the edge of the section. More... | |
| bool | CreateMeshIfNeeded (const vector< XY > &Section) const |
| Create the mesh if it has not already been created. More... | |
Protected Attributes | |
| int | m_iNumLayers |
| CMesh | m_Mesh |
| Used to cache the result of the previous mesh for efficiency. More... | |
| vector< XY > | m_Section |
| Store the section used to request a mesh the last time. More... | |
Create a rectangular mesh, the number of layers can be specified or set as -1 for automatic determination.
Mesh is created with regular rectangular grid
Definition at line 31 of file SectionMeshRectangleSection.h.
| CSectionMeshRectangleSection::CSectionMeshRectangleSection | ( | int | iNumLayers = -1 | ) |
Definition at line 24 of file SectionMeshRectangleSection.cpp.
| CSectionMeshRectangleSection::CSectionMeshRectangleSection | ( | TiXmlElement & | Element | ) |
Definition at line 38 of file SectionMeshRectangleSection.cpp.
References m_iNumLayers.
| CSectionMeshRectangleSection::~CSectionMeshRectangleSection | ( | void | ) |
Definition at line 34 of file SectionMeshRectangleSection.cpp.
| int CSectionMeshRectangleSection::CalculateNumberofLayers | ( | const vector< XY > & | Section | ) | const |
Definition at line 178 of file SectionMeshRectangleSection.cpp.
References TexGen::XY::x, and TexGen::XY::y.
Referenced by CreateMesh().
|
inlinevirtual |
This is a function to allow copying of derived classes correctly.
Derived classes should implement this as CSectionMesh* Copy() const { return new CSectionMeshDerived(*this); } where CSectionMeshDerived should be replaced by the name of the derived class
Implements TexGen::CSectionMesh.
Definition at line 38 of file SectionMeshRectangleSection.h.
|
protectedvirtual |
Create a mesh out of given list of points representing the edge of the section.
Implements TexGen::CSectionMesh.
Definition at line 49 of file SectionMeshRectangleSection.cpp.
References TexGen::CMesh::AddElement(), CalculateNumberofLayers(), TexGen::CMesh::Clear(), TexGen::CMesh::GetIndices(), TexGen::GetMinMaxXY(), m_iNumLayers, TexGen::CSectionMesh::m_Mesh, TexGen::Max(), TexGen::Min(), TexGen::CMesh::POLYGON, TexGen::CMesh::QUAD, TexGen::CMesh::SetNode(), TexGen::CMesh::SetNumNodes(), TGERROR, TexGen::XYZ::x, TexGen::XY::x, TexGen::XYZ::y, and TexGen::XY::y.
|
protectedinherited |
Create the mesh if it has not already been created.
Definition at line 67 of file SectionMesh.cpp.
References TexGen::CSectionMesh::CreateMesh(), and TexGen::CSectionMesh::m_Section.
Referenced by TexGen::CSectionMesh::GetMesh().
|
staticinherited |
Create a section from TiXmlElement.
Definition at line 52 of file SectionMesh.cpp.
Referenced by TexGen::CSection::CSection(), TexGen::CTextile3DWeave::CTextile3DWeave(), and TexGen::CTextileWeave::CTextileWeave().
Accessor methods.
Definition at line 77 of file SectionMesh.cpp.
References TexGen::CSectionMesh::CreateMeshIfNeeded(), and TexGen::CSectionMesh::m_Mesh.
|
inlinevirtualinherited |
Definition at line 58 of file SectionMesh.h.
|
inline |
Definition at line 43 of file SectionMeshRectangleSection.h.
Referenced by TexGen::CSection::GetSectionMeshLayers().
|
inlinevirtual |
Derived class should return the class name.
Implements TexGen::CSectionMesh.
Definition at line 39 of file SectionMeshRectangleSection.h.
|
virtual |
Used for saving data to XML.
Reimplemented from TexGen::CSectionMesh.
Definition at line 43 of file SectionMeshRectangleSection.cpp.
References m_iNumLayers, and TexGen::CSectionMesh::PopulateTiXmlElement().
|
virtual |
Reimplemented from TexGen::CSectionMesh.
Definition at line 199 of file SectionMeshRectangleSection.cpp.
References m_iNumLayers.
|
protected |
Definition at line 50 of file SectionMeshRectangleSection.h.
Referenced by CreateMesh(), CSectionMeshRectangleSection(), PopulateTiXmlElement(), and SetNumLayers().
|
mutableprotectedinherited |
Used to cache the result of the previous mesh for efficiency.
Definition at line 68 of file SectionMesh.h.
Referenced by CreateMesh(), TexGen::CSectionMeshRectangular::CreateMesh(), TexGen::CSectionMeshTriangulate::CreateMesh(), TexGen::CSectionMeshRectangular::CreateSingleLayerMesh(), and TexGen::CSectionMesh::GetMesh().
|
mutableprotectedinherited |
Store the section used to request a mesh the last time.
If the given section is the same as given last time then no need to remesh, simply re-used the result of last time.
Definition at line 75 of file SectionMesh.h.
Referenced by TexGen::CSectionMesh::CreateMeshIfNeeded().