Fix issue #3411 + revert some code to the old one for better readability

This commit is contained in:
Hombre
2016-09-03 00:49:35 +02:00
parent bdf4665c16
commit a69c631f22
7 changed files with 31 additions and 93 deletions

View File

@@ -519,11 +519,12 @@ cmsHPROFILE ICCStore::createGammaProfile (const procparams::ColorManagementParam
// 7 parameters for smoother curves
cmsFloat64Number Parameters[7] = { ga[0], ga[1], ga[2], ga[3], ga[4], ga[5], ga[6] } ;
lcmsMutex->lock ();
cmsWhitePointFromTemp(&xyD, (double)temp);
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(NULL, 5, Parameters); //5 = smoother than 4
cmsHPROFILE oprofdef = cmsCreateRGBProfile(&xyD, &Primaries, GammaTRC); //oprofdef become Outputprofile
cmsFreeToneCurve(GammaTRC[0]);
lcmsMutex->unlock ();
return oprofdef;
}