Classes | Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CRichModel Class Reference

#include <RichModel.h>

Inheritance diagram for CRichModel:
Inheritance graph
[legend]

Classes

struct  CEdge
 

Public Member Functions

double AngleSum (int vertIndex) const
 
 CRichModel (const string &filename)
 
 CRichModel (const vector< CPoint3D > &verts, const vector< CBaseModel::CFace > &faces)
 
double DistanceToLeftVert (int edgeIndex, const pair< double, double > &coord) const
 
double DistanceToOppositeAngle (int edgeIndex, const pair< double, double > &coord) const
 
double DistanceToRightVert (int edgeIndex, const pair< double, double > &coord) const
 
const CEdgeEdge (int edgeIndex) const
 
void FinishChangingEdgeLengths ()
 
CPoint3D GetBarycentricCoord (CPoint3D pt, int faceID) const
 
int GetEdgeIndexFromTwoVertices (int leftVert, int rightVert) const
 
double GetMaxEdgeLength () const
 
pair< double, double > GetNew2DCoordinatesByReversingCurrentEdge (int edgeIndex, const pair< double, double > &input2DCoordinates) const
 
pair< double, double > GetNew2DCoordinatesByRotatingAroundLeftChildEdge (int edgeIndex, const pair< double, double > &input2DCoordinates) const
 
pair< double, double > GetNew2DCoordinatesByRotatingAroundRightChildEdge (int edgeIndex, const pair< double, double > &input2DCoordinates) const
 
int GetNumOfBoundries () const
 
int GetNumOfComponents () const
 
int GetNumOfEdges () const
 
int GetNumOfGenera () const
 
int GetNumOfIsolated () const
 
int GetNumOfTotalUndirectedEdges () const
 
int GetNumOfValidDirectedEdges () const
 
int GetSubindexToVert (int root, int neigh) const
 
pair< double, double > GetTwoSplitAngles (int root, EdgePoint pt1, EdgePoint pt2) const
 
int IntersectQuery (int faceID, const pair< EdgePoint, EdgePoint > &seg1, const pair< EdgePoint, EdgePoint > &seg2, EdgePoint &intersection) const
 
bool isBoundaryVert (int index) const
 
bool IsClosedModel () const
 
bool IsExtremeEdge (int edgeIndex) const
 
bool IsStartEdge (int edgeIndex) const
 
bool IsStronglyConvexVert (int index) const
 
bool IsWeaklyConvexVert (int index) const
 
void LoadModel ()
 
const vector< pair< int, double > > & Neigh (int root) const
 
void PreprocessBaseModel ()
 
void PrintInfo (ostream &out) const
 
double ProportionOnEdgeByImage (int edgeIndex, const pair< double, double > &coord) const
 
double ProportionOnEdgeByImage (int edgeIndex, double x1, double y1, double x2, double y2) const
 
double ProportionOnLeftEdgeByImage (int edgeIndex, const pair< double, double > &coord, double proportion) const
 
double ProportionOnRightEdgeByImage (int edgeIndex, const pair< double, double > &coord, double proportion) const
 
void SaveIsolineToObj (const vector< EdgePoint > &isoline, const string &filename) const
 
void SavePathToObj (const vector< EdgePoint > &pl, const string &filename) const
 
void SetEdgeLength (int leftVert, int rightVert, double newLength)
 
void SplitBasedOnScalarField (const vector< double > &scalarField, double val, const string &fileWithLargerScalars, const string &fileWithSmallerScalars)
 
int SplitEdge (const EdgePoint &ep)
 
- Public Member Functions inherited from CBaseModel
 CBaseModel (const string &filename)
 
const CFaceFace (int faceIndex) const
 
const vector< CBaseModel::CFace > & GetFaces () const
 
string GetFileFullName () const
 
string GetFileShortName () const
 
string GetFileShortNameWithoutExtension () const
 
int GetNumOfFaces () const
 
int GetNumOfVerts () const
 
double GetScale () const
 
CPoint3D GetShiftVertex (int indexOfVert) const
 
int GetVertexID (const CPoint3D &pt) const
 
const CPoint3DNormal (int vertIndex) const
 
void SaveMFile (const string &filename) const
 
void SaveObjFile (const string &filename) const
 
