print LCP error messages about missing vignette/CA correction only when settings->verbose

This commit is contained in:
Alberto Griggio
2017-04-11 11:44:39 +02:00
parent ecae94f17c
commit e215ad4c6c

View File

@@ -28,11 +28,18 @@
#include <shlobj.h>
#endif
#include "settings.h"
using namespace std;
using namespace rtengine;
namespace rtengine {
extern const Settings* settings;
}
LCPModelCommon::LCPModelCommon() :
foc_len_x(-1.0f),
foc_len_y(-1.0f),
@@ -603,7 +610,9 @@ void LCPProfile::calcParams(int mode, float focalLength, float focusDist, float
//printf("LCP mode=%i, dist: %g found frames: Fno %g-%g; FocLen %g-%g; Dist %g-%g with weight %g\n", mode, focusDist, pLow->aperture, pHigh->aperture, pLow->focLen, pHigh->focLen, pLow->focDist, pHigh->focDist, facLow);
} else {
printf("Error: LCP file contained no %s parameters\n", mode == 0 ? "vignette" : mode == 1 ? "distortion" : "CA" );
if (settings->verbose) {
printf("Error: LCP file contained no %s parameters\n", mode == 0 ? "vignette" : mode == 1 ? "distortion" : "CA" );
}
}
}