|
xmsgrid
1.0
|
Used to delete points that are connected to 4 triangles and then retriangulate the void. More...
Public Member Functions | |
| TrAutoFixFourTrianglePtsImpl () | |
| constructor | |
| virtual void | Fix (BSHP< TrTin > a_tin) override |
| Removes any points in the tin that are connected to only 4 triangles. These points usually cause poorly formed elements in the mesher. More... | |
| virtual void | SetObserver (BSHP< Observer > a_) override |
| Set the observer to use for feedback while processing. More... | |
| virtual void | SetUndeleteablePtIdxs (VecInt &a_ptIdx) override |
| Set the indexes of points that can not be deleted. More... | |
| void | FillAdjTrisIfNeeded () |
| Makes sure the adjacent triangles exist in the TIN. | |
| void | GetPtsAndTrisToDelete () |
| Finds and removes the points connected to 4 triangles. | |
| std::pair< int, int > | EdgeOppositePt (int a_ptIdx, int a_tri, VecInt &a_tris) |
| Finds and removes the points connected to 4 triangles. More... | |
| void | MakeTwoNewTriangles (VecPt3d &a_pts, std::map< int, int > a_edges, int a_tris[2][3]) |
| Makes 2 new triangles from the 4 edges passed into this method. More... | |
| void | ReplaceTriangle (int &a_tIdx, int a_newTri[3], VecInt &a_tris) |
| Makes 2 new triangles from the 4 edges passed into this method. More... | |
| void | RenumberPts () |
| Renumbers the point indexes in the triangles. | |
| void | RenumberTris () |
| Renumbers the triangle indexes in the adjacent triangles. | |
| void | RemovePts () |
| Removes points from the points vector of the TIN. | |
| void | RemoveTris () |
| Removes triangles from the triangles vector in the TIN. | |
| void | ClearAdjTrisIfCreated () |
| Clears the adjacent triangles if this class created them. | |
Private Attributes | |
| BSHP< TrTin > | m_tin |
| tin | |
| BSHP< Observer > | m_observer |
| Observer. | |
| bool | m_removeAdjTris |
| flag to remove adjacent tris when done | |
| SetInt | m_ptsToDelete |
| points in the TIN that will be deleted | |
| SetInt | m_trisToDelete |
| triangles that will be deleted | |
| SetInt | m_noDelete |
| indexes of points that can't be deleted | |
Additional Inherited Members | |
Static Public Member Functions inherited from xms::TrAutoFixFourTrianglePts | |
| static BSHP< TrAutoFixFourTrianglePts > | New () |
| Creates a TrAutoFixFourTrianglePtsImpl object. More... | |
Used to delete points that are connected to 4 triangles and then retriangulate the void.
Definition at line 41 of file TrAutoFixFourTrianglePts.cpp.
| std::pair< int, int > xms::TrAutoFixFourTrianglePtsImpl::EdgeOppositePt | ( | int | a_ptIdx, |
| int | a_tri, | ||
| VecInt & | a_tris | ||
| ) |
Finds and removes the points connected to 4 triangles.
| [in] | a_ptIdx | : A point on a triangle |
| [in] | a_tri | : The index to the triangle |
| [in] | a_tris | : Array of triangles |
Definition at line 174 of file TrAutoFixFourTrianglePts.cpp.
Referenced by GetPtsAndTrisToDelete().
Removes any points in the tin that are connected to only 4 triangles. These points usually cause poorly formed elements in the mesher.
| [in,out] | a_tin | The tin to be modified. |
Definition at line 113 of file TrAutoFixFourTrianglePts.cpp.
References ClearAdjTrisIfCreated(), FillAdjTrisIfNeeded(), GetPtsAndTrisToDelete(), m_tin, RemovePts(), RemoveTris(), RenumberPts(), and RenumberTris().
Referenced by TrAutoFixFourTrianglePtsUnitTests::test1().
| void xms::TrAutoFixFourTrianglePtsImpl::MakeTwoNewTriangles | ( | VecPt3d & | a_pts, |
| std::map< int, int > | a_edges, | ||
| int | a_tris[2][3] | ||
| ) |
Makes 2 new triangles from the 4 edges passed into this method.
| [in] | a_pts | : Array of point locations in the TIN |
| [in] | a_edges | : A map of edges that surround the point that is being removed. |
| [out] | a_tris | : Array of point indexes that will define the new triangles |
Definition at line 201 of file TrAutoFixFourTrianglePts.cpp.
References MdistSq(), xms::Pt3< T >::x, and xms::Pt3< T >::y.
Referenced by GetPtsAndTrisToDelete().
| void xms::TrAutoFixFourTrianglePtsImpl::ReplaceTriangle | ( | int & | a_tIdx, |
| int | a_newTri[3], | ||
| VecInt & | a_tris | ||
| ) |
Makes 2 new triangles from the 4 edges passed into this method.
| [in] | a_tIdx | : Index to a triangle that will be replaced |
| [in] | a_newTri | : Point indexes that define a new triangle |
| [in,out] | a_tris | : The triangles in the TIN |
Definition at line 241 of file TrAutoFixFourTrianglePts.cpp.
Referenced by GetPtsAndTrisToDelete().
|
inlineoverridevirtual |
Set the observer to use for feedback while processing.
| a_ | The observer. |
Definition at line 51 of file TrAutoFixFourTrianglePts.cpp.
References m_observer.
|
inlineoverridevirtual |
Set the indexes of points that can not be deleted.
| [in] | a_ptIdx | : The indexes of points that can't be deleted |
Definition at line 54 of file TrAutoFixFourTrianglePts.cpp.
References m_noDelete.