Files
envi-code/SourceCode/Code2026/tg_shs/inc/subgeo/TPGeCurveMesh.h
T

78 lines
1.6 KiB
C++
Raw Normal View History

2026-10-04 00:04:20 +08:00
//-------------------------------------------------------------------------------------------------------+
2026-09-28 15:28:50 +08:00
// Copyright (C), 1998-2007, Beijing Tangent Software Co. Ltd.
2026-10-04 00:04:20 +08:00
// = FileName : TPGeCurveMesh 类
2026-09-28 15:28:50 +08:00
// = Version : ver2.0
// = Author : wlw
// = CreateDate : 2002-09-09
2026-10-04 00:04:20 +08:00
// = Description: TPGeCurveMesh 声明 拓扑网络
2026-09-28 15:28:50 +08:00
// = Maintainers:
//
//-------------------------------------------------------------------------------------------------------+
#ifndef _TPGECURVEMESH_H_
#define _TPGECURVEMESH_H_
#ifndef _TPDLIST_H_
#include "TPDList.h"
#endif
#ifndef _TGMESH_H_
#include "TGMesh.h"
#endif
#ifndef _TGMESHNODE_H_
#include "TGMeshNode.h"
#endif
class GEOAPI TPGeCurveMesh
{
friend class TPGeCurveMesh;
public:
2026-10-04 00:04:20 +08:00
//要求输入曲线是完全打断的,但允许有重线
2026-09-28 15:28:50 +08:00
TPGeCurveMesh(const TGObjectList &buf,bool bOnlyClose = true);
virtual ~TPGeCurveMesh();
void AppendCurve(const TPGeCurve2D* pCurve);
2026-10-04 00:04:20 +08:00
//去开放边
2026-09-28 15:28:50 +08:00
void RemoveOpenEdge();
void FindAllMesh();
2026-10-04 00:04:20 +08:00
//按原曲线方向搜索边界路径
2026-09-28 15:28:50 +08:00
void FindAllSDMesh();
void CreateRegion(TGObjectList& lstRegion,TGObjectList& lstHole);
2026-10-04 00:04:20 +08:00
//根据连接关系分解为独立的子网
2026-09-28 15:28:50 +08:00
void Explode(TPDList<TPGeCurveMesh> &lstChildMesh);
bool operator > (const TPGeCurveMesh&) const;
bool operator < (const TPGeCurveMesh&) const;
public:
2026-10-04 00:04:20 +08:00
//结果
2026-09-28 15:28:50 +08:00
TPDList< TGMesh > m_allMesh;
protected:
TPGeCurveMesh();
TGMeshNode* FindOrAddNode(const TGPoint&pt);
protected:
2026-10-04 00:04:20 +08:00
//所有节点
2026-09-28 15:28:50 +08:00
TPDListEx<TGMeshNode> m_allNode;
2026-10-04 00:04:20 +08:00
//所有边
2026-09-28 15:28:50 +08:00
TPDList<TGMeshEdge> m_allEdge;
};
#endif