[gdal-dev] Standardization of Bounding Box structure

Ari Jolma ari.jolma at gmail.com
Fri Nov 24 01:06:03 PST 2017


Roberto Ribeiro kirjoitti 23.11.2017 klo 20:43:
> In OGR, the GetGeometry() method from the Geometry class returns a 
> bounding box in the (xmin, xmax, ymin, ymax) structure. However, the 
> SetSpatialFilterRect() method from the Layer class expects a bounding 
> box in the (xmin, ymin, xmax, ymax) structure. This is a problem that 
> can be worked around, but it does generate confusion. Any reason why 
> this couldn't be standardized?

There are also for example in gdal_translate also "xoff yoff xsize 
ysize", i.e., (xmin, ymin, xmax-xmin, ymax-ymin) and "ulx uly lrx lry", 
i.e., (xmin, ymax, xmax, ymin).

I guess the main reason is that changing the interface is a major 
change. So, perhaps this could be put on the list of things to consider 
changing in GDAL 3.0.

Ari

>
> Also, on a similar note, having SetSpatialFilterRect expect an array 
> of coordinates, instead of coordinates as individual arguements, seems 
> more logical to me, as it's how every other GIS package returns 
> bounding box info afaik, including OGR's GetGeometry.
>
>
> _______________________________________________
> gdal-dev mailing list
> gdal-dev at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/gdal-dev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20171124/7d8ff9a7/attachment.html>


More information about the gdal-dev mailing list