qcw911 发表于 2013-1-17 09:33:07

【求助】画pL线生成相应的图形

大家好
小弟新手
麻烦大家帮忙一下

1、画pl线
2、pl线向外便宜a距离
3、两端封口
4、外面所有角进行倒圆角半径为a距离
5、然后填充
注:pl线形状为任意状 也可是拐直角、也可能是弓字形

谢谢大家,必有重谢

Gu_xl 发表于 2013-1-17 10:26:02


(defun c:tt (/ e1 e2 l1 l2 d pt)
(setq e1 (car(entsel "\n选择多段线:")))
(setq d (getdist "\n偏移距离:"))
(setq pt (getpoint "\n偏移方向点:"))
(command "offset" d e1 pt "")
(setq e2 (entlast))
(command "FILLET" "r" d "FILLET" "p" e2)
(entmake
    (list '(0 . "line")
          (cons 10 (vlax-curve-getStartPoint e1))
          (cons 11 (vlax-curve-getStartPoint e2))
          )
    )
(setq l1 (entlast))
(entmake
    (list '(0 . "line")
          (cons 10 (vlax-curve-getEndPoint e1))
          (cons 11 (vlax-curve-getEndPoint e2))
          )
    )
(setq l2 (entlast))
(command "bhatch" "p" "ANSI31" 1 0 "s" e1 e2 l1 l2 "" "")
(princ)
)

xiabin68 发表于 2013-1-17 13:36:06

好代码,,,,,,,,,,,

zyhandw 发表于 2013-1-17 13:47:45

G版好快

ScmTools 发表于 2013-1-17 18:37:23

为何不直接参数绘图
页: [1]
查看完整版本: 【求助】画pL线生成相应的图形