多段线求交点问题
虽说有IntersectWith方法求交点,可是如果object,IntersectObject<b>是同一图元时</b>例如<b>LWPOLYLINE</b> 那么RetVal 中的交点为什么是它的<b>节点</b>
那么应该怎么正确的求出真正的交点呢?
谢谢大家!
附注 IntersectWith 方法
RetVal = object.IntersectWith(IntersectObject, ExtendOption)
Object All Drawing Objects (Except Pviewport and PolygonMesh)<BR>The object or objects this method applies to.<BR>IntersectObject Object, input-only; <BR>The object can be one of All Drawing Objects.
<BR>ExtendOption AcExtendOption enum; input-only<BR>This option specifies if one or the other, both, or none of the entities are to be extended in order to attempt an intersection.
acExtendNone Does not extend either object.<BR>acExtendThisEntity Extends the base object.<BR>acExtendOtherEntity Extends the object passed as an argument.
acExtendBoth Extends both objects.
RetVal Variant (array of doubles)<BR>The array of points where one object intersects another object in the drawing. <b>同一图元求交点干什么?</b> 当然有必要啊,例如<b>LWPOLYLINE图元</b>
在绘制等高线时会出现回线,自交叉等问题
影响了图的美观.但是在绘图时又不能轻易停下来修改
怎么办,我只是想用IntersectWith得到它的交点,而不想编历每个节点.
行么? <p>这个问题,多年等待中!</p><p>坛主们给个解吧!</p> <p>参考,先把多段线依据节分解成n条,各条线用IntersectWith是否相交得出交点</p>
页:
[1]