TexGen
|
Class for meshing fabric unit cells. More...
#include <BasicVolumes.h>
Classes | |
struct | PROJECTED_REGION |
Struct representing a region projected onto the XY plane. More... | |
struct | ProjectedRegionArea |
Functor defining the < operator based on the projected region's area. More... | |
Public Member Functions | |
CBasicVolumes (void) | |
~CBasicVolumes (void) | |
bool | CreateBasicVolumes (CTextile &Textile) |
bool | CreateBasicVolumes (string TextileName) |
void | SetSeed (double dSeed) |
double | GetSeed () |
void | SetPeriodic (bool bPeriodic) |
bool | GetPeriodic () |
void | SetDebug (bool bDebug) |
bool | GetDebug () |
Protected Types | |
enum | LINE_STATE { FORWARD = 1 , REVERSE = 2 } |
Protected Member Functions | |
void | SaveProjectedContoursToVTK (string Filename) |
void | SaveProjectedAreasToVTK (string Filename) |
bool | ValidProjectedMesh () |
int | SplitLinesByNodes (CMesh &Mesh) |
int | SplitLinesByLines (CMesh &Mesh) |
int | MergeStraightLines (CMesh &Mesh) |
int | RemoveDuplicateSegments (CMesh &Mesh) |
int | RemoveDegenerateSegments (CMesh &Mesh) |
CMesh | GetProjectedMesh (const CMesh &Mesh) |
bool | GetCommonEdgeIndices (int Indices1[3], int Indices2[3], int Common[2]) |
bool | CreateProjectedAreas () |
bool | SeedOuterBoundary () |
bool | RemoveOuterBoundary () |
double | GetRegionArea (const PROJECTED_REGION &Region) |
bool | CreateProjectedCenters () |
bool | PointInsideRegion (XYZ Point, int iRegion) |
void | CalculateYarnIndices () |
bool | MeshProjectedAreas () |
bool | GetMeshVerticalBounds (const CMesh &Mesh, XYZ Point, double &dMinZ, double &dMaxZ, bool bForceFind=false) |
Protected Attributes | |
CMesh | m_ProjectedMesh |
CMesh | m_DomainMesh |
vector< CMesh > | m_YarnMeshes |
vector< PROJECTED_REGION > | m_ProjectedRegions |
vector< int > | m_TriangleRegions |
double | m_dTolerance |
CTextile * | m_pTextile |
double | m_dSeed |
bool | m_bCreatePeriodic |
bool | m_bDebug |
Class for meshing fabric unit cells.
Definition at line 32 of file BasicVolumes.h.
|
protected |
Enumerator | |
---|---|
FORWARD | |
REVERSE |
Definition at line 51 of file BasicVolumes.h.
CBasicVolumes::CBasicVolumes | ( | void | ) |
Definition at line 31 of file BasicVolumes.cpp.
CBasicVolumes::~CBasicVolumes | ( | void | ) |
Definition at line 40 of file BasicVolumes.cpp.
|
protected |
Definition at line 826 of file BasicVolumes.cpp.
References GetMeshVerticalBounds(), m_ProjectedRegions, and m_YarnMeshes.
Referenced by CreateBasicVolumes().
bool CBasicVolumes::CreateBasicVolumes | ( | CTextile & | Textile | ) |
Definition at line 53 of file BasicVolumes.cpp.
References CalculateYarnIndices(), TexGen::CMesh::Clear(), TexGen::CMesh::ConvertQuadstoTriangles(), CreateProjectedAreas(), CreateProjectedCenters(), TexGen::CTextile::GetDomain(), TexGen::CDomain::GetMesh(), GetProjectedMesh(), TexGen::CTextile::GetYarns(), TexGen::CMesh::InsertMesh(), m_bCreatePeriodic, m_bDebug, m_DomainMesh, m_dTolerance, m_ProjectedMesh, m_ProjectedRegions, m_pTextile, m_TriangleRegions, m_YarnMeshes, TexGen::CMesh::MergeNodes(), MergeStraightLines(), MeshProjectedAreas(), RemoveDegenerateSegments(), RemoveDuplicateSegments(), RemoveOuterBoundary(), SaveProjectedAreasToVTK(), SaveProjectedContoursToVTK(), TexGen::CMesh::SaveToVTK(), SeedOuterBoundary(), SplitLinesByLines(), SplitLinesByNodes(), TGLOG, and ValidProjectedMesh().
Referenced by CreateBasicVolumes(), TexGen::CMesher::CreateMesh(), and TexGen::CGeometrySolver::CreateSystem().
bool CBasicVolumes::CreateBasicVolumes | ( | string | TextileName | ) |
Definition at line 44 of file BasicVolumes.cpp.
References CreateBasicVolumes(), and TEXGEN.
|
protected |
Definition at line 517 of file BasicVolumes.cpp.
References TexGen::CrossProduct(), TexGen::DotProduct(), FORWARD, TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), GetRegionArea(), TexGen::CMesh::LINE, m_ProjectedMesh, m_ProjectedRegions, REVERSE, and TGERROR.
Referenced by CreateBasicVolumes(), and SeedOuterBoundary().
|
protected |
Definition at line 745 of file BasicVolumes.cpp.
References TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, m_ProjectedMesh, m_ProjectedRegions, TexGen::Max(), TexGen::Min(), PointInsideRegion(), TexGen::RandomNumber(), TexGen::XYZ::x, and TexGen::XYZ::y.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 217 of file BasicVolumes.cpp.
Referenced by GetProjectedMesh().
|
inline |
Definition at line 48 of file BasicVolumes.h.
|
protected |
Find the intersections between a line passing through Point and parallel to the Z axis and the given mesh, then return the lowest and highest of those intersections.
Mesh | The mesh with which to perform the intersection test |
Point | The point through which the line passes through (the z component is redundant) |
dMinZ | The returned lowest intersection point |
dMaxZ | The returned highest intersection point |
bForceFind | Force the algorithm to find at least one intersection, what this means is that it will find the intersection with the closest triangle and use that intersection as the maximum and minimum returned bounds. This is usefull for cases where the vertical line just misses the mesh and the closest intersection is needed. |
Definition at line 975 of file BasicVolumes.cpp.
References TexGen::CMesh::IntersectLine(), m_dTolerance, and TexGen::XYZ::z.
Referenced by TexGen::CMesher::BuildMidSideNode(), CalculateYarnIndices(), TexGen::CGeometrySolver::RaiseNodes(), and TexGen::CMesher::RaiseNodes().
|
inline |
Definition at line 45 of file BasicVolumes.h.
Definition at line 1007 of file BasicVolumes.cpp.
References GetCommonEdgeIndices(), TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::GetNodes(), TexGen::CMesh::LINE, TexGen::CMesh::RemoveAllElementsExcept(), TexGen::CMesh::RemoveUnreferencedNodes(), TexGen::CMesh::TRI, TexGen::XYZ::x, and TexGen::XYZ::y.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 733 of file BasicVolumes.cpp.
References TexGen::CBasicVolumes::PROJECTED_REGION::ContourNodes, TexGen::GetArea(), TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, and m_ProjectedMesh.
Referenced by CreateProjectedAreas().
|
inline |
Definition at line 42 of file BasicVolumes.h.
|
protected |
Definition at line 235 of file BasicVolumes.cpp.
References TexGen::DotProduct(), TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, m_dTolerance, TexGen::Normalise(), and TexGen::CMesh::RemoveUnreferencedNodes().
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 852 of file BasicVolumes.cpp.
References TexGen::CMesh::AddNode(), TexGen::CMesh::Clear(), TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::GetNumNodes(), TexGen::CMesh::LINE, m_bCreatePeriodic, m_dSeed, m_ProjectedMesh, m_ProjectedRegions, m_TriangleRegions, TexGen::CMesh::TRI, TexGen::XYZ::x, and TexGen::XYZ::y.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 788 of file BasicVolumes.cpp.
References TexGen::CBasicVolumes::PROJECTED_REGION::ContourNodes, TexGen::CMesh::GetNode(), m_ProjectedMesh, m_ProjectedRegions, TexGen::XYZ::x, and TexGen::XYZ::y.
Referenced by CreateProjectedCenters().
|
protected |
Definition at line 332 of file BasicVolumes.cpp.
References TexGen::CMesh::GetIndices(), and TexGen::CMesh::LINE.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 304 of file BasicVolumes.cpp.
References TexGen::CMesh::GetIndices(), and TexGen::CMesh::LINE.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 721 of file BasicVolumes.cpp.
References m_ProjectedRegions.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 191 of file BasicVolumes.cpp.
References TexGen::CMeshDataBase::ELEMENT, TexGen::CMeshData< T >::m_Data, m_ProjectedMesh, m_ProjectedRegions, m_TriangleRegions, and TexGen::CMesh::SaveToVTK().
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 148 of file BasicVolumes.cpp.
References TexGen::CMesh::AddNode(), TexGen::CMeshDataBase::ELEMENT, TexGen::CMesh::GetIndices(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, TexGen::CMeshData< T >::m_Data, m_ProjectedMesh, m_ProjectedRegions, and TexGen::CMesh::SaveToVTK().
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 640 of file BasicVolumes.cpp.
References TexGen::CMesh::AddNode(), CreateProjectedAreas(), TexGen::CMesh::GetIndices(), TexGen::GetLength(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, m_dSeed, m_ProjectedMesh, and m_ProjectedRegions.
Referenced by CreateBasicVolumes().
|
inline |
Definition at line 47 of file BasicVolumes.h.
|
inline |
Definition at line 44 of file BasicVolumes.h.
Referenced by TexGen::CGeometrySolver::CreateSystem().
|
inline |
Definition at line 41 of file BasicVolumes.h.
|
protected |
Definition at line 414 of file BasicVolumes.cpp.
References TexGen::CMesh::AddNode(), TexGen::CMesh::GetIndices(), TexGen::GetLengthSquared(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, TexGen::LineLineIntersect2D(), m_dTolerance, TexGen::XYZ::x, and TexGen::XYZ::y.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 352 of file BasicVolumes.cpp.
References TexGen::CMesh::GetIndices(), TexGen::GetLengthSquared(), TexGen::CMesh::GetNode(), TexGen::CMesh::LINE, m_dTolerance, TexGen::CMesh::NodesBegin(), TexGen::CMesh::NodesEnd(), and TexGen::ShortestDistPointLine().
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 485 of file BasicVolumes.cpp.
References TexGen::CMesh::GetIndices(), TexGen::CMesh::LINE, and m_ProjectedMesh.
Referenced by CreateBasicVolumes().
|
protected |
Definition at line 123 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), TexGen::CMesher::CreateVolumeMesh(), and MeshProjectedAreas().
|
protected |
Definition at line 124 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), and TexGen::CGeometrySolver::SolveSystem().
|
protected |
Definition at line 113 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), and TexGen::CMesher::RaiseNodes().
|
protected |
Definition at line 122 of file BasicVolumes.h.
Referenced by TexGen::CMesher::GetBestSeed(), MeshProjectedAreas(), and SeedOuterBoundary().
|
protected |
Definition at line 120 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), GetMeshVerticalBounds(), MergeStraightLines(), SplitLinesByLines(), and SplitLinesByNodes().
|
protected |
Definition at line 112 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), CreateProjectedAreas(), CreateProjectedCenters(), TexGen::CGeometrySolver::CreateSurfaceMesh(), TexGen::CGeometrySolver::CreateSystem(), TexGen::CMesher::CreateVolumeMesh(), TexGen::CGeometrySolver::GetAverageLength(), TexGen::CMesher::GetBestSeed(), GetRegionArea(), MeshProjectedAreas(), PointInsideRegion(), TexGen::CGeometrySolver::RaiseNodes(), TexGen::CMesher::RaiseNodes(), SaveProjectedAreasToVTK(), SaveProjectedContoursToVTK(), SeedOuterBoundary(), TexGen::CMesher::SortPairs(), and ValidProjectedMesh().
|
protected |
Definition at line 115 of file BasicVolumes.h.
Referenced by CalculateYarnIndices(), CreateBasicVolumes(), CreateProjectedAreas(), CreateProjectedCenters(), TexGen::CMesher::MeshColumn(), MeshProjectedAreas(), PointInsideRegion(), TexGen::CGeometrySolver::RaiseNodes(), TexGen::CMesher::RaiseNodes(), RemoveOuterBoundary(), SaveProjectedAreasToVTK(), SaveProjectedContoursToVTK(), and SeedOuterBoundary().
|
protected |
Definition at line 121 of file BasicVolumes.h.
Referenced by TexGen::CGeometrySolver::AssignFibreDirectionToElements(), CreateBasicVolumes(), TexGen::CGeometrySolver::CreateSystem(), TexGen::CGeometrySolver::DeformTextile(), TexGen::CMesher::FillYarnTangentsData(), and TexGen::CGeometrySolver::GetDeformedCopyOfTextile().
|
protected |
Definition at line 119 of file BasicVolumes.h.
Referenced by CreateBasicVolumes(), TexGen::CMesher::CreateVolumeMesh(), MeshProjectedAreas(), TexGen::CGeometrySolver::RaiseNodes(), TexGen::CMesher::RaiseNodes(), and SaveProjectedAreasToVTK().
|
protected |
Definition at line 114 of file BasicVolumes.h.
Referenced by TexGen::CMesher::BuildMidSideNode(), CalculateYarnIndices(), CreateBasicVolumes(), TexGen::CGeometrySolver::RaiseNodes(), and TexGen::CMesher::RaiseNodes().