void SaveOffFile (const string &filename) const
 
void SavePamametrizationObjFile (const vector< pair< double, double >> &uvs, const string &filename) const
 
void SaveScalarFieldObjFile (const vector< double > &vals, const string &filename) const
 
void SaveScalarFieldObjFile (const vector< double > &vals, double maxV, const string &filename) const
 
void SaveScalarFieldObjFile (const vector< double > &vals, const string &comments, const string &filename) const
 
void SetFaces (const vector< CBaseModel::CFace > &faces)
 
const CPoint3DVert (int vertIndex) const
 

Protected Member Functions

void CollectAndArrangeNeighs ()
 
void ComputeAnglesAroundVerts ()
 
void ComputeNumOfComponents ()
 
void ComputeNumOfHoles ()
 
void ComputePlanarCoordsOfIncidentVertForEdges ()
 
void CreateEdgesFromVertsAndFaces ()
 
- Protected Member Functions inherited from CBaseModel
void ComputeScaleAndNormals ()
 
void ReadFile (const string &filename)
 
void ReadMFile (const string &filename)
 
void ReadObjFile (const string &filename)
 
void ReadOffFile (const string &filename)
 

Protected Attributes

vector< CEdgem_Edges
 
vector< pair< bool, bool > > m_FlagsForCheckingConvexVerts
 
double m_maxEdgeLength
 
int m_nBoundries
 
int m_nComponents
 
vector< vector< pair< int, double > > > m_NeighsAndAngles
 
int m_nIsolatedVerts
 
set< int > m_UselessEdges
 
- Protected Attributes inherited from CBaseModel
string m_filename
 
vector< CPoint3Dm_NormalsToVerts
 
double m_scale
 
set< int > m_UselessFaces
 

Additional Inherited Members

- Static Public Member Functions inherited from CBaseModel
static string GetComments (const char *filename)
 
static vector< double > GetScalarField (string filename)
 
- Public Attributes inherited from CBaseModel
vector< CFacem_Faces
 
vector< CPoint3Dm_Verts
 

Detailed Description

Definition at line 16 of file RichModel.h.

Constructor & Destructor Documentation

◆ CRichModel() [1/2]

CRichModel::CRichModel ( const string &  filename)

Definition at line 14 of file RichModel.cpp.

◆ CRichModel() [2/2]

CRichModel::CRichModel ( const vector< CPoint3D > &  verts,
const vector< CBaseModel::CFace > &  faces 
)

Definition at line 18 of file RichModel.cpp.

Member Function Documentation

◆ AngleSum()

double CRichModel::AngleSum ( int  vertIndex) const

Definition at line 399 of file RichModel.cpp.

◆ CollectAndArrangeNeighs()

void CRichModel::CollectAndArrangeNeighs ( )
protected

Definition at line 84 of file RichModel.cpp.

◆ ComputeAnglesAroundVerts()

void CRichModel::ComputeAnglesAroundVerts ( )
protected

Definition at line 148 of file RichModel.cpp.

◆ ComputeNumOfComponents()

void CRichModel::ComputeNumOfComponents ( )
protected

Definition at line 333 of file RichModel.cpp.

◆ ComputeNumOfHoles()

void CRichModel::ComputeNumOfHoles ( )
protected

Definition at line 303 of file RichModel.cpp.

◆ ComputePlanarCoordsOfIncidentVertForEdges()

void CRichModel::ComputePlanarCoordsOfIncidentVertForEdges ( )
protected

Definition at line 184 of file RichModel.cpp.

◆ CreateEdgesFromVertsAndFaces()

void CRichModel::CreateEdgesFromVertsAndFaces ( )
protected

Definition at line 25 of file RichModel.cpp.

◆ DistanceToLeftVert()

double CRichModel::DistanceToLeftVert ( int  edgeIndex,
const pair< double, double > &  coord 
) const

Definition at line 742 of file RichModel.cpp.

◆ DistanceToOppositeAngle()

double CRichModel::DistanceToOppositeAngle ( int  edgeIndex,
const pair< double, double > &  coord 
) const

Definition at line 735 of file RichModel.cpp.

◆ DistanceToRightVert()

double CRichModel::DistanceToRightVert ( int  edgeIndex,
const pair< double, double > &  coord 
) const

