Skip to content

Commit

Permalink
v0.3.3 add byline iptc reading
Browse files Browse the repository at this point in the history
  • Loading branch information
Systerr committed Jun 1, 2017
1 parent 0f12779 commit 68f902c
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@
using namespace boost::program_options;
using namespace std;

#define ARION_VERSION "0.3.2"
#define ARION_VERSION "0.3.3"

//------------------------------------------------------------------------------
//------------------------------------------------------------------------------
Expand Down
7 changes: 6 additions & 1 deletion src/models/read_meta.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ void Read_meta::readIptc()
const string iptcCountryNameKey = "Iptc.Application2.CountryName";
const string iptcCountryCodeKey = "Iptc.Application2.CountryCode";
const string iptcSubjectKey = "Iptc.Application2.Subject";
const string iptcBylineKey = "Iptc.Application2.Byline";

const Exiv2::IptcData &iptcData = *mpIptcData;

Expand All @@ -180,7 +181,8 @@ void Read_meta::readIptc()
readIptcStringByKey(md, iptcCountryNameKey, &mCountryName);
readIptcStringByKey(md, iptcCountryCodeKey, &mCountryCode);
readIptcStringByKey(md, iptcSubjectKey, &mSubject);

readIptcStringByKey(md, iptcBylineKey, &mByline);

if (md->key() == iptcKeywordsKey)
{
string keyword = md->toString();
Expand Down Expand Up @@ -255,6 +257,9 @@ void Read_meta::serialize(rapidjson::Writer<rapidjson::StringBuffer>& writer) co
writer.String("copyright");
writer.String(mCopyright);

writer.String("byline");
writer.String(mByline);

writer.String("city");
writer.String(mCity);

Expand Down
1 change: 1 addition & 0 deletions src/models/read_meta.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ class Read_meta : public Operation
bool mPropertyReleased;
std::string mInstructions;
std::string mSubject;
std::string mByline;

// Location
std::string mCity;
Expand Down

0 comments on commit 68f902c

Please sign in to comment.