149 lines
6.4 KiB
C++
149 lines
6.4 KiB
C++
// 暖通吸尘罩实现类 mcl add 2011.2.16
|
|
|
|
#if !defined(AFX_THIMPHVACDEDUSTCOVER_H__F596F8B5_3456_427D_B486_F2009656B66C__INCLUDED_)
|
|
#define AFX_THIMPHVACDEDUSTCOVER_H__F596F8B5_3456_427D_B486_F2009656B66C__INCLUDED_
|
|
|
|
#if _MSC_VER > 1000
|
|
#pragma once
|
|
#endif // _MSC_VER > 1000
|
|
|
|
#include "TImpSpecEquipment.h"
|
|
|
|
class THImpHvacDeDustCover : public TImpSpecEquipment
|
|
{
|
|
public:
|
|
THImpHvacDeDustCover();
|
|
virtual ~THImpHvacDeDustCover();
|
|
|
|
// 接口描述对象
|
|
virtual BOOL GetInterface(int nIndex,TInterface& pipeInterface) const;
|
|
virtual BOOL GetInterface(const AcGePoint3d& ptCon,TInterface& pipeInterface) const;
|
|
|
|
virtual BOOL HasInterface(const AcGePoint3d& ptCon,const AcGeVector3d& vtDir);
|
|
virtual int GetInterfaceCount() const;
|
|
|
|
// 建立接口关联关系
|
|
virtual BOOL SetInterfaceRelation(const AcGePoint3d& ptConnect,const AcDbObjectId& idConnect);
|
|
|
|
//移除接口关联关系
|
|
virtual BOOL RemoveInterfaceRelation(const AcGePoint3d& ptConnect,const AcDbObjectId& idConnect);
|
|
|
|
// 接口更改通知
|
|
virtual BOOL NotifyInterfaceToModify(const TInterfaceModifyMsg& iModiMsg,TInterfaceModifyMsgs& iModiMsgs);
|
|
|
|
// 夹点移动消息处理
|
|
BOOL OnMoveGripPointMsgNotify(const TInterfaceModifyMsg& iModiMsg, TInterfaceModifyMsgs& iModiMsgs);
|
|
|
|
// 除尘罩是否竖直放置(风管接口方向垂直向上)
|
|
BOOL IsVertAlignment() const;
|
|
|
|
// 除尘罩是否水平放置(风管接口方向垂直于Z轴,侧吸式,法向在XY平面)
|
|
BOOL IsHorzAligment() const;
|
|
|
|
// 获取2维显示的所有曲线
|
|
virtual BOOL MakeCurves(TComplexCurve& cplCurve) const;
|
|
|
|
// 获取2维边界内显示的曲线
|
|
virtual BOOL GetCurvesInSide(TComplexCurve& compCurve) const;
|
|
|
|
// 获取2维显示的边界pl线
|
|
virtual AcDbPolyline* MakePolyCurve() const;
|
|
|
|
// 获取2维边界围城的面
|
|
virtual BOOL MakePolyCurveFaces(AcDbVoidPtrArray& arFaces);
|
|
|
|
// 获取对象类型名称 [es. 弯头--> TCH_EELBOW]
|
|
virtual void GetKindName(CString& sName);
|
|
|
|
// 解释夹点
|
|
virtual TDb::Position ExplainGripIndex(int nIndex) const;
|
|
|
|
// 夹点提示
|
|
virtual Acad::ErrorStatus GetGripText(int i, CString &cs) const;
|
|
|
|
// 对象查询
|
|
virtual void GetTips(CMapStringToString& mapLable2Tip) const;
|
|
|
|
//获取三维的壳对象
|
|
virtual int GetXBaseShell(TXShell& xShell);
|
|
|
|
//获取体的范围方块
|
|
virtual int GetBodyBox(AcDbExtents& ext) const;
|
|
|
|
// add by hh 2010-12-27 导出XML
|
|
// virtual CString GetXml() const;
|
|
virtual CString GetXml(const AcGeMatrix3d& mat) const;
|
|
|
|
// add by hh 2011.10.27 除尘罩的三维剖切
|
|
virtual bool GetSection(const AcDbFace &face, const AcGeVector3d &vtPlaneSecDir,
|
|
std::vector<TObjSectionRecord> §ionRecord, AcDbVoidPtrArray& arFillPtrs) const;
|
|
|
|
public:
|
|
|
|
//{{AFX_ARX_METHODS(TImpSpecEquipment)
|
|
virtual Acad::ErrorStatus ExplodeOrDraw2d(XExplodeDraw &mode) const;
|
|
virtual Acad::ErrorStatus ExplodeOrDraw3d(XExplodeDraw &mode) const;
|
|
virtual void list() const;
|
|
virtual Acad::ErrorStatus transformBy(const AcGeMatrix3d& xform);
|
|
virtual Acad::ErrorStatus moveGripPointsAt(const AcDbIntArray& indices,
|
|
const AcGeVector3d& offset);
|
|
virtual Acad::ErrorStatus moveStretchPointsAt(const AcDbIntArray& indices,
|
|
const AcGeVector3d& offset);
|
|
Acad::ErrorStatus getStretchPoints(AcGePoint3dArray& stretchPoints) const;
|
|
virtual Acad::ErrorStatus intersectWith(const AcDbEntity* pEnt,
|
|
AcDb::Intersect intType,
|
|
const AcGePlane& projPlane,
|
|
AcGePoint3dArray& points,
|
|
INT_PTR thisGsMarker = 0,
|
|
INT_PTR otherGsMarker = 0) const;
|
|
virtual Acad::ErrorStatus intersectWith(const AcDbEntity* pEnt,
|
|
AcDb::Intersect intType,
|
|
AcGePoint3dArray& points,
|
|
INT_PTR thisGsMarker = 0,
|
|
INT_PTR otherGsMarker = 0) const;
|
|
virtual Acad::ErrorStatus getOsnapPoints(AcDb::OsnapMode osnapMode,
|
|
INT_PTR gsSelectionMark,
|
|
const AcGePoint3d& pickPoint,
|
|
const AcGePoint3d& lastPoint,
|
|
const AcGeMatrix3d& viewXform,
|
|
AcGePoint3dArray& snapPoints,
|
|
AcDbIntArray& geomIds) const;
|
|
virtual Acad::ErrorStatus getGripPoints(AcGePoint3dArray& gripPoints,
|
|
AcDbIntArray& osnapModes,
|
|
AcDbIntArray& geomIds) const;
|
|
virtual Acad::ErrorStatus getGeomExtents(AcDbExtents& extents) const;
|
|
virtual Acad::ErrorStatus getClassID(CLSID* pClsid) const;
|
|
virtual Acad::ErrorStatus explode(AcDbVoidPtrArray& entitySet) const;
|
|
virtual BOOL OPMInfo(LPCTSTR pszName, TDb::OPMInfo* pInfo);
|
|
//virtual AecObjectEditMethod GetEditMethod() const;
|
|
//}}AFX_ARX_METHODS
|
|
|
|
|
|
private:
|
|
Acad::ErrorStatus Draw2dBox(XExplodeDraw &mode) const;
|
|
BOOL GetBoxPts(AcGePoint3dArray &arPts) const;
|
|
AcGeVector3d GetNormal() const;
|
|
Acad::ErrorStatus InserBlockCen(XExplodeDraw &mode,AcDbObjectId idBlock) const;
|
|
Acad::ErrorStatus InserBlockHand(XExplodeDraw &mode) const;
|
|
BOOL GetInterfaceSizeData(int nIndex, TInterface& pipeInterface) const;
|
|
//得到接口的位置信息接口nIndex需要-1因为第一个接口为设备位置点。
|
|
BOOL GetInterFaceLocal(AcGePoint3dArray& arpts) const;
|
|
BOOL SetInterFaceLocal(const AcGeMatrix3d& xform) const;
|
|
BOOL SetInterFaceLocal(const AcGeScale3d& scale3d) const;
|
|
BOOL GetInterFaceLocal(int nIndex, int &nType) const;
|
|
BOOL GetInterFaceLocal(int nIndex, CString &sName) const;
|
|
BOOL GetInterFaceLocal(int nIndex, AcGePoint3d &pt) const;
|
|
BOOL GetInterFaceLocal(int nIndex, AcGeVector3d &vt) const;
|
|
BOOL GetInterFaceLocal(int nIndex, double &dWidth, double &dHeight) const;
|
|
BOOL GetIFIndexFormPt(int &nIndex, const AcGePoint3d &pt) const;
|
|
//为移动设备接口,接口线跟着走所设
|
|
BOOL GetInterfaceFromXdata(const int& nIndex, const AcGeVector3d& vtOff) const;
|
|
|
|
void GetFourConer(AcGePoint3dArray &arrPt) const;
|
|
|
|
void CheckIfPostion() const; // 根据直径、是否超出边界,校核接口位置
|
|
|
|
};
|
|
|
|
#endif // !defined(AFX_THIMPHVACDEDUSTCOVER_H__F596F8B5_3456_427D_B486_F2009656B66C__INCLUDED_)
|