Photo saved via queue from the Editor tab looks different to the one saved from the File Browser tab, issue 1471

This commit is contained in:
Troy Sankey
2012-07-18 18:38:50 -07:00
parent ed4bfcf7d5
commit 61f287b364
6 changed files with 20 additions and 11 deletions

View File

@@ -369,7 +369,7 @@ LINUX
liblcms2-dev libpng-dev libsigc++-2.0-dev libtiff-dev mercurial \
zlib1g-dev
in Fedora, run:
In Fedora, run:
sudo yum install gcc-c++ cmake bzip2-devel exiv2-devel expat-devel \
fftw-devel glib2-devel glibmm24-devel gtk+-devel gtkmm24-devel \
libjpeg-turbo-devel lcms2-devel libiptcdata-devel libpng-devel \

View File

@@ -246,7 +246,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall) {
// if it's just crop we just need the histogram, no image updates
if ( todo!=CROP ) {
ipf.rgbProc (oprevi, oprevl, hltonecurve, shtonecurve, tonecurve, shmap, params.toneCurve.saturation,
rCurve, gCurve, bCurve);
rCurve, gCurve, bCurve, params.toneCurve.expcomp, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh);
}
// compute L channel histogram

View File

@@ -186,9 +186,15 @@ void ImProcFunctions::firstAnalysis (Imagefloat* original, const ProcParams* par
}
// Process RGB image and convert to LAB space
void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
SHMap* shmap, int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve) {
rgbProc (working, lab, hltonecurve, shtonecurve, tonecurve, shmap, sat, rCurve, gCurve, bCurve, params->toneCurve.expcomp, params->toneCurve.hlcompr, params->toneCurve.hlcomprthresh);
}
// Process RGB image and convert to LAB space
void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
SHMap* shmap, int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve,
double expcomp, int hlcompr, int hlcomprthresh) {
int h_th, s_th;
if (shmap) {
@@ -247,9 +253,9 @@ void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, LUTf & hltone
if (sCurveEnabled) sCurve = new FlatCurve(params->hsvequalizer.scurve);
if (vCurveEnabled) vCurve = new FlatCurve(params->hsvequalizer.vcurve);
const float exp_scale = pow (2.0, params->toneCurve.expcomp);
const float comp = (max(0.0, params->toneCurve.expcomp) + 1.0)*params->toneCurve.hlcompr/100.0;
const float shoulder = ((65536.0/max(1.0f,exp_scale))*(params->toneCurve.hlcomprthresh/200.0))+0.1;
const float exp_scale = pow (2.0, expcomp);
const float comp = (max(0.0, expcomp) + 1.0)*hlcompr/100.0;
const float shoulder = ((65536.0/max(1.0f,exp_scale))*(hlcomprthresh/200.0))+0.1;
const float hlrange = 65536.0-shoulder;

View File

@@ -118,6 +118,9 @@ class ImProcFunctions {
void firstAnalysis (Imagefloat* working, const ProcParams* params, LUTu & vhist16, double gamma);
void rgbProc (Imagefloat* working, LabImage* lab, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
SHMap* shmap, int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve);
void rgbProc (Imagefloat* working, LabImage* lab, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
SHMap* shmap, int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve,
double expcomp, int hlcompr, int hlcomprthresh);
void luminanceCurve (LabImage* lold, LabImage* lnew, LUTf &curve);
void chrominanceCurve (LabImage* lold, LabImage* lnew, LUTf &acurve, LUTf &bcurve, LUTf & satcurve);
void vibrance (LabImage* lab);//Jacques' vibrance

View File

@@ -739,7 +739,7 @@ IImage8* Thumbnail::processImage (const procparams::ProcParams& params, int rhei
//CurveFactory::complexCurve (expcomp, black/65535.0, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh,
// params.toneCurve.shcompr, params.toneCurve.brightness, params.toneCurve.contrast,
// gamma, true, params.toneCurve.curve, hist16, dummy, curve1, curve2, curve, dummy, 16);
CurveFactory::complexCurve (expcomp, black/65535.0, hlcompr, params.toneCurve.hlcomprthresh,
CurveFactory::complexCurve (expcomp, black/65535.0, hlcompr, hlcomprthresh,
params.toneCurve.shcompr, bright, contr, gamma, true,
params.toneCurve.curve, hist16, dummy, curve1, curve2, curve, dummy, 16);
@@ -749,7 +749,7 @@ IImage8* Thumbnail::processImage (const procparams::ProcParams& params, int rhei
LabImage* labView = new LabImage (fw,fh);
ipf.rgbProc (baseImg, labView, curve1, curve2, curve, shmap, params.toneCurve.saturation, rCurve, gCurve, bCurve );
ipf.rgbProc (baseImg, labView, curve1, curve2, curve, shmap, params.toneCurve.saturation, rCurve, gCurve, bCurve, expcomp, hlcompr, hlcomprthresh);
if (shmap)
delete shmap;

View File

@@ -160,7 +160,7 @@ IImage16* processImage (ProcessingJob* pjob, int& errorCode, ProgressListener* p
LUTf bCurve (65536,0);
LUTu dummy;
CurveFactory::complexCurve (expcomp, black/65535.0, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh, params.toneCurve.shcompr, bright, params.toneCurve.contrast, imgsrc->getGamma(), true, params.toneCurve.curve,
CurveFactory::complexCurve (expcomp, black/65535.0, hlcompr, hlcomprthresh, params.toneCurve.shcompr, bright, contr, imgsrc->getGamma(), true, params.toneCurve.curve,
hist16, dummy, curve1, curve2, curve, dummy);
CurveFactory::RGBCurve (params.rgbCurves.rcurve, rCurve, 1);
@@ -169,7 +169,7 @@ IImage16* processImage (ProcessingJob* pjob, int& errorCode, ProgressListener* p
LabImage* labView = new LabImage (fw,fh);
ipf.rgbProc (baseImg, labView, curve1, curve2, curve, shmap, params.toneCurve.saturation, rCurve, gCurve, bCurve);
ipf.rgbProc (baseImg, labView, curve1, curve2, curve, shmap, params.toneCurve.saturation, rCurve, gCurve, bCurve, expcomp, hlcompr, hlcomprthresh);
// Freeing baseImg because not used anymore
delete baseImg;