Improve mask preview and avoid reprocessing when switching spot

Changes:
- Mask preview has been improved. It only applies on detailed image now
("dcrop" pipeline) which corrects unexpected behavior on navigator
image. Mask preview now only applies on selected spot: when switching
between spots, mask preview is deactivated on newly selected spot.
- Image reprocessing is now avoided when switching between spots (except
if mask preview was previously activated). Mask background update
remains functionnal.

Bugfixe:
- AStyle runned on several modified files
This commit is contained in:
Pandagrapher
2019-08-21 13:40:28 +02:00
parent 53eeffbebf
commit 2080f65197
13 changed files with 273 additions and 147 deletions

View File

@@ -157,6 +157,15 @@ public:
* @return True if a spot corresponding to the id has been selected
*/
bool setSelectedSpot(const int id);
/**
* Setter for mask preview active indicator
*
* @param ind True is mask preview is active
*/
void setMaskPrevActive(bool ind)
{
maskPrevActive = ind;
}
// Control spot creation functions
/**
@@ -208,13 +217,6 @@ public:
* @param pedited ParamsEdited containing default state values to set to the adjusters (not used because batch mode is deactivated for Locallab)
*/
void setDefaults(const rtengine::procparams::ProcParams* defParams, const ParamsEdited* pedited = nullptr);
/**
* Variant of setDefaults function which only update adjuster default states
*
* @param pedited ParamsEdited containing default states to set to the adjusters
* @param id Spot id to consider to update adjusters default states
*/
// void updateDefaultsStates(const ParamsEdited* pedited, int id = 0);
/**
* Enable or disable the interactions with panel widgets
*
@@ -378,6 +380,7 @@ private:
bool visibilityChanged_;
int eventType; // 0 = No event, 1 = Spot creation event, 2 = Spot deletion event, 3 = Spot selection event, 4 = Spot duplication event
Gtk::Frame* const excluFrame;
bool maskPrevActive;
// Row background color
Gdk::RGBA colorMouseover, colorNominal, colorMouseovertext;