赞
踩
三点引线附着块参照实例
- // 创建AcDbLeader引线
- ads_point p1,p2,p3;
- if (RTNORM != acedGetPoint(NULL,_T("\n请选择引线第一点: "),p1))
- return;
- if (RTNORM != acedGetPoint(p1,_T("\n请选择引线第二点: "),p2))
- return;
- if (RTNORM != acedGetPoint(p2,_T("\n请选择引线第三点: "),p3))
- return;
- // ucs点转换到wcs点
- acdbUcs2Wcs(p1,p1,false);
- acdbUcs2Wcs(p2,p2,false);
- acdbUcs2Wcs(p3,p3,false);
- // ads点转为AcGe点
- AcGePoint3d pt1=asPnt3d(p1);
- AcGePoint3d pt2=asPnt3d(p2);
- AcGePoint3d pt3=asPnt3d(p3);
- // 设置第三点为第二点的水平点
- pt3.y=pt2.y;
-
- AcDbDatabase *pDb=acdbHostApplicationServices()->workingDatabase();
- // 使用智能指针打开块表
- AcDbBlockTablePointer pBlkTbl(
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。