转换3DFACE到POLYLINE
Converting 3dface to a polylineIssue
How do I convert 3dFaces to polylines ?
Solution
There's no mechanism available to do this directly. What you'll need to do is
collect the 3dFace vertex data, and create a polyline using that information.
Since a 3dFace will probably be construced with differing X,Y, and Z coordinates
you can only re-create them as a 3dPolyline. If the face's Z coordinates are on
the same elevation, you could re-create them as a 2d polyline. Here's some lisp
code to demonstrate this:
**** Hidden Message *****
辛苦了,因为你们有更多的人进步
回复看看!:lol 还有更简单的?
(defun c:tt ()
(fy:begin)
(if (ssget '((0 . "3dface")))
(progn (mapcar '(lambda (x)
(vlax-put (vlax-invoke
(fy:acspace)
'Add3dPoly
(vlax-get x 'Coordinates)
)
"Closed"
:vlax-true
)
)
(fy:cset->objs)
)
(vl-cmdf ".erase" "P" "")
)
)
(princ)
)
代码还应考虑下ucs和捕捉的问题!
(command "3DPOLY" "non" (trans pt1 0 1) "non" (trans pt2 0 1) "non" (trans pt3 0 1))
xuexi Le
看看什么方法.... 学习了 看看学习一下
3d线转pline? 回复看看!
谢谢分享~~~ 这东西不错 学习学习学习学习学习学习
学习!!!!!!!!!!!!!!!!!!!!!