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

@@ -21,7 +21,6 @@
#include "locallabtools.h"
#include "options.h"
#include "multilangmgr.h"
#include "../rtengine/procparams.h"
#define MINCHRO 0.
@@ -181,6 +180,11 @@ LocallabTone::LocallabTone():
pack_start(*sensitm);
}
void LocallabTone::getMaskView(int &colorMask, int &expMask, int &shMask, int &softMask, int &tmMask, int &retiMask, int &cbMask)
{
tmMask = showMaskMethod->get_active_row_number();
}
void LocallabTone::disableListener()
{
LocallabTool::disableListener();
@@ -458,7 +462,7 @@ void LocallabTone::showMaskMethodChanged()
}
if (listener) {
listener->panelChanged(EvLocallabEnatmMask, ""); // TODO Use generic event for mask preview
listener->panelChanged(EvlocallabshowmaskMethod, "");
}
}
@@ -595,6 +599,11 @@ LocallabRetinex::~LocallabRetinex()
delete LocalcurveEditorgainT;
}
void LocallabRetinex::getMaskView(int &colorMask, int &expMask, int &shMask, int &softMask, int &tmMask, int &retiMask, int &cbMask)
{
retiMask = showMaskMethod->get_active_row_number();
}
void LocallabRetinex::disableListener()
{
LocallabTool::disableListener();
@@ -959,7 +968,7 @@ void LocallabRetinex::showMaskMethodChanged()
}
if (listener) {
listener->panelChanged(EvlocallabshowmaskretiMethod, ""); // TODO Use generic event for mask preview
listener->panelChanged(EvlocallabshowmaskMethod, "");
}
}
@@ -1663,6 +1672,11 @@ LocallabCBDL::LocallabCBDL():
pack_start(*sensicb);
}
void LocallabCBDL::getMaskView(int &colorMask, int &expMask, int &shMask, int &softMask, int &tmMask, int &retiMask, int &cbMask)
{
cbMask = showMaskMethod->get_active_row_number();
}
void LocallabCBDL::disableListener()
{
LocallabTool::disableListener();
@@ -1950,7 +1964,7 @@ void LocallabCBDL::showMaskMethodChanged()
}
if (listener) {
listener->panelChanged(EvlocallabshowmaskcbMethod, ""); // TODO Use generic event for mask preview
listener->panelChanged(EvlocallabshowmaskMethod, "");
}
}