Definition at line 749 of file RichModel.cpp.

◆ Edge()

const CRichModel::CEdge & CRichModel::Edge ( int  edgeIndex) const

Definition at line 669 of file RichModel.cpp.

◆ FinishChangingEdgeLengths()

void CRichModel::FinishChangingEdgeLengths ( )

Definition at line 229 of file RichModel.cpp.

◆ GetBarycentricCoord()

CPoint3D CRichModel::GetBarycentricCoord ( CPoint3D  pt,
int  faceID 
) const

Definition at line 1113 of file RichModel.cpp.

◆ GetEdgeIndexFromTwoVertices()

int CRichModel::GetEdgeIndexFromTwoVertices ( int  leftVert,
int  rightVert 
) const

Definition at line 756 of file RichModel.cpp.

◆ GetMaxEdgeLength()

double CRichModel::GetMaxEdgeLength ( ) const

Definition at line 1097 of file RichModel.cpp.

◆ GetNew2DCoordinatesByReversingCurrentEdge()

pair< double, double > CRichModel::GetNew2DCoordinatesByReversingCurrentEdge ( int  edgeIndex,
const pair< double, double > &  input2DCoordinates 
) const

Definition at line 720 of file RichModel.cpp.

◆ GetNew2DCoordinatesByRotatingAroundLeftChildEdge()

pair< double, double > CRichModel::GetNew2DCoordinatesByRotatingAroundLeftChildEdge ( int  edgeIndex,
const pair< double, double > &  input2DCoordinates 
) const

Definition at line 706 of file RichModel.cpp.

◆ GetNew2DCoordinatesByRotatingAroundRightChildEdge()

pair< double, double > CRichModel::GetNew2DCoordinatesByRotatingAroundRightChildEdge ( int  edgeIndex,
const pair< double, double > &  input2DCoordinates 
) const

Definition at line 712 of file RichModel.cpp.

◆ GetNumOfBoundries()

int CRichModel::GetNumOfBoundries ( ) const

Definition at line 624 of file RichModel.cpp.

◆ GetNumOfComponents()

int CRichModel::GetNumOfComponents ( ) const

Definition at line 619 of file RichModel.cpp.

◆ GetNumOfEdges()

int CRichModel::GetNumOfEdges ( ) const

Definition at line 639 of file RichModel.cpp.

◆ GetNumOfGenera()

int CRichModel::GetNumOfGenera ( ) const

Definition at line 614 of file RichModel.cpp.

◆ GetNumOfIsolated()

int CRichModel::GetNumOfIsolated ( ) const

Definition at line 634 of file RichModel.cpp.

◆ GetNumOfTotalUndirectedEdges()

int CRichModel::GetNumOfTotalUndirectedEdges ( ) const

Definition at line 609 of file RichModel.cpp.

◆ GetNumOfValidDirectedEdges()

int CRichModel::GetNumOfValidDirectedEdges ( ) const

Definition at line 604 of file RichModel.cpp.

◆ GetSubindexToVert()

int CRichModel::GetSubindexToVert ( int  root,
int  neigh 
) const

Definition at line 725 of file RichModel.cpp.

◆ GetTwoSplitAngles()

pair< double, double > CRichModel::GetTwoSplitAngles ( int  root,
EdgePoint  pt1,
EdgePoint  pt2 
) const

Definition at line 409 of file RichModel.cpp.

◆ IntersectQuery()

int CRichModel::IntersectQuery ( int  faceID,
const pair< EdgePoint, EdgePoint > &  seg1,
const pair< EdgePoint, EdgePoint > &  seg2,
EdgePoint intersection 
) const

Definition at line 1067 of file RichModel.cpp.

◆ isBoundaryVert()

bool CRichModel::isBoundaryVert ( int  index) const

Definition at line 644 of file RichModel.cpp.

◆ IsClosedModel()

bool CRichModel::IsClosedModel ( ) const

Definition at line 629 of file RichModel.cpp.

◆ IsExtremeEdge()

bool CRichModel::IsExtremeEdge ( int  edgeIndex) const

Definition at line 659 of file RichModel.cpp.

◆ IsStartEdge()

bool CRichModel::IsStartEdge ( int  edgeIndex) const

Definition at line 664 of file RichModel.cpp.

