geotiff.js is a small library to parse TIFF files for visualization or analysis. It is written in pure JavaScript, and is usable in both the browser and node.js applications.
When writing my GeoTIFF to a file with writeArrayBuffer and re-opening with fromFile, I get the following error: Could not get value of geoKey 'GeogSemiMajorAxisGeoKey'.
I've tried adding the GeogSemiMajorAxisGeoKey to the metadata options but I get the following error: unknown type of tag: 2057
How can I get this geokey value to be saved and re-used ? Would be glad to help by submitting a PR !
Many thanks !
Note: After digging a bit in the code, I think there's bug in the geotiffwriter, line 434:
// delete GeoKeys from metadata, because stored in GeoKeyDirectory tag
for (const geoKey in geoKeys) {
if (geoKeys.hasOwnProperty(geoKey)) {
delete metadata[geoKey];
}
}
The first intention was probably the following:
for (const geoKey of geoKeys) {
if (metadata.hasOwnProperty(geoKey)) {
delete metadata[geoKey];
}
}
Hello and thanks for this wonderful lib 🙌
In my GeoTiff, I have the following
geoKeys
:When writing my GeoTIFF to a file with
writeArrayBuffer
and re-opening withfromFile
, I get the following error:Could not get value of geoKey 'GeogSemiMajorAxisGeoKey'
.I've tried adding the
GeogSemiMajorAxisGeoKey
to the metadata options but I get the following error:unknown type of tag: 2057
How can I get this geokey value to be saved and re-used ? Would be glad to help by submitting a PR !
Many thanks !
Note: After digging a bit in the code, I think there's bug in the
geotiffwriter
, line 434:The first intention was probably the following: