77 lines
1.8 KiB
C++
77 lines
1.8 KiB
C++
//-----------------------------------------------------------------------------+
|
|
// Copyright (C), 1998-2007, Beijing Tangent Software Co. Ltd.
|
|
// = FileName : TGGiUcsDrawStream Àà
|
|
// = Version : ver2.0
|
|
// = Author : wlw
|
|
// = CreateDate : 2002-09-09
|
|
// = Description: TGGiUcsDrawStream ¶¨Òå
|
|
// = Maintainers:
|
|
//
|
|
//-----------------------------------------------------------------------------+
|
|
#include "StdAfx.h"
|
|
#include "TGGiUcsDrawStream.h"
|
|
#include "TchGlobalFunc.h"
|
|
#include "TchPrivateGlobalFunc.h"
|
|
|
|
TGGiUcsDrawStream::TGGiUcsDrawStream()
|
|
{
|
|
TCHAR szLay[80] = _T("");
|
|
TGGetVar(_T("CLAYER"), szLay);
|
|
sLayer = szLay;
|
|
}
|
|
|
|
TGGiUcsDrawStream::~TGGiUcsDrawStream()
|
|
{
|
|
|
|
}
|
|
|
|
void TGGiUcsDrawStream::DrawXPoint(const TADSGePoint3d &pt)
|
|
{
|
|
TADSGePoint3d ptTmp = Ucs2Wcs(pt);
|
|
ptTmp.Make(sLayer);
|
|
}
|
|
|
|
void TGGiUcsDrawStream::DrawX3DFace(const TGGe3DFace &face)
|
|
{
|
|
TGGe3DFace faceTmp(face);
|
|
for (int i = 0; i < 4; i++)
|
|
{
|
|
faceTmp.SetVertex(i, Ucs2Wcs(faceTmp.GetVertex(i)));
|
|
}
|
|
|
|
faceTmp.Make(sLayer);
|
|
}
|
|
|
|
void TGGiUcsDrawStream::DrawXPoly(const TGGePoly2D &poly, double nThick)
|
|
{
|
|
TGGePoly2D polyTmp(poly);
|
|
TGroups g1(1), g0(0);
|
|
polyTmp.TransUCS((resbuf *)&g1, (resbuf *)&g0);
|
|
polyTmp.Make(sLayer);
|
|
}
|
|
|
|
void TGGiUcsDrawStream::DrawXCurve(const TGGeCurveSegment &cvCurve, double nThick)
|
|
{
|
|
TGGeCurveSegment cvTmp=cvCurve;
|
|
TGroups g1(1), g0(0);
|
|
cvTmp.TransUCS((resbuf *)&g1, (resbuf *)&g0);
|
|
cvTmp.Make(sLayer);
|
|
}
|
|
|
|
void TGGiUcsDrawStream::DrawXEntity(const TEntitySet &eEnt)
|
|
{
|
|
TEntitySet ent = eEnt;
|
|
TGroups g(_T("*"));
|
|
TRBList rbBuf = ads_entgetx(ent, (resbuf *)& g);
|
|
ads_entmake(rbBuf);
|
|
}
|
|
|
|
const TCHAR * TGGiUcsDrawStream::Descriptor()
|
|
{
|
|
return _T("TGGiUcsDrawStream");
|
|
}
|
|
|
|
const TCHAR * TGGiUcsDrawStream::Desc()
|
|
{
|
|
return Descriptor();
|
|
} |