Merge branch 'dev' into nr-gain

This commit is contained in:
Lawrence37
2023-10-10 21:03:03 -07:00
committed by GitHub
201 changed files with 19647 additions and 25087 deletions

View File

@@ -643,15 +643,11 @@ struct WBParams {
double equal;
double tempBias;
StandardObserver observer;
int itcwb_thres;
int itcwb_precis;
int itcwb_size;
int itcwb_delta;
int itcwb_fgreen;
double itcwb_green;
int itcwb_rgreen;
bool itcwb_nopurple;
bool itcwb_sorted;
bool itcwb_forceextra;
bool itcwb_alg;
Glib::ustring itcwb_prim;
bool itcwb_sampling;
WBParams();
@@ -1941,6 +1937,7 @@ struct ColorManagementParams {
ACES_P1,
WIDE_GAMUT,
ACES_P0,
JDC_MAX,
BRUCE_RGB,
BETA_RGB,
BEST_RGB,
@@ -1993,31 +1990,22 @@ struct ColorManagementParams {
bool operator !=(const ColorManagementParams& other) const;
};
/**
* Parameters for metadata handling
*/
struct MetaDataParams {
enum Mode {
TUNNEL,
EDIT,
STRIP
};
Mode mode;
MetaDataParams();
bool operator ==(const MetaDataParams &other) const;
bool operator !=(const MetaDataParams &other) const;
};
/**
* Minimal wrapper allowing forward declaration for representing a key/value for the exif metadata information
*/
class ExifPairs final
{
private:
using Pairs = std::map<Glib::ustring, Glib::ustring>;
public:
using const_iterator = std::map<Glib::ustring, Glib::ustring>::const_iterator;
using const_iterator = Pairs::const_iterator;
using size_type = Pairs::size_type;
const_iterator find(const Glib::ustring& key) const
{
return pairs.find(key);
}
const_iterator begin() const
{
@@ -2034,6 +2022,16 @@ public:
pairs.clear();
}
size_type erase(const Glib::ustring& key)
{
return pairs.erase(key);
}
bool empty() const
{
return pairs.empty();
}
Glib::ustring& operator[](const Glib::ustring& key)
{
return pairs[key];
@@ -2045,7 +2043,7 @@ public:
}
private:
std::map<Glib::ustring, Glib::ustring> pairs;
Pairs pairs;
};
/**
@@ -2077,6 +2075,11 @@ public:
return pairs.empty();
}
iterator erase(const const_iterator& key)
{
return pairs.erase(key);
}
void clear()
{
pairs.clear();
@@ -2096,6 +2099,29 @@ private:
std::map<Glib::ustring, std::vector<Glib::ustring>> pairs;
};
/**
* Parameters for metadata handling
*/
struct MetaDataParams {
enum Mode {
TUNNEL,
EDIT,
STRIP
};
Mode mode;
std::vector<std::string> exifKeys;
ExifPairs exif;
IPTCPairs iptc;
MetaDataParams();
bool operator ==(const MetaDataParams &other) const;
bool operator !=(const MetaDataParams &other) const;
static std::vector<std::string> basicExifKeys;
};
struct WaveletParams {
std::vector<double> ccwcurve;
std::vector<double> wavdenoise;
@@ -2614,8 +2640,8 @@ public:
int ppVersion; ///< Version of the PP file from which the parameters have been read
MetaDataParams metadata; ///< Metadata parameters
ExifPairs exif; ///< List of modifications appplied on the exif tags of the input image
IPTCPairs iptc; ///< The IPTC tags and values to be saved to the output image
// ExifPairs exif; ///< List of modifications appplied on the exif tags of the input image
// IPTCPairs iptc; ///< The IPTC tags and values to be saved to the output image
/**
* The constructor only sets the hand-wired defaults.