[求助]如何给地形线增加Z坐标?
在CAD里如何给圆弧\样条曲线增加Z坐标? 可在PROPERTIES栏中修改。 这我知道,我是想知道有什么更快的方法. 这就是最快的吧?要再想快就只能靠编程序啦? 可以参考一下。记得在Vhcad 4.1.1中也有。(defun c:ZQ ()<BR> (setvar "cmdecho" 0)<BR> (setq elev (getreal "输入归位的高度: "))<BR> (if (= elev nil) (setq elev 0))<BR> (setq ss (ssget))<BR> (if (= ss nil) (princ "0 个对象被执行。")<BR> (progn<BR> (setq Num1 (sslength ss))<BR> (command "change" ss "" "p" "E" elev "")<BR> (setq i 0)<BR> (while (setq ent (ssname ss i))<BR> (setq entlist (entget ent))<BR> (setq entlist (change_point entlist 10 elev))<BR> (cond ((or (eq (cdr (assoc 0 entlist)) "3DFACE")<BR> (eq (cdr (assoc 0 entlist)) "SOLID"))<BR> (setq entlist (change_point entlist 11 elev))<BR> (setq entlist (change_point entlist 12 elev))<BR> (setq entlist (change_point entlist 13 elev))<BR> )<BR> ((eq (cdr (assoc 0 entlist)) "LINE")<BR> (setq entlist (change_point entlist 11 elev))<BR> )<BR> ((eq (cdr (assoc 0 entlist)) "POLYLINE")<BR> (cond ((eq 8 (boole 1 (cdr (assoc 70 entlist)) 8))<BR> (while (eq "VERTEX" (cdr (assoc 0 (setq entlist (entget (setq ent (entnext ent)))))))<BR> (setq entlist (change_point entlist 10 elev))<BR> <BR> )<BR> )<BR> )<BR> )<BR> )<BR> (setq i (1+ i))<BR> )<BR> (princ Num1)(princ "个对象被执行")<BR> )<BR>)<BR> (command "regenall")<BR> (setvar "cmdecho" 1)<BR>)
(defun change_point (elist point el)<BR> (setq xyz (assoc point elist))<BR> (setq elist <BR> (subst <BR> (list point (nth 1 xyz) (nth 2 xyz) el) <BR> (assoc point elist)<BR> elist<BR> )<BR> )<BR> (entmod elist)<BR> (setq elist elist)<BR>)
(princ)<BR> 非常感谢,送你一支鲜花! 请问如何才能实现每个节点的动态Z坐标输入?比如说样条曲线,它有多个节点,每个节点的标高不一样,如何在命令提示窗口中动态操作? 在控制栏选拟合点修改坐标。 我需要的是LISP程序.
页:
[1]