[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a

Maximiliano Curia maxy at moszumanska.debian.org
Thu Jul 13 17:39:14 UTC 2017


Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=8239c44

The following commit has been merged in the master branch:
commit 8239c44ee81a0654017aee82f6bad0c88bd91545
Author: Andreas Huggel <ahuggel at gmx.net>
Date:   Thu Jan 31 08:32:52 2008 +0000

    More XMP TagDetails removed, intermediate.
---
 src/properties.cpp         |  51 ++++++---------------------------------------
 src/tags.cpp               |  48 +++++++++++++++++++++++++++++-------------
 src/tags.hpp               |  10 +++++++++
 test/bugfixes-test.sh      |   4 ++++
 test/data/exiv2-bug540.jpg | Bin 0 -> 10011 bytes
 5 files changed, 53 insertions(+), 60 deletions(-)

diff --git a/src/properties.cpp b/src/properties.cpp
index c70f1e0..8c9234b 100644
--- a/src/properties.cpp
+++ b/src/properties.cpp
@@ -446,45 +446,6 @@ namespace Exiv2 {
         { 0, 0, 0, invalidTypeId, xmpInternal, 0 }
     };
 
-    //! exif:SceneCaptureType
-    extern const TagDetails xmpExifSceneCaptureType[] = {
-        { 0, N_("Standard")    },
-        { 1, N_("Landscape")   },
-        { 2, N_("Portrait")    },
-        { 3, N_("Night scene") }
-    };
-
-    //! exif:GainControl
-    extern const TagDetails xmpExifGainControl[] = {
-        { 0, N_("None")           },
-        { 1, N_("Low gain up")    },
-        { 2, N_("High gain up")   },
-        { 3, N_("Low gain down")  },
-        { 4, N_("High gain down") }
-    };
-
-    //! exif:Contrast, exif:Sharpness
-    extern const TagDetails xmpExifNormalSoftHard[] = {
-        { 0, N_("Normal") },
-        { 1, N_("Soft")   },
-        { 2, N_("Hard")   }
-    };
-
-    //! exif:Saturation
-    extern const TagDetails xmpExifSaturation[] = {
-        { 0, N_("Normal")          },
-        { 1, N_("Low saturation")  },
-        { 2, N_("High saturation") }
-    };
-
-    //! exif:SubjectDistanceRange
-    extern const TagDetails xmpExifSubjectDistanceRange[] = {
-        { 0, N_("Unknown")      },
-        { 1, N_("Macro")        },
-        { 2, N_("Close view")   },
-        { 3, N_("Distant view") }
-    };
-
     //! exif:GPSAltitudeRef
     extern const TagDetails xmpExifGPSAltitudeRef[] = {
         { 0, N_("Above sea level") },
@@ -676,7 +637,7 @@ namespace Exiv2 {
         {"Xmp.exif.BrightnessValue",          printFloat                                     },
         {"Xmp.exif.ColorSpace",               print0xa001                                    },
         {"Xmp.exif.ComponentsConfiguration",  print0x9101                                    },
-        {"Xmp.exif.Contrast",                 EXV_PRINT_TAG(xmpExifNormalSoftHard)           },
+        {"Xmp.exif.Contrast",                 printNormalSoftHard                            },
         {"Xmp.exif.CreateDate",               printXmpDate                                   },
         {"Xmp.exif.CustomRendered",           print0xa401                                    },
         {"Xmp.exif.DateTimeOriginal",         printXmpDate                                   },
@@ -691,7 +652,7 @@ namespace Exiv2 {
         {"Xmp.exif.FocalPlaneResolutionUnit", printExifUnit                                  },
         {"Xmp.exif.FocalPlaneXResolution",    printFloat                                     },
         {"Xmp.exif.FocalPlaneYResolution",    printFloat                                     },
-        {"Xmp.exif.GainControl",              EXV_PRINT_TAG(xmpExifGainControl)              },
+        {"Xmp.exif.GainControl",              print0xa407                                    },
         {"Xmp.exif.GPSAltitudeRef",           EXV_PRINT_TAG(xmpExifGPSAltitudeRef)           },
         {"Xmp.exif.GPSDestBearingRef",        EXV_PRINT_TAG(xmpExifGPSDirection)             },
         {"Xmp.exif.GPSDestDistanceRef",       EXV_PRINT_TAG(xmpExifGPSDestDistanceRef)       },
@@ -705,13 +666,13 @@ namespace Exiv2 {
         {"Xmp.exif.LightSource",              print0x9208                                    },
         {"Xmp.exif.MeteringMode",             print0x9207                                    },
         {"Xmp.exif.ModifyDate",               printXmpDate                                   },
-        {"Xmp.exif.Saturation",               EXV_PRINT_TAG(xmpExifSaturation)               },
-        {"Xmp.exif.SceneCaptureType",         EXV_PRINT_TAG(xmpExifSceneCaptureType)         },
+        {"Xmp.exif.Saturation",               print0xa409                                    },
+        {"Xmp.exif.SceneCaptureType",         print0xa406                                    },
         {"Xmp.exif.SceneType",                print0xa301                                    },
         {"Xmp.exif.SensingMethod",            print0xa217                                    },
-        {"Xmp.exif.Sharpness",                EXV_PRINT_TAG(xmpExifNormalSoftHard)           },
+        {"Xmp.exif.Sharpness",                printNormalSoftHard                            },
         {"Xmp.exif.ShutterSpeedValue",        print0x9201                                    },
-        {"Xmp.exif.SubjectDistanceRange",     EXV_PRINT_TAG(xmpExifSubjectDistanceRange)     },
+        {"Xmp.exif.SubjectDistanceRange",     print0xa40c                                    },
         {"Xmp.exif.WhiteBalance",             print0xa403                                    },
         {"Xmp.tiff.Orientation",              print0x0112                                    },
         {"Xmp.tiff.ResolutionUnit",           printExifUnit                                  },
diff --git a/src/tags.cpp b/src/tags.cpp
index b2eee00..e46c71b 100644
--- a/src/tags.cpp
+++ b/src/tags.cpp
@@ -674,8 +674,8 @@ namespace Exiv2 {
         { 4, N_("High gain down") }
     };
 
-    //! Contrast, tag 0xa408
-    extern const TagDetails exifContrast[] = {
+    //! Contrast, tag 0xa408 and Sharpness, tag 0xa40a
+    extern const TagDetails exifNormalSoftHard[] = {
         { 0, N_("Normal") },
         { 1, N_("Soft")   },
         { 2, N_("Hard")   }
@@ -688,13 +688,6 @@ namespace Exiv2 {
         { 2, N_("High")   }
     };
 
-    //! Sharpness, tag 0xa40a
-    extern const TagDetails exifSharpness[] = {
-        { 0, N_("Normal") },
-        { 1, N_("Soft")   },
-        { 2, N_("Hard")   }
-    };
-
     //! SubjectDistanceRange, tag 0xa40c
     extern const TagDetails exifSubjectDistanceRange[] = {
         { 0, N_("Unknown")      },
@@ -934,22 +927,22 @@ namespace Exiv2 {
                 N_("This tag indicates the type of scene that was shot. It can "
                 "also be used to record the mode in which the image was "
                 "shot. Note that this differs from the <SceneType> tag."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifSceneCaptureType)),
+                exifIfdId, captureCond, unsignedShort, print0xa406),
         TagInfo(0xa407, "GainControl", N_("Gain Control"),
                 N_("This tag indicates the degree of overall image gain adjustment."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifGainControl)),
+                exifIfdId, captureCond, unsignedShort, print0xa407),
         TagInfo(0xa408, "Contrast", N_("Contrast"),
                 N_("This tag indicates the direction of contrast processing "
                 "applied by the camera when the image was shot."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifContrast)),
+                exifIfdId, captureCond, unsignedShort, printNormalSoftHard),
         TagInfo(0xa409, "Saturation", N_("Saturation"),
                 N_("This tag indicates the direction of saturation processing "
                 "applied by the camera when the image was shot."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifSaturation)),
+                exifIfdId, captureCond, unsignedShort, print0xa409),
         TagInfo(0xa40a, "Sharpness", N_("Sharpness"),
                 N_("This tag indicates the direction of sharpness processing "
                 "applied by the camera when the image was shot."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifSharpness)),
+                exifIfdId, captureCond, unsignedShort, printNormalSoftHard),
         TagInfo(0xa40b, "DeviceSettingDescription", N_("Device Setting Description"),
                 N_("This tag indicates information on the picture-taking "
                 "conditions of a particular camera model. The tag is used "
@@ -957,7 +950,7 @@ namespace Exiv2 {
                 exifIfdId, captureCond, undefined, printValue),
         TagInfo(0xa40c, "SubjectDistanceRange", N_("Subject Distance Range"),
                 N_("This tag indicates the distance to the subject."),
-                exifIfdId, captureCond, unsignedShort, EXV_PRINT_TAG(exifSubjectDistanceRange)),
+                exifIfdId, captureCond, unsignedShort, print0xa40c),
         TagInfo(0xa420, "ImageUniqueID", N_("Image Unique ID"),
                 N_("This tag indicates an identifier assigned uniquely to "
                 "each image. It is recorded as an ASCII string equivalent "
@@ -2096,6 +2089,31 @@ namespace Exiv2 {
         return os;
     }
 
+    std::ostream& print0xa406(std::ostream& os, const Value& value)
+    {
+        return EXV_PRINT_TAG(exifSceneCaptureType)(os, value);
+    }
+
+    std::ostream& print0xa407(std::ostream& os, const Value& value)
+    {
+        return EXV_PRINT_TAG(exifGainControl)(os, value);
+    }
+
+    std::ostream& print0xa409(std::ostream& os, const Value& value)
+    {
+        return EXV_PRINT_TAG(exifSaturation)(os, value);
+    }
+
+    std::ostream& print0xa40c(std::ostream& os, const Value& value)
+    {
+        return EXV_PRINT_TAG(exifSubjectDistanceRange)(os, value);
+    }
+
+    std::ostream& printNormalSoftHard(std::ostream& os, const Value& value)
+    {
+        return EXV_PRINT_TAG(exifNormalSoftHard)(os, value);
+    }
+
     std::ostream& printExifVersion(std::ostream& os, const Value& value)
     {
         if (value.size() != 4 || value.typeId() != undefined) {
diff --git a/src/tags.hpp b/src/tags.hpp
index 9a7c5da..1ceac90 100644
--- a/src/tags.hpp
+++ b/src/tags.hpp
@@ -502,6 +502,16 @@ namespace Exiv2 {
     std::ostream& print0xa404(std::ostream& os, const Value& value);
     //! Print 35mm equivalent focal length
     std::ostream& print0xa405(std::ostream& os, const Value& value);
+    //! Print scene capture type
+    std::ostream& print0xa406(std::ostream& os, const Value& value);
+    //! Print gain control
+    std::ostream& print0xa407(std::ostream& os, const Value& value);
+    //! Print saturation
+    std::ostream& print0xa409(std::ostream& os, const Value& value);
+    //! Print subject distance range
+    std::ostream& print0xa40c(std::ostream& os, const Value& value);
+    //! Print contrast, sharpness (normal, soft, hard)
+    std::ostream& printNormalSoftHard(std::ostream& os, const Value& value);
     //! Print any version packed in 4 Bytes format : major major minor minor
     std::ostream& printExifVersion(std::ostream& os, const Value& value);
     //! Print any version encoded in the ASCII string majormajorminorminor
diff --git a/test/bugfixes-test.sh b/test/bugfixes-test.sh
index de63a62..2fed3b7 100755
--- a/test/bugfixes-test.sh
+++ b/test/bugfixes-test.sh
@@ -82,6 +82,10 @@ num=501
 filename=`prep_file $num`
 $exiv2 -pi $filename
 
+num=540
+filename=`prep_file $num`
+$exiv2 -px $filename
+
 ) > $results 2>&1
 
 # ----------------------------------------------------------------------
diff --git a/test/data/exiv2-bug540.jpg b/test/data/exiv2-bug540.jpg
new file mode 100644
index 0000000..62c0e56
Binary files /dev/null and b/test/data/exiv2-bug540.jpg differ

-- 
exiv2 packaging



More information about the pkg-kde-commits mailing list