Merge pull request #4449 from Beep6581/flatfield_monochrom

Flatfield correction for monochrome raw files, fixes #4418
This commit is contained in:
Ingo Weyrich
2018-03-20 14:44:45 +01:00
committed by GitHub
9 changed files with 61 additions and 25 deletions

View File

@@ -261,7 +261,7 @@ ToolPanelCoordinator::~ToolPanelCoordinator ()
delete toolBar;
}
void ToolPanelCoordinator::imageTypeChanged (bool isRaw, bool isBayer, bool isXtrans)
void ToolPanelCoordinator::imageTypeChanged (bool isRaw, bool isBayer, bool isXtrans, bool isMono)
{
if (isRaw) {
if (isBayer) {
@@ -292,7 +292,20 @@ void ToolPanelCoordinator::imageTypeChanged (bool isRaw, bool isBayer, bool isXt
};
idle_register.add(func, this);
}
else {
else if (isMono) {
const auto func = [](gpointer data) -> gboolean {
ToolPanelCoordinator* const self = static_cast<ToolPanelCoordinator*>(data);
self->rawPanelSW->set_sensitive (true);
self->sensorbayer->FoldableToolPanel::hide();
self->sensorxtrans->FoldableToolPanel::hide();
self->preprocess->FoldableToolPanel::hide();
self->flatfield->FoldableToolPanel::show();
return FALSE;
};
idle_register.add(func, this);
} else {
const auto func = [](gpointer data) -> gboolean {
ToolPanelCoordinator* const self = static_cast<ToolPanelCoordinator*>(data);

View File

@@ -218,7 +218,7 @@ public:
// toolpanellistener interface
void panelChanged (rtengine::ProcEvent event, const Glib::ustring& descr);
void imageTypeChanged (bool isRaw, bool isBayer, bool isXtrans);
void imageTypeChanged (bool isRaw, bool isBayer, bool isXtrans, bool isMono = false);
// profilechangelistener interface
void profileChange (const rtengine::procparams::PartialProfile* nparams, rtengine::ProcEvent event, const Glib::ustring& descr, const ParamsEdited* paramsEdited = nullptr);
void setDefaults (rtengine::procparams::ProcParams* defparams);