Merge pull request #6227 from Beep6581/spot-removal-tool

Spot removal tool
This commit is contained in:
Lawrence37
2021-05-16 12:44:45 -07:00
committed by GitHub
60 changed files with 2652 additions and 163 deletions

View File

@@ -27,6 +27,7 @@
#include <glibmm/ustring.h>
#include <lcms2.h>
#include "coord.h"
#include "noncopyable.h"
struct ParamsEdited;
@@ -1697,6 +1698,41 @@ struct ResizeParams {
bool operator !=(const ResizeParams& other) const;
};
/**
* Parameters entry
*/
struct SpotEntry {
Coord sourcePos;
Coord targetPos;
int radius;
float feather;
float opacity;
SpotEntry();
float getFeatherRadius() const;
bool operator ==(const SpotEntry& other) const;
bool operator !=(const SpotEntry& other) const;
};
/**
* Parameters of the dust removal tool
*/
struct SpotParams {
bool enabled;
std::vector<SpotEntry> entries;
// the following constant can be used for experimentation before the final merge
static const short minRadius;
static const short maxRadius;
SpotParams();
bool operator ==(const SpotParams& other) const;
bool operator !=(const SpotParams& other) const;
};
/**
* Parameters of the color spaces used during the processing
*/
@@ -2386,6 +2422,7 @@ public:
ChannelMixerParams chmixer; ///< Channel mixer parameters
BlackWhiteParams blackwhite; ///< Black& White parameters
ResizeParams resize; ///< Resize parameters
SpotParams spot; ///< Spot removal tool
ColorManagementParams icm; ///< profiles/color spaces used during the image processing
RAWParams raw; ///< RAW parameters before demosaicing
WaveletParams wavelet; ///< Wavelet parameters