Intersection-Deal With linear Entity

Intersection-Deal With linear Entity

Anonymous
Not applicable
672 Views
2 Replies
Message 1 of 3

Intersection-Deal With linear Entity

Anonymous
Not applicable

Hello,

There is a question about Intersection between linear Entities(In the following pictures),how can I get the correct Intersected Point?Any solutions?

0 Likes
673 Views
2 Replies
Replies (2)
Message 2 of 3

Alfred.NESWADBA
Consultant
Consultant

Hi,

 

within the function AcDbEntity::intersectWith you do have the parameter for extending elements. So you can compare each element to each other, extending the entities set to on and you just have to collect the intersection points.

 

From the help:

The intType is used to determine how to deal with extending the two entities in order to calculate intersections. The possible AcDb::Intersect values are: 

AcDb::kOnBothOperands Do not extend either entity. This results in only calculating intersections where the two entitys' geometry actually intersect

AcDb::kExtendThis Extend this entity (if necessary) when calculating intersections, but do not extend the pEnt entity.

AcDb::kExtendArg Extend the pEnt entity (if necessary) when calculating intersections, but do not extend this entity.

AcDb::kExtendBoth Extend both the pEnt entity and this entity (if necessary) when calculating intersections 

 

I hope that answers your questions, if not, please be more specific of what your question is, where you do have a problem in your codeing.

 

HTH, - alfred -

------------------------------------------------------------------------------------
Alfred NESWADBA
ISH-Solutions GmbH / Ingenieur Studio HOLLAUS
www.ish-solutions.at ... blog.ish-solutions.at ... LinkedIn ... CDay 2026
------------------------------------------------------------------------------------

(not an Autodesk consultant)
0 Likes
Message 3 of 3

michael_robertson
Collaborator
Collaborator

You should also be aware the some of the intersection methods return incorrect results when "large" coordinates are used. We've run into this problem quite a few times since we work in state-plane coordinates doing road work. ADN said it is a known problem when coordinates are "large" (although there is no set definition of what "large" is).

 

What we have to do in code to get these methods to work is transform copies of the object we are interested in so that they are near the origin, run the intersection method, then transform the result back to the original objects.

Mike Robertson
FL. Dept. of Transportation
CADD Applications Developer
0 Likes