android: jpeg: exif: change GPS method encoding from ASCII to NoEncoding

According to the EXIF specification, the GPS method should be UNDEFINED,
and the first 8 bytes will designate the type. However, CTS expects the
first 8 bytes to be part of the data. Remove the 8-byte encoding
designator by changing the encoding to NoEncoding to appease CTS.

This is part of the fix that allows the following CTS test to pass:
- android.hardware.cts.CameraTest#testJpegExif

Signed-off-by: Paul Elder <paul.elder@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo@jmondi.org>
This commit is contained in:
Paul Elder
2021-03-08 19:01:22 +09:00
parent a3c9718cfc
commit d3cf0fed3e
+1 -1
View File
@@ -405,7 +405,7 @@ void Exif::setGPSLocation(const double *coords)
void Exif::setGPSMethod(const std::string &method)
{
setString(EXIF_IFD_GPS, static_cast<ExifTag>(EXIF_TAG_GPS_PROCESSING_METHOD),
EXIF_FORMAT_UNDEFINED, method, Unicode);
EXIF_FORMAT_UNDEFINED, method, NoEncoding);
}
void Exif::setOrientation(int orientation)