From eeb24af8f0d9c76b107d4758412aec6a7427cae7 Mon Sep 17 00:00:00 2001 From: Desmis Date: Tue, 25 Feb 2020 12:48:23 +0100 Subject: [PATCH] Suppress message in console except verbose --- rtengine/improccoordinator.cc | 12 +++++++++--- rtengine/rawimagesource.cc | 4 +++- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/rtengine/improccoordinator.cc b/rtengine/improccoordinator.cc index d8d38e14a..f5bdbbc5d 100644 --- a/rtengine/improccoordinator.cc +++ b/rtengine/improccoordinator.cc @@ -255,7 +255,9 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange) RAWParams rp = params->raw; ColorManagementParams cmp = params->icm; LCurveParams lcur = params->labCurve; - printf("metwb2=%s \n", params->wb.method.c_str()); + if (settings->verbose) { + printf("metwb2=%s \n", params->wb.method.c_str()); + } if (!highDetailNeeded) { // if below 100% magnification, take a fast path @@ -419,7 +421,9 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange) bool autowb = false; autowb = (params->wb.method == "autold" || params->wb.method == "aut" || params->wb.method == "autosdw" || params->wb.method == "autedgsdw" || params->wb.method == "autitcgreen" || params->wb.method == "autedgrob" || params->wb.method == "autedg" || params->wb.method == "autorobust"); - printf("automethod=%s \n", params->wb.method.c_str()); + if (settings->verbose) { + printf("automethod=%s \n", params->wb.method.c_str()); + } if (todo & (M_INIT | M_LINDENOISE | M_HDR)) { MyMutex::MyLock initLock(minit); // Also used in crop window @@ -447,7 +451,9 @@ void ImProcCoordinator::updatePreviewImage(int todo, bool panningRelatedChange) currWBitc = imgsrc->getWB(); double tempref = currWBitc.getTemp() * (1. + params->wb.tempBias); double greenref = currWBitc.getGreen(); - printf("tempref=%f greref=%f\n", tempref, greenref); + if (settings->verbose) { + printf("tempref=%f greref=%f\n", tempref, greenref); + } imgsrc->getAutoWBMultipliersitc(tempref, greenref, tempitc, greenitc, studgood, 0, 0, fh, fw, 0, 0, fh, fw, rm, gm, bm, params->wb, params->icm, params->raw); diff --git a/rtengine/rawimagesource.cc b/rtengine/rawimagesource.cc index 03992a648..9f7c08a8d 100644 --- a/rtengine/rawimagesource.cc +++ b/rtengine/rawimagesource.cc @@ -7034,7 +7034,9 @@ void RawImageSource::ItcWB(bool extra, double &tempref, double &greenref, double } - printf("ITCWB tempitc=%f gritc=%f stud=%f \n", tempitc, greenitc, studgood); + if (settings->verbose) { + printf("ITCWB tempitc=%f gritc=%f stud=%f \n", tempitc, greenitc, studgood); + } xc(0, 0);