◆ IsStronglyConvexVert()

bool CRichModel::IsStronglyConvexVert ( int  index) const

Definition at line 649 of file RichModel.cpp.

◆ IsWeaklyConvexVert()

bool CRichModel::IsWeaklyConvexVert ( int  index) const

Definition at line 654 of file RichModel.cpp.

◆ LoadModel()

void CRichModel::LoadModel ( )
virtual

Reimplemented from CBaseModel.

Definition at line 276 of file RichModel.cpp.

◆ Neigh()

const vector< pair< int, double > > & CRichModel::Neigh ( int  root) const

Definition at line 674 of file RichModel.cpp.

◆ PreprocessBaseModel()

void CRichModel::PreprocessBaseModel ( )

Definition at line 246 of file RichModel.cpp.

◆ PrintInfo()

void CRichModel::PrintInfo ( ostream &  out) const
virtual

Reimplemented from CBaseModel.

Definition at line 371 of file RichModel.cpp.

◆ ProportionOnEdgeByImage() [1/2]

double CRichModel::ProportionOnEdgeByImage ( int  edgeIndex,
const pair< double, double > &  coord 
) const

Definition at line 679 of file RichModel.cpp.

◆ ProportionOnEdgeByImage() [2/2]

double CRichModel::ProportionOnEdgeByImage ( int  edgeIndex,
double  x1,
double  y1,
double  x2,
double  y2 
) const

Definition at line 685 of file RichModel.cpp.

◆ ProportionOnLeftEdgeByImage()

double CRichModel::ProportionOnLeftEdgeByImage ( int  edgeIndex,
const pair< double, double > &  coord,
double  proportion 
) const

Definition at line 691 of file RichModel.cpp.

◆ ProportionOnRightEdgeByImage()

double CRichModel::ProportionOnRightEdgeByImage ( int  edgeIndex,
const pair< double, double > &  coord,
double  proportion 
) const

Definition at line 698 of file RichModel.cpp.

◆ SaveIsolineToObj()

void CRichModel::SaveIsolineToObj ( const vector< EdgePoint > &  isoline,
const string &  filename 
) const

Definition at line 972 of file RichModel.cpp.

◆ SavePathToObj()

void CRichModel::SavePathToObj ( const vector< EdgePoint > &  pl,
const string &  filename 
) const

Definition at line 926 of file RichModel.cpp.

◆ SetEdgeLength()

void CRichModel::SetEdgeLength ( int  leftVert,
int  rightVert,
double  newLength 
)

Definition at line 390 of file RichModel.cpp.

◆ SplitBasedOnScalarField()

void CRichModel::SplitBasedOnScalarField ( const vector< double > &  scalarField,
double  val,
const string &  fileWithLargerScalars,
const string &  fileWithSmallerScalars 
)

Definition at line 992 of file RichModel.cpp.

◆ SplitEdge()

int CRichModel::SplitEdge ( const EdgePoint ep)

Definition at line 763 of file RichModel.cpp.

Member Data Documentation

◆ m_Edges

vector<CEdge> CRichModel::m_Edges
protected

Definition at line 110 of file RichModel.h.

◆ m_FlagsForCheckingConvexVerts

vector<pair<bool, bool> > CRichModel::m_FlagsForCheckingConvexVerts
protected

Definition at line 114 of file RichModel.h.

◆ m_maxEdgeLength

double CRichModel::m_maxEdgeLength
protected

Definition at line 109 of file RichModel.h.

◆ m_nBoundries

int CRichModel::m_nBoundries
protected

Definition at line 106 of file RichModel.h.

◆ m_nComponents

int CRichModel::m_nComponents
protected

Definition at line 108 of file RichModel.h.

◆ m_NeighsAndAngles

vector<vector<pair<int, double> > > CRichModel::m_NeighsAndAngles
protected

Definition at line 112 of file RichModel.h.

◆ m_nIsolatedVerts

int CRichModel::m_nIsolatedVerts
protected

Definition at line 107 of file RichModel.h.

◆ m_UselessEdges

set<int> CRichModel::m_UselessEdges
protected

Definition at line 111 of file RichModel.h.


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


co_scan
Author(s):
autogenerated on Mon Feb 28 2022 23:00:58