用lisp语言画个奥运五环,需要完整编写程序,急等
2016-06-23
展开全部
下面是我写的程序有什么问题加QQ584963273共同学习
(defun c:wh ()
(setq os (getvar "osmode"))
(setvar "osmode" 0)
(setq p1 (getpoint ":指定第一个圆心位置"))
(setq r (getdist ":指定半径"))
(setq p2 (polar p1 (* -0.25 pi) r))
(setq p3 (polar p2 (* 0.25 pi) r))
(setq p4 (polar p3 (* -0.25 pi) r))
(setq p5 (polar p4 (* 0.25 pi) r))
(command "color" "blue")(command "circle" p1 r)
(command "color" "yellow")(command "circle" p2 r)
(command "color" "white")(command "circle" p3 r)
(command "color" "green")(command "circle" p4 r)
(command "color" "red")(command "circle" p5 r)
(setvar "osmode" os)
(princ)
)
(defun c:wh ()
(setq os (getvar "osmode"))
(setvar "osmode" 0)
(setq p1 (getpoint ":指定第一个圆心位置"))
(setq r (getdist ":指定半径"))
(setq p2 (polar p1 (* -0.25 pi) r))
(setq p3 (polar p2 (* 0.25 pi) r))
(setq p4 (polar p3 (* -0.25 pi) r))
(setq p5 (polar p4 (* 0.25 pi) r))
(command "color" "blue")(command "circle" p1 r)
(command "color" "yellow")(command "circle" p2 r)
(command "color" "white")(command "circle" p3 r)
(command "color" "green")(command "circle" p4 r)
(command "color" "red")(command "circle" p5 r)
(setvar "osmode" os)
(princ)
)
追问
大神,能不能帮我将每个圆环的线条变得粗一些,修改在命令中,谢了
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询