4

So how do I do that? ArcMap's Select By Location selects also all features that touch, but I only need the ones that actually intersect the area.

I currently use esriSpatialRelEnum.esriSpatialRelIntersects and there doesn't seem to be an option for what I need. esriSpatialRelOverlaps isn't an option because it doesn't cover the case when the geometries are excatly the same size and over each other. esriSpatialRelCrosses also doesn't work because it doesn't support Area/Area intersection.

So is this possible at all?

5

You should use esriSpatialRelEnum.esriSpatialRelRelation instead and set the SpatialRelDescription property to pSFilter.SpatialRelDescription = "T***F****". This will only return the features that have the interiors intersecting.

1

This probably should be a comment, instead of an answer, but I can't include images in comments.

The help page for Using Select by Location says:

A target feature will be selected if the intersection of its geometry with the source feature is nonempty, but the intersection of their interiors is empty. This is the definition of the Clementini touch operator, so if the target feature touches (as defined by Clementini) the source feature, it is selected.

But the image on the right (incorrectly?) shows that a polygon with an intersecting interior is selected - the middle yellow polygon is outlined with cyan, when it shouldn't be.

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.