[SCM] exiv2 packaging branch, master, updated. debian/0.25-3.1-3734-gdcbc29a
Maximiliano Curia
maxy at moszumanska.debian.org
Thu Jul 13 17:46:27 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=664af57
The following commit has been merged in the master branch:
commit 664af57e10a020bfa875be448da3882dec4203a7
Author: Robin Mills <robin at clanmills.com>
Date: Fri Apr 29 19:20:30 2016 +0000
#1034 Added samples/toexv This is a first step to write exif metadata to memory to send to a web service.
---
Makefile | 3 ++-
config/Makefile.in | 3 ++-
include/exiv2/image.hpp | 7 ++++++-
include/exiv2/types.hpp | 2 +-
samples/Makefile | 5 +++--
src/image.cpp | 5 +++++
6 files changed, 19 insertions(+), 6 deletions(-)
diff --git a/Makefile b/Makefile
index 0e1d2ba..8642dee 100644
--- a/Makefile
+++ b/Makefile
@@ -101,7 +101,8 @@ bugtest bugstest testbugs bugfixes:
addmoddel exifcomment exifvalue httptest iptctest mmap-test stringto-test \
exifdata iotest key-test path-test taglist write2-test write-test \
convert-test exifdata-test exiv2json iptceasy largeiptc-test prevtest tiff-test \
-easyaccess-test geotag iptcprint metacopy werror-test xmpparser-test xmpsample xmpparse :
+easyaccess-test geotag iptcprint metacopy toexv werror-test \
+xmpparser-test xmpsample xmpparse :
cd samples && $(MAKE) $(MAKECMDGOALS)
MAJOR=$(shell grep "define.*EXIV2_.*_VERSION .*\d*" src/version.hpp | grep MAJOR | sed -e 's/EXIV2//g' | tr -dC [:digit:])
diff --git a/config/Makefile.in b/config/Makefile.in
index 38c0754..dfa1f31 100644
--- a/config/Makefile.in
+++ b/config/Makefile.in
@@ -101,7 +101,8 @@ bugtest bugstest testbugs bugfixes:
addmoddel exifcomment exifvalue httptest iptctest mmap-test stringto-test \
exifdata iotest key-test path-test taglist write2-test write-test \
convert-test exifdata-test exiv2json iptceasy largeiptc-test prevtest tiff-test \
-easyaccess-test geotag iptcprint metacopy werror-test xmpparser-test xmpsample xmpparse :
+easyaccess-test geotag iptcprint metacopy toexv werror-test \
+xmpparser-test xmpsample xmpparse :
cd samples && $(MAKE) $(MAKECMDGOALS)
MAJOR=$(shell grep "define.*EXIV2_.*_VERSION .*\d*" src/version.hpp | grep MAJOR | sed -e 's/EXIV2//g' | tr -dC [:digit:])
diff --git a/include/exiv2/image.hpp b/include/exiv2/image.hpp
index 3ed9932..495ab5c 100644
--- a/include/exiv2/image.hpp
+++ b/include/exiv2/image.hpp
@@ -235,10 +235,15 @@ namespace Exiv2 {
*/
virtual void setIccProfile(DataBuf& iccProfile);
/*!
- @brief Erase iccProfile. the profile isnot not removed from
+ @brief Erase iccProfile. the profile is not removed from
the actual image until the writeMetadata() method is called.
*/
virtual void clearIccProfile();
+
+ /*!
+ @brief return iccProfile
+ */
+ virtual DataBuf* iccProfile() { return &iccProfile_; }
/*!
@brief Copy all existing metadata from source Image. The data is
copied into internal buffers and is not written to the image
diff --git a/include/exiv2/types.hpp b/include/exiv2/types.hpp
index 00c225b..c22b71c 100644
--- a/include/exiv2/types.hpp
+++ b/include/exiv2/types.hpp
@@ -112,7 +112,7 @@ namespace Exiv2 {
enum WriteMethod { wmIntrusive, wmNonIntrusive };
//! An identifier for each type of metadata
- enum MetadataId { mdNone=0, mdExif=1, mdIptc=2, mdComment=4, mdXmp=8 };
+ enum MetadataId { mdNone=0, mdExif=1, mdIptc=2, mdComment=4, mdXmp=8, mdIccProfile=16 };
//! An identifier for each mode of metadata support
enum AccessMode { amNone=0, amRead=1, amWrite=2, amReadWrite=3 };
diff --git a/samples/Makefile b/samples/Makefile
index c3ca651..805b95e 100644
--- a/samples/Makefile
+++ b/samples/Makefile
@@ -87,7 +87,8 @@ BINSRC = addmoddel.cpp \
OTHERSRC = exiv2json.cpp \
geotag.cpp \
metacopy.cpp \
- path-test.cpp
+ path-test.cpp \
+ toexv.cpp
# ******************************************************************************
# Initialisations
@@ -167,7 +168,7 @@ geotag: %: %.cpp
$(LIBTOOL) --mode=link $(LINK.cc) -lexpat $@.o -o ../bin/$@
# link applications which require utils.cpp support
-metacopy path-test: %: %.cpp ../src/utils.o
+metacopy path-test toexv: %: %.cpp ../src/utils.o
$(COMPILE.cc) -I../src -I../include -I../include/exiv2 -o $@.o $<
@$(MAKEDEPEND)
@$(POSTDEPEND)
diff --git a/src/image.cpp b/src/image.cpp
index eceaf74..7f04871 100644
--- a/src/image.cpp
+++ b/src/image.cpp
@@ -212,6 +212,9 @@ namespace Exiv2 {
if (checkMode(mdIptc) & amWrite) {
setIptcData(image.iptcData());
}
+ if (checkMode(mdIccProfile) & amWrite && iccProfile()) {
+ setIccProfile(*iccProfile());
+ }
if (checkMode(mdXmp) & amWrite) {
setXmpPacket(image.xmpPacket());
setXmpData(image.xmpData());
@@ -391,6 +394,8 @@ namespace Exiv2 {
case mdComment:
am = r->commentSupport_;
break;
+ case mdIccProfile: break;
+
// no default: let the compiler complain
}
return am;
--
exiv2 packaging
More information about the pkg-kde-commits
mailing list