Patch from issue 1131: "Predefined White Balance values".
This commit is contained in:
@@ -56,12 +56,12 @@ ImProcCoordinator::ImProcCoordinator ()
|
||||
histLCurve(256);
|
||||
bcabhist(256);
|
||||
|
||||
rCurve(65536,0);
|
||||
rcurvehist(256); rcurvehistCropped(256); rbeforehist(256);
|
||||
gCurve(65536,0);
|
||||
gcurvehist(256); gcurvehistCropped(256); gbeforehist(256);
|
||||
bCurve(65536,0);
|
||||
bcurvehist(256); bcurvehistCropped(256); bbeforehist(256);
|
||||
rCurve(65536,0);
|
||||
rcurvehist(256); rcurvehistCropped(256); rbeforehist(256);
|
||||
gCurve(65536,0);
|
||||
gcurvehist(256); gcurvehistCropped(256); gbeforehist(256);
|
||||
bCurve(65536,0);
|
||||
bcurvehist(256); bcurvehistCropped(256); bbeforehist(256);
|
||||
}
|
||||
|
||||
void ImProcCoordinator::assign (ImageSource* imgsrc) {
|
||||
@@ -156,7 +156,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall) {
|
||||
imgsrc->HLRecovery_Global( params.hlrecovery ); // this handles Color HLRecovery
|
||||
|
||||
if (settings->verbose) printf ("Applying white balance, color correction & sRBG conversion...\n");
|
||||
currWB = ColorTemp (params.wb.temperature, params.wb.green);
|
||||
currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.method);
|
||||
if (params.wb.method=="Camera")
|
||||
currWB = imgsrc->getWB ();
|
||||
else if (params.wb.method=="Auto") {
|
||||
@@ -231,15 +231,15 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall) {
|
||||
params.toneCurve.shcompr, params.toneCurve.brightness, params.toneCurve.contrast, \
|
||||
imgsrc->getGamma(), true, params.toneCurve.curve, \
|
||||
vhist16, histCropped, hltonecurve, shtonecurve, tonecurve, histToneCurve, scale==1 ? 1 : 1);
|
||||
|
||||
CurveFactory::RGBCurve (params.rgbCurves.rcurve, rCurve, scale==1 ? 1 : 1);
|
||||
CurveFactory::RGBCurve (params.rgbCurves.gcurve, gCurve, scale==1 ? 1 : 1);
|
||||
CurveFactory::RGBCurve (params.rgbCurves.bcurve, bCurve, scale==1 ? 1 : 1);
|
||||
|
||||
CurveFactory::RGBCurve (params.rgbCurves.rcurve, rCurve, scale==1 ? 1 : 1);
|
||||
CurveFactory::RGBCurve (params.rgbCurves.gcurve, gCurve, scale==1 ? 1 : 1);
|
||||
CurveFactory::RGBCurve (params.rgbCurves.bcurve, bCurve, scale==1 ? 1 : 1);
|
||||
|
||||
// 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);
|
||||
}
|
||||
|
||||
// compute L channel histogram
|
||||
@@ -526,7 +526,7 @@ void ImProcCoordinator::getSpotWB (int x, int y, int rect, double& temp, double&
|
||||
if (params.coarse.vflip) tr |= TR_VFLIP;
|
||||
|
||||
ColorTemp ret = imgsrc->getSpotWB (red, green, blue, tr);
|
||||
currWB = ColorTemp (params.wb.temperature, params.wb.green);
|
||||
currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.method);
|
||||
mProcessing.unlock ();
|
||||
|
||||
if (ret.getTemp() > 0) {
|
||||
@@ -577,7 +577,7 @@ void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname) {
|
||||
imgsrc->preprocess( ppar.raw );
|
||||
imgsrc->demosaic(ppar.raw );
|
||||
//imgsrc->getImage (imgsrc->getWB(), 0, im, pp, ppar.hlrecovery, ppar.icm, ppar.raw);
|
||||
ColorTemp currWB = ColorTemp (params.wb.temperature, params.wb.green);
|
||||
ColorTemp currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.method);
|
||||
if (params.wb.method=="Camera")
|
||||
currWB = imgsrc->getWB ();
|
||||
else if (params.wb.method=="Auto") {
|
||||
|
Reference in New Issue
Block a user