Files
envi-code/SourceCode/Code2026/tg_shs/inc/subgeo/TPGeDscEdge.h
T
2026-09-28 15:28:50 +08:00

76 lines
1.6 KiB
C++

//-------------------------------------------------------------------------------------------------------+
// Copyright (C), 1998-2007, Beijing Tangent Software Co. Ltd.
// = FileName : TPGeDscEdge 类
// = Version : ver2.0
// = Author : wlw
// = CreateDate : 2002-09-09
// = Description: TPGeDscEdge 声明 离散无向边集合
// = Maintainers:
//
//-------------------------------------------------------------------------------------------------------+
#ifndef _TPGEDSCEDGE_H_
#define _TPGEDSCEDGE_H_
#ifndef _TWFLAG_H_
#include "TWFlag.h"
#endif
#ifndef _TPGEFITPATH_H_
#include "TPGeFitPath.h"
#endif
#ifndef _TPGEEXTEND2D_H_
#include "TPGeExtend2D.h"
#endif
class TPGeGLineSeg2D;
class TPGeDscPoint;
class TPGeFitTriangle;
class GEOAPI TPGeDscEdge : public TWFlag
{
public:
//同时建立点连接!
TPGeDscEdge(TPGeDscPoint* p0,TPGeDscPoint* p1,double len = 0);
virtual ~TPGeDscEdge();
//取另一个点
TPGeDscPoint* GetNextPoint(TPGeDscPoint* pPt) const;
//判断两边是否交叉、重叠
bool IsCrossWith(TPGeDscEdge* pEdge) const;
//计算一般线性插值点,失败返回NULL
TPGeDscPoint* GetFitPoint(double dz);
//从这一边起构造拟合路径,沿途边加VISITED标志
void ConnectPath(TPGeFitPath& path);
void GetExtend2D(TPGeExtend2D& ext);
TPGeGLineSeg2D* CreateEdge();
double GetMinZ();
bool operator >(const TPGeDscEdge& e) const;
bool operator <(const TPGeDscEdge& e) const;
public:
//第一点,第二点<引用>
TPGeDscPoint*pPt0,*pPt1;
//当前拟合点<引用>
TPGeDscPoint*pPtFit;
//边长
double length;
//相领的两个三角
TPGeFitTriangle* pTrgLeft,*pTrgRight;
};
#endif