I have 2 layers. A lines layer and a points layer.
For any given line, how can I find the points that intersect the envelope of the line, but not the line itself, or more specifically, not the to point or from point of the line.
I can obviously find all the points that intersect the line’s envelope, and then do 1 by 1 tests on the found points to see if they intersect the to or from points of the line, but I was hoping there is an easier, faster way to do something of this nature.
Edit:
An envelope or extent of a geometry is the smallest rectangle (polygon with 4 points) in which the geometry (polygon, polyline, line, etc.) will fit.
The below diagram illustrates the envelope for a polygon, but a polyline will work similarly.
Envelope http://www.freeimagehosting.net/uploads/cf344d3fe2.jpg
To find all points in the points layer that do not intersect an endpoint of a line in the lines layer, I would do this:
Dictionary<string,IPoint>of points in the points layer.Dictionary<string,IPoint>of endpoints in the lines layer.The string key is based on a concatenation of X, comma, and Y.