AddEllipse的椭圆长轴长度的理解.
<p>此帖的目的是,在addellipse中,如何理解不好椭圆长轴长度,画的椭圆会转个角度.</p><p>Sub Example_AddEllipse()<br/> ' 该示例在模型空间中创建椭圆。<br/> <br/> Dim ellObj As AcadEllipse<br/> Dim majAxis(0 To 2) As Double<br/> Dim center(0 To 2) As Double<br/> Dim radRatio As Double<br/> <br/> ' 在模型空间中创建椭圆<br/> center(0) = 25#: center(1) = 25#: center(2) = 0#<br/> majAxis(0) = 400: majAxis(1) = 0#: majAxis(2) = 0#<br/> radRatio = 0.5<br/> Set ellObj = ThisDrawing.ModelSpace.AddEllipse(center, majAxis, radRatio)<br/> ZoomAll<br/> <br/>End Sub<br/></p><p> 注意事项:如果要绿线与红线平行,majAxis(1) = 0#: 必须设置为0,否则椭圆会转为一个角度.</p><p>说明,红线为-500,0到500,0的直线</p><p>在AddEllipse的帮助文件中对MajorAxis描述是</p><p class="element-desc">Variant[变体] (双精度); 仅用于输入<br/>定义椭圆长轴长度的正值。 注意理解为椭圆长轴长度</p><p> </p>
页:
[1]