作者sjgau (sjgau)
看板Cad_Cae
标题Re: [问题] autolisp指令
时间Fri Sep 10 06:25:12 2010
下面是 原厂的 on-line help 所给的说明。
polar
Returns the UCS 3D point at a specified angle and distance from a point
(polar pt ang dist)Arguments
pt
A 2D or 3D point.
ang
An angle expressed in radians relative to the world X axis. Angles increase
in the counterclockwise direction, independent of the current construction
plane.
dist
Distance from the specified pt.
Return Values
A 2D or 3D point, depending on the type of point specified by pt.
Examples
Supplying a 3D point to polar:
Command: (polar '(1 1 3.5) 0.785398 1.414214)
// 从 座标点 '(x y z) 沿着 theta 角 ,使用 弪度量计算的角度,
前进 s 的距离,会 return 一个新的 座标点
(2.0 2.0 3.5)
Supplying a 2D point to polar:
Command: (polar '(1 1) 0.785398 1.414214)
(2.0 2.0)
※ 引述《kihg (值得努力)》之铭言:
: 请问用lisp写 (polar x (* pi (/ 75 180)) y))
// x 的地方,应该使用一个点的座标
角度的计算,必须使用
(* (/ 75.0 180.0) pi)
y 的地方,必须是一个 前进的距离
: 为什麽跑出来的都是一条水平线?
: 照理说不是应该是75度的直线嘛?
: 还是有其他问题?
: 谢谢
--
e-mail:
[email protected]
我的课程介绍网页:
http://www.csie.ntu.edu.tw/train/teacher_display.php?num=18
AutoCAD 台湾地区菁英讲师获选
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 118.231.81.202