在arx中 如何获得角度值
<P>在arx中 如何直接获得角度值</P><P>(360度格式,非弧度数值)</P>
<P>比如 输入15 ,即角度为15度</P> <P>怎么没人能帮我?</P> <P>ARX有一个全局函数AcUtAngle();</P>
<P>原型及解释如下,在ARX的帮助中有:</P>
<P class=signature>ads_real</P>
<P class=signature>acutAngle(</P>
<P class=signatureIn>const ads_point pt1,</P>
<P class=signatureInEnd>const ads_point pt2);</P>
<P>
<TABLE class=argumentList>
<TBODY>
<TR vAlign=baseline>
<TD class=argumentName>pt1</TD>
<TD class=argumentDescription>Description to come</TD></TR>
<TR vAlign=baseline>
<TD class=argumentName>pt2</TD>
<TD class=argumentDescription>Description to come</TD></TR></TBODY></TABLE></P>
<P>Finds the angle between a line and the current X axis.</P>
<P>Returns the angle of the line defined by pt1 and pt2. The acutAngle() function measures the angle from the X axis of the current User Coordinate System (UCS), with the angle increasing in the counterclockwise direction. It returns the value in radians. This function treats pt1 and pt2 as two-dimensional points; it ignores their Z coordinates, in effect projecting the line onto the current construction plane.</P>
<P>不过返回的是弧度值,需要转换为角度值。</P> 不好意思,函数名写错了,是acutAngle,不是AcUtAngle <P>您好像没看懂我的意思</P>
<P>应该是这样</P>
<P>从键盘输入 15 给参数 angle</P>
<P>则angle=15度,</P>
<P>就像输入ads_real 一样的</P>
<P> </P>
<P> </P> <P>好象不能直接做,但是你可以从程序里,将弧度值修改为角度值,然后赋 给一个变量,很简单的</P>
页:
[1]