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

Maximiliano Curia maxy at moszumanska.debian.org
Thu Jul 13 17:36:15 UTC 2017


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

The following commit has been merged in the master branch:
commit cd6ca2a94c510e6cc014649cfd3af037a18be53b
Author: Andreas Huggel <ahuggel at gmx.net>
Date:   Sat Apr 3 03:48:38 2004 +0000

    Implemented print functions for flash details and AF point(s) used
---
 src/canonmn.cpp | 67 +++++++++++++++++++++++++++++++++++++++++++++++++--------
 1 file changed, 58 insertions(+), 9 deletions(-)

diff --git a/src/canonmn.cpp b/src/canonmn.cpp
index f6f2a22..e6e2502 100644
--- a/src/canonmn.cpp
+++ b/src/canonmn.cpp
@@ -20,7 +20,7 @@
  */
 /*
   File:      canonmn.cpp
-  Version:   $Name:  $ $Revision: 1.5 $
+  Version:   $Name:  $ $Revision: 1.6 $
   Author(s): Andreas Huggel (ahu) <ahuggel at gmx.net>
   History:   18-Feb-04, ahu: created
              07-Mar-04, ahu: isolated as a separate component
@@ -30,7 +30,7 @@
  */
 // *****************************************************************************
 #include "rcsid.hpp"
-EXIV2_RCSID("@(#) $Name:  $ $Revision: 1.5 $ $RCSfile: canonmn.cpp,v $")
+EXIV2_RCSID("@(#) $Name:  $ $Revision: 1.6 $ $RCSfile: canonmn.cpp,v $")
 
 // *****************************************************************************
 // included header files
@@ -213,9 +213,11 @@ namespace Exif {
 
         if (count < 30) return os;
         s = val.value_[29];
-        os << std::setw(30) << "
   Flash details ";
-        print0x0001_29(os, s);
- 
+        if (s > 0) {
+            os << std::setw(30) << "
   Flash details ";
+            print0x0001_29(os, s);
+        }
+
         // Meaning of the 30th ushort is unknown - ignore it
         // Meaning of the 31st ushort is unknown - ignore it
 
@@ -506,8 +508,32 @@ namespace Exif {
 
     std::ostream& CanonMakerNote::print0x0001_29(std::ostream& os, uint16 s)
     {
-        // Todo: decode bitmask
-        os << std::dec << s << " (Todo: decode bitmask)";
+        bool coma = false;
+        if (s & 0x4000) {
+            if (coma) os << ", ";
+            os << "External TTL";
+            coma = true;
+        }
+        if (s & 0x2000) {
+            if (coma) os << ", ";
+            os << "Internal flash";
+            coma = true;
+        }
+        if (s & 0x0800) {
+            if (coma) os << ", ";
+            os << "FP sync used";
+            coma = true;
+        }
+        if (s & 0x0080) {
+            if (coma) os << ", ";
+            os << "Rear curtain sync used";
+            coma = true;
+        }
+        if (s & 0x0010) {
+            if (coma) os << ", ";
+            os << "FP sync enabled";
+            coma = true;
+        }
         return os;
     }
 
@@ -565,8 +591,31 @@ namespace Exif {
 
     std::ostream& CanonMakerNote::print0x0004_14(std::ostream& os, uint16 s)
     {
-        // Todo: decode bitmask
-        os << s << " (Todo: decode bitmask)";
+        uint16 num = (s & 0xf000) >> 12;
+        os << num << " focus points; ";
+        uint16 used = s & 0x0fff;
+        if (used == 0) {
+            os << "none";
+        }
+        else {
+            bool coma = false;
+            if (s & 0x0004) {
+                if (coma) os << ", ";
+                os << "left";
+                coma = true;
+            }
+            if (s & 0x0002) {
+                if (coma) os << ", ";
+                os << "center";
+                coma = true;
+            }
+            if (s & 0x0001) {
+                if (coma) os << ", ";
+                os << "right";
+                coma = true;
+            }
+        }
+        os << " used";
         return os;
     }
 

-- 
exiv2 packaging



More information about the pkg-kde-commits mailing list