Add structure to shape detection for colorlight and exposure
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include <fstream>
|
||||
#include <string>
|
||||
#include <unistd.h>
|
||||
#include "jaggedarray.h"
|
||||
|
||||
#include "iccstore.h"
|
||||
#include <iostream>
|
||||
@@ -772,6 +773,7 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange)
|
||||
float **shbuffer = nullptr;
|
||||
int sca = 1;
|
||||
double huere, chromare, lumare, huerefblu, sobelre;
|
||||
JaggedArray<float> blend(pW, pH);
|
||||
|
||||
for (int sp = 0; sp < params.locallab.nbspot && sp < (int)params.locallab.spots.size(); sp++) {
|
||||
// Set local curves of current spot to LUT
|
||||
@@ -805,9 +807,9 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange)
|
||||
|
||||
// Reference parameters computation
|
||||
if (params.locallab.spots.at(sp).spotMethod == "exc") {
|
||||
ipf.calc_ref(sp, reserv, reserv, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, reserv, reserv, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
} else {
|
||||
ipf.calc_ref(sp, nprevl, nprevl, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, nprevl, nprevl, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
}
|
||||
CurveFactory::complexCurvelocal(ecomp, black / 65535., hlcompr, hlcomprthresh, shcompr, br, cont, lhist16loc,
|
||||
hltonecurveloc, shtonecurveloc, tonecurveloc, lightCurveloc,
|
||||
@@ -830,13 +832,13 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange)
|
||||
* - maxspot, huerefs, centerx and centery aren't used in Lab_Local (only for printf) so values aren't important
|
||||
* - shbuffer is used as nullptr
|
||||
*/
|
||||
ipf.Lab_Local(3, sp, sobelrefs, (float**)shbuffer, nprevl, nprevl, reserv, 0, 0, pW, pH, scale, locRETgainCurve, lllocalcurve, loclhCurve, lochhCurve, locccmasCurve, locllmasCurve, lochhmasCurve, locccmasexpCurve, locllmasexpCurve,
|
||||
ipf.Lab_Local(3, sp, (float**)shbuffer, nprevl, nprevl, reserv, 0, 0, pW, pH, scale, locRETgainCurve, lllocalcurve, loclhCurve, lochhCurve, locccmasCurve, locllmasCurve, lochhmasCurve, locccmasexpCurve, locllmasexpCurve,
|
||||
LHutili, HHutili, cclocalcurve, localskutili, sklocalcurve, localexutili, exlocalcurve, hltonecurveloc, shtonecurveloc, tonecurveloc, lightCurveloc, huerblu, huer, chromar, lumar, sobeler);
|
||||
|
||||
if (params.locallab.spots.at(sp).spotMethod == "exc") {
|
||||
ipf.calc_ref(sp, reserv, reserv, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, reserv, reserv, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
} else {
|
||||
ipf.calc_ref(sp, nprevl, nprevl, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, nprevl, nprevl, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
}
|
||||
|
||||
// Clear local curves
|
||||
@@ -848,9 +850,9 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange)
|
||||
for (int sp = 0; sp < params.locallab.nbspot && sp < (int)params.locallab.spots.size(); sp++) {
|
||||
//update references after threatment
|
||||
if (params.locallab.spots.at(sp).spotMethod == "exc") {
|
||||
ipf.calc_ref(sp, reserv, reserv, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, reserv, reserv, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
} else {
|
||||
ipf.calc_ref(sp, nprevl, nprevl, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
ipf.calc_ref(sp, nprevl, nprevl, blend, 0, 0, pW, pH, scale, huerefblu, huere, chromare, lumare, sobelre, lhist16loc);
|
||||
}
|
||||
huerblu = huerefblurs[sp] = huerefblu;
|
||||
huer = huerefs[sp] = huere;
|
||||
|
Reference in New Issue
Block a user