Hello, Using conda installed GDAL 3.2.1
I think I've stumbled on a bug with the BAG driver. It seems as though when you use Create() to make a BAG, it writes the dimensionSize xml attribute in the wrong order. It sets the column dimension size to the row dimensionSize xml attribute, and row to column. I found this on examining the xml manually, see blob below. <gmd:axisDimensionProperties> <gmd:MD_Dimension> <gmd:dimensionName> <gmd:MD_DimensionNameTypeCode codeList=" http://www.isotc211.org/2005/resources/Codelist/gmxCodelists.xml#MD_DimensionNameTypeCode" codeListValue="row">row</gmd:MD_DimensionNameTypeCode> </gmd:dimensionName> * <gmd:dimensionSize> <gco:Integer>546</gco:Integer> </gmd:dimensionSize>* <gmd:resolution> <gco:Measure uom="m">2.0</gco:Measure> </gmd:resolution> </gmd:MD_Dimension> </gmd:axisDimensionProperties> This bug does not affect viewing the BAG in QGIS, as it seems like QGIS just computes the size using the actual array. I found that GDAL created BAGs would not load in Caris, a software for viewing bathymetric data. I believe that is because Caris is using the dimensionSize xml instead of calculating size from the data. If I swap row/col dimensionSize, the BAG then works in Caris. Seems like a relatively simple fix (assuming I am right about this), please let me know if I need to submit it somewhere else. Thanks, Eric -- Eric Younkin Physical Scientist NOAA OCS, Hydrographic Systems and Technology Branch 1315 East-West Highway N/CS11, Room 6604 Silver Spring, MD 20910 Office: 240-847-8208 Cell: 828-331-8197
_______________________________________________ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev