[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:55 UTC 2017
Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/exiv2.git;a=commitdiff;h=7bd8740
The following commit has been merged in the master branch:
commit 7bd874049efc1b60e68b5a6b88f919a5f04d9499
Author: Robin Mills <robin at clanmills.com>
Date: Wed Sep 14 20:25:21 2016 +0000
#1074 Work in progress. -eC -pC -eC- work for JPG/PNG/TIFF/WEBP. pngimage::doWriteMetadata() does not update iCCP chunk.
---
src/actions.cpp | 19 ++++++++++++-------
src/pngchunk.cpp | 19 +++++++++++++++++--
src/pngchunk_int.hpp | 11 +++++++++++
src/pngimage.cpp | 53 +++++++++++++++++++++++++++++++++++++++++++---------
src/tiffimage.cpp | 2 +-
5 files changed, 85 insertions(+), 19 deletions(-)
diff --git a/src/actions.cpp b/src/actions.cpp
index ee51dd3..0958b1a 100644
--- a/src/actions.cpp
+++ b/src/actions.cpp
@@ -1187,14 +1187,19 @@ namespace Action {
std::cerr << _("No embedded iccProfile: ") << path_ << std::endl;
rc = -2;
} else {
- std::string iccPath = newFilePath(path_,".icc");
- if (Params::instance().verbose_) {
- std::cout << _("Writing iccProfile: ") << iccPath << std::endl;
+
+ if ( Params::instance().target_ & Params::ctStdInOut ) { // -eC-
+ std::cout.write((const char*)image->iccProfile()->pData_,image->iccProfile()->size_);
+ } else {
+ std::string iccPath = newFilePath(path_,".icc");
+ if (Params::instance().verbose_) {
+ std::cout << _("Writing iccProfile: ") << iccPath << std::endl;
+ }
+ Exiv2::FileIo iccFile(iccPath);
+ iccFile.open("wb") ;
+ iccFile.write(image->iccProfile()->pData_,image->iccProfile()->size_);
+ iccFile.close();
}
- Exiv2::FileIo iccFile(iccPath);
- iccFile.open("wb") ;
- iccFile.write(image->iccProfile()->pData_,image->iccProfile()->size_);
- iccFile.close();
}
}
return rc;
diff --git a/src/pngchunk.cpp b/src/pngchunk.cpp
index ce5a75b..14638fd 100644
--- a/src/pngchunk.cpp
+++ b/src/pngchunk.cpp
@@ -225,7 +225,7 @@ namespace Exiv2 {
{
// We look if an ImageMagick EXIF raw profile exist.
- if ( keySize >= 21
+ if ( keySize >= 21
&& ( memcmp("Raw profile type exif", key, 21) == 0
|| memcmp("Raw profile type APP1", key, 21) == 0)
&& pImage->exifData().empty())
@@ -329,7 +329,7 @@ namespace Exiv2 {
if ( keySize >= 20
&& memcmp("Raw profile type xmp", key, 20) == 0
- && pImage->xmpData().empty())
+ && pImage->xmpData().empty())
{
DataBuf xmpBuf = readRawProfile(arr);
long length = xmpBuf.size_;
@@ -541,6 +541,21 @@ namespace Exiv2 {
} // PngChunk::makeAsciiTxtChunk
+ std::string PngChunk::makeICCPChunkHeader(const std::string& keyword,long compressedLength)
+ {
+ // Chunk structure: length (4 bytes) + chunk type
+ std::string chunkData = keyword + '
--
exiv2 packaging
More information about the pkg-kde-commits
mailing list