UltraHDR: update Version handling.

Version is now a string as spec'd, and identifier is added to Primary
image XMP to indicate presence of a gain map.

Bug: 278784125
Test: tests pass
Change-Id: Ia76879ca3d187edb78927ad5bab79fc8eef07da8
(cherry picked from commit 4ac2a268cbd211389d7f1d27853b8eeb6f956b72)
diff --git a/libs/ultrahdr/jpegr.cpp b/libs/ultrahdr/jpegr.cpp
index 5f55d1b..0f7aa27 100644
--- a/libs/ultrahdr/jpegr.cpp
+++ b/libs/ultrahdr/jpegr.cpp
@@ -61,7 +61,7 @@
   }
 
 // The current JPEGR version that we encode to
-static const uint32_t kJpegrVersion = 1;
+static const char* const kJpegrVersion = "1.0";
 
 // Map is quarter res / sixteenth size
 static const size_t kMapDimensionScaleFactor = 4;
@@ -943,7 +943,7 @@
                                  + xmp_secondary_length
                                  + compressed_gain_map->length;
   // primary image
-  const string xmp_primary = generateXmpForPrimaryImage(secondary_image_size);
+  const string xmp_primary = generateXmpForPrimaryImage(secondary_image_size, *metadata);
   // same as primary
   const int xmp_primary_length = 2 + nameSpaceLength + xmp_primary.size();