Merge branch 'dev' into enhance_icc

This commit is contained in:
heckflosse
2018-11-16 22:28:10 +01:00
6 changed files with 140 additions and 16 deletions

View File

@@ -1025,11 +1025,10 @@ void ICCProfileCreator::savePressed()
if (illuminant == "D50") {
xyD = {0.3457, 0.3585, 1.0};//white D50 near LCMS values but not perfect...it's a compromise!!
}
if (illuminant == "stdA") {
xyD = {0.447573, 0.407440, 1.0};
}
} else {
if (v2except) {
@@ -1199,29 +1198,21 @@ void ICCProfileCreator::savePressed()
cmsToneCurve* GammaTRC[3];
if (gammaPreset != "standard_g2.2" || gammaPreset != "standard_g1.8" || gammaPreset != "linear_g1.0") {
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(nullptr, 5, ga);
}
if (gammaPreset == "standard_g2.2") {
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildGamma(NULL, 2.19921875);//spec Adobe
}
if (gammaPreset == "standard_g1.8") {
} else if (gammaPreset == "standard_g1.8") {
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildGamma(NULL, 1.80078125);
}
if (gammaPreset == "linear_g1.0") {
} else if (gammaPreset == "linear_g1.0") {
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildGamma(NULL, 1.0);
} else {
GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(nullptr, 5, ga);
}
if (profileVersion == "v4") {
newProfile = cmsCreateRGBProfile(&xyD, &Primaries, GammaTRC);
}
if (profileVersion == "v2") {
} else if (profileVersion == "v2") {
if (v2except) {
cmsSetProfileVersion(profile_v2_except, 2.2);
} else {