Files
gjm 164968b62e chore
把非utf8-bom编码的cpp/h文件改为 utf8 bom 编码, msvc识别utf8编码时,如果不是bom格式的,会使用当前cp_oem来解码.
2026-10-04 00:04:20 +08:00

48 lines
955 B
C++

//-----------------------------------------------------------------------------+
// Copyright (C), 1998-2007, Beijing Tangent Software Co. Ltd.
// = FileName : TGGeLineDist 类
// = Version : ver2.0
// = Author : wlw
// = CreateDate : 2002-09-09
// = Description: TGGeLineDist 类定义
// = Maintainers:
//
//-----------------------------------------------------------------------------+
#include "StdAfx.h"
#include "TGGeLineDist.h"
int TGGeLineDist::Compare(const TGGeLineDist *p1, const TGGeLineDist *p2)
{
if (p1->nDist < _DIST_SNAP)
{
return 1;
}
if (p2->nDist < _DIST_SNAP)
{
return -1;
}
if (fabs(p1->nDist - p2->nDist) < _DIST_SNAP)
{
return 0;
}
if (p1->nDist > p2->nDist)
{
return 1;
}
return -1;
}
TGGeLineDist::TGGeLineDist(ads_real nD, const TADSGePoint3d &pt1, const TADSGePoint3d &pt2)
: nDist(nD), ptLocation1(pt1), ptLocation2(pt2)
{
}
TGGeLineDist::~TGGeLineDist()
{
}