I am using piexifjs
to manipulate exif data of jpg images. everything works fine. but when I try to modify the gps longitude and latitudes, I am having some issues.
as on https://www.exiv2.org/tags.html, it states the datatype for gps coordinates it a Rational
and I am having trouble getting how it works.
gps[piexif.GPSIFD.GPSLatitude] = 23.234;
gps[piexif.GPSIFD.GPSLatitudeRef] = "S";
OR
gps[piexif.GPSIFD.GPSLatitude] = [23,23,23];
gps[piexif.GPSIFD.GPSLatitudeRef] = "S";
I can add all the others like Author
, XPTitle
... and yet it It doesn't work at all for gps coordinates.