rafaqz / Extents.jl

A shared Extent object for Julia spatial data, with DE-9IM spatial predicates
MIT License
4 stars 3 forks source link

Intersect for Extent #11

Closed felixcremer closed 1 year ago

felixcremer commented 1 year ago

I am wondering, whether it would make sense to overload the intersect function for Extent types. I have two rasters that have slightly different Extents and I would like to quickly find the area of intersection for plotting purposes.

I would expect that an intersect function would operate on the interval intersection of both dimensions after checking, that the dimension names are the same.

rafaqz commented 1 year ago

Extents.intersection should be what you want

felixcremer commented 1 year ago

Yes, thanks, that is exactly what I want. Sorry for the noise.