Merge branch 'dev' into spot-removal-tool
This commit is contained in:
@@ -205,10 +205,8 @@ void Crop::update(int todo)
|
||||
}
|
||||
|
||||
int numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip;
|
||||
int kall = 2;
|
||||
|
||||
parent->ipf.Tile_calc(tilesize, overlap, kall, widIm, heiIm, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
|
||||
kall = 0;
|
||||
parent->ipf.Tile_calc(tilesize, overlap, 2, widIm, heiIm, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
|
||||
|
||||
float *min_b = new float [9];
|
||||
float *min_r = new float [9];
|
||||
@@ -661,10 +659,9 @@ void Crop::update(int todo)
|
||||
|
||||
if (todo & M_LINDENOISE) {
|
||||
if (skip == 1 && denoiseParams.enabled) {
|
||||
int kall = 0;
|
||||
|
||||
float nresi, highresi;
|
||||
parent->ipf.RGB_denoise(kall, origCrop, origCrop, calclum, parent->denoiseInfoStore.ch_M, parent->denoiseInfoStore.max_r, parent->denoiseInfoStore.max_b, parent->imgsrc->isRAW(), /*Roffset,*/ denoiseParams, parent->imgsrc->getDirPyrDenoiseExpComp(), noiseLCurve, noiseCCurve, nresi, highresi);
|
||||
parent->ipf.RGB_denoise(0, origCrop, origCrop, calclum, parent->denoiseInfoStore.ch_M, parent->denoiseInfoStore.max_r, parent->denoiseInfoStore.max_b, parent->imgsrc->isRAW(), /*Roffset,*/ denoiseParams, parent->imgsrc->getDirPyrDenoiseExpComp(), noiseLCurve, noiseCCurve, nresi, highresi);
|
||||
|
||||
if (parent->adnListener) {
|
||||
parent->adnListener->noiseChanged(nresi, highresi);
|
||||
@@ -915,9 +912,6 @@ void Crop::update(int todo)
|
||||
if (skip == 1) {
|
||||
if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) {
|
||||
parent->ipf.impulsedenoise(labnCrop);
|
||||
}
|
||||
|
||||
if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) {
|
||||
parent->ipf.defringe(labnCrop);
|
||||
}
|
||||
|
||||
@@ -930,7 +924,6 @@ void Crop::update(int todo)
|
||||
}
|
||||
|
||||
// if (skip==1) {
|
||||
WaveletParams WaveParams = params.wavelet;
|
||||
|
||||
if (params.dirpyrequalizer.cbdlMethod == "aft") {
|
||||
if (((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled))) {
|
||||
@@ -939,81 +932,81 @@ void Crop::update(int todo)
|
||||
}
|
||||
}
|
||||
|
||||
int kall = 0;
|
||||
int minwin = min(labnCrop->W, labnCrop->H);
|
||||
int maxlevelcrop = 10;
|
||||
|
||||
// if(cp.mul[9]!=0)maxlevelcrop=10;
|
||||
// adap maximum level wavelet to size of crop
|
||||
if (minwin * skip < 1024) {
|
||||
maxlevelcrop = 9; //sampling wavelet 512
|
||||
}
|
||||
|
||||
if (minwin * skip < 512) {
|
||||
maxlevelcrop = 8; //sampling wavelet 256
|
||||
}
|
||||
|
||||
if (minwin * skip < 256) {
|
||||
maxlevelcrop = 7; //sampling 128
|
||||
}
|
||||
|
||||
if (minwin * skip < 128) {
|
||||
maxlevelcrop = 6;
|
||||
}
|
||||
|
||||
if (minwin < 64) {
|
||||
maxlevelcrop = 5;
|
||||
}
|
||||
|
||||
int realtile;
|
||||
|
||||
if (params.wavelet.Tilesmethod == "big") {
|
||||
realtile = 22;
|
||||
} else /*if (params.wavelet.Tilesmethod == "lit")*/ {
|
||||
realtile = 12;
|
||||
}
|
||||
|
||||
int tilesize = 128 * realtile;
|
||||
int overlap = (int) tilesize * 0.125f;
|
||||
|
||||
int numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip;
|
||||
|
||||
parent->ipf.Tile_calc(tilesize, overlap, kall, labnCrop->W, labnCrop->H, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
|
||||
//now we have tile dimensions, overlaps
|
||||
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
int minsizetile = min(tilewidth, tileheight);
|
||||
int maxlev2 = 10;
|
||||
|
||||
if (minsizetile < 1024 && maxlevelcrop == 10) {
|
||||
maxlev2 = 9;
|
||||
}
|
||||
|
||||
if (minsizetile < 512) {
|
||||
maxlev2 = 8;
|
||||
}
|
||||
|
||||
if (minsizetile < 256) {
|
||||
maxlev2 = 7;
|
||||
}
|
||||
|
||||
if (minsizetile < 128) {
|
||||
maxlev2 = 6;
|
||||
}
|
||||
|
||||
int maxL = min(maxlev2, maxlevelcrop);
|
||||
|
||||
if (parent->awavListener) {
|
||||
parent->awavListener->wavChanged(float (maxL));
|
||||
}
|
||||
|
||||
if ((params.wavelet.enabled)) {
|
||||
WaveletParams WaveParams = params.wavelet;
|
||||
int kall = 0;
|
||||
int minwin = min(labnCrop->W, labnCrop->H);
|
||||
int maxlevelcrop = 10;
|
||||
|
||||
// if(cp.mul[9]!=0)maxlevelcrop=10;
|
||||
// adap maximum level wavelet to size of crop
|
||||
if (minwin * skip < 1024) {
|
||||
maxlevelcrop = 9; //sampling wavelet 512
|
||||
}
|
||||
|
||||
if (minwin * skip < 512) {
|
||||
maxlevelcrop = 8; //sampling wavelet 256
|
||||
}
|
||||
|
||||
if (minwin * skip < 256) {
|
||||
maxlevelcrop = 7; //sampling 128
|
||||
}
|
||||
|
||||
if (minwin * skip < 128) {
|
||||
maxlevelcrop = 6;
|
||||
}
|
||||
|
||||
if (minwin < 64) {
|
||||
maxlevelcrop = 5;
|
||||
}
|
||||
|
||||
int realtile;
|
||||
|
||||
if (params.wavelet.Tilesmethod == "big") {
|
||||
realtile = 22;
|
||||
} else /*if (params.wavelet.Tilesmethod == "lit")*/ {
|
||||
realtile = 12;
|
||||
}
|
||||
|
||||
int tilesize = 128 * realtile;
|
||||
int overlap = (int) tilesize * 0.125f;
|
||||
|
||||
int numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip;
|
||||
|
||||
parent->ipf.Tile_calc(tilesize, overlap, kall, labnCrop->W, labnCrop->H, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
|
||||
//now we have tile dimensions, overlaps
|
||||
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||
int minsizetile = min(tilewidth, tileheight);
|
||||
int maxlev2 = 10;
|
||||
|
||||
if (minsizetile < 1024 && maxlevelcrop == 10) {
|
||||
maxlev2 = 9;
|
||||
}
|
||||
|
||||
if (minsizetile < 512) {
|
||||
maxlev2 = 8;
|
||||
}
|
||||
|
||||
if (minsizetile < 256) {
|
||||
maxlev2 = 7;
|
||||
}
|
||||
|
||||
if (minsizetile < 128) {
|
||||
maxlev2 = 6;
|
||||
}
|
||||
|
||||
int maxL = min(maxlev2, maxlevelcrop);
|
||||
|
||||
if (parent->awavListener) {
|
||||
parent->awavListener->wavChanged(float (maxL));
|
||||
}
|
||||
|
||||
WavCurve wavCLVCurve;
|
||||
WavOpacityCurveRG waOpacityCurveRG;
|
||||
WavOpacityCurveBY waOpacityCurveBY;
|
||||
WavOpacityCurveW waOpacityCurveW;
|
||||
WavOpacityCurveWL waOpacityCurveWL;
|
||||
LUTf wavclCurve;
|
||||
LUTu dummy;
|
||||
|
||||
params.wavelet.getCurves(wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL);
|
||||
|
||||
|
Reference in New Issue
Block a user