API Reference > OdDb Classes > OdDbRegion Class > OdDbRegion Methods > subIntersectWith Method > OdDbRegion::subIntersectWith Method (OdDbEntity*, OdDb::Intersect, OdGePoint3dArray&, OdGsMarker, OdGsMarker)
OdDbRegion::subIntersectWith Method (OdDbEntity*, OdDb::Intersect, OdGePoint3dArray&, OdGsMarker, OdGsMarker)
Syntax
C++
virtual OdResult subIntersectWith(const OdDbEntity* pEnt, OdDb::Intersect intType, OdGePoint3dArray& points, OdGsMarker thisGsMarker = 0, OdGsMarker otherGsMarker = 0) const;
Parameters 
Description 
const OdDbEntity* pEnt 
[in] Pointer to the entity which must be intersected with the region.  
OdDb::Intersect intType 
[in] Intersection type.  
OdGePoint3dArray& points 
[out] Reference to the array of the appended points of intersection (point coordinates are represented in WCS).  
OdGsMarker thisGsMarker = 0 
[in] GS marker of the subentity of the region involved in the intersection operation.  
OdGsMarker otherGsMarker = 0 
[in] GS marker of the subentity of the entity represented by pEnt that is involved in the intersection operation.
 

Returns eOk if successful or an appropriate error code in other case.

Finds the intersections of the specified entity with all the edges of the region's bounding box. 

 

The intType parameter determines the extension of the region and the specified entity while calculating intersections:

  • OdDb::kOnBothOperands - do not extend the region or the entity represented with pEnt bounding box edges.

In this case the method calculates only where the bounding box lines actually intersect with the specified entity.

  • OdDb::kExtendThis - extend the region's bounding box edges (if necessary) when calculating intersections without extending the specified entity.
  • OdDb::kExtendArg - extend the specified entity (if necessary) when calculating intersections without extending the region's bounding box edges.
  • OdDb::kExtendBoth - extend both the region's bounding box and the specified entity (if necessary) when calculating intersections.

 

Any found intersection points are appended to the points array. All points are represented in WCS coordinates. 

The thisGsMarker and otherGsMarker parameters provide information for searching intersections between specified subentities. The default value for these parameters is zero. 

This method is implemented only for Spatial modeler and returns eNotImplementedYet status for other modelers.

Copyright © 2002–2020. Open Design Alliance. All rights reserved.