diff --git a/rtdata/languages/default b/rtdata/languages/default index 31192d8fb..256dcccb9 100644 --- a/rtdata/languages/default +++ b/rtdata/languages/default @@ -1610,7 +1610,7 @@ TP_GAMMA_PRIM_WIDEG;Widegamut TP_GAMMA_PRIM_BEST;BestRGB TP_GAMMA_PRIM_BETA;BetaRGB TP_GAMMA_PRIM_BRUCE;BruceRGB -TP_GAMMA_TEMP;D illuminant (icc V4)temp +TP_GAMMA_TEMP;Illuminant (icc V4)temp TP_GAMMA_TEMP_DEF;Default TP_GAMMA_TEMP_41;D41 TP_GAMMA_TEMP_50;D50 @@ -1618,6 +1618,7 @@ TP_GAMMA_TEMP_55;D55 TP_GAMMA_TEMP_60;D60 TP_GAMMA_TEMP_65;D65 TP_GAMMA_TEMP_80;D80 +TP_GAMMA_TEMP_INC;Incandescent 2856K TP_GAMMA_TEMP_TOOLTIP;Only whith generate ICC V4, you can change the D illuminant TP_GENERAL_11SCALE_TOOLTIP;The effects of this tool are only visible or only accurate at a preview scale of 1:1. TP_GRADIENT_CENTER;Center diff --git a/rtengine/iccstore.cc b/rtengine/iccstore.cc index fad3b569d..75718f843 100644 --- a/rtengine/iccstore.cc +++ b/rtengine/iccstore.cc @@ -1440,11 +1440,13 @@ cmsHPROFILE rtengine::ICCStore::createGammaProfile(const procparams::ColorManage } else if (icm.wtemp == "D55") { tempv4 = 5500.; } else if (icm.wtemp == "D60") { - tempv4 = 6005.; + tempv4 = 6004.; } else if (icm.wtemp == "D65") { tempv4 = 6504.; } else if (icm.wtemp == "D80") { tempv4 = 8000.; + } else if (icm.wtemp == "INC") { + tempv4 = 5003.; } } @@ -1454,7 +1456,8 @@ cmsHPROFILE rtengine::ICCStore::createGammaProfile(const procparams::ColorManage } else { cmsWhitePointFromTemp(&xyD, (double)temp); } - + + if (icm.wtemp == "INC") xyD = {0.447573, 0.407440, 1.0}; // cmsWhitePointFromTemp(&xyD, (double)temp); @@ -1589,6 +1592,8 @@ cmsHPROFILE rtengine::ICCStore::createCustomGammaOutputProfile(const procparams: outPr = outPr + "D65"; } else if (icm.wtemp == "D80") { outPr = outPr + "D80"; + } else if (icm.wtemp == "INC") { + outPr = outPr + "INC"; } // printf("outpr=%s \n",outPr.c_str()); @@ -1771,13 +1776,15 @@ cmsHPROFILE rtengine::ICCStore::createCustomGammaOutputProfile(const procparams: } else if (icm.wtemp == "D55") { tempv4 = 5500.; } else if (icm.wtemp == "D60") { - tempv4 = 6005.; + tempv4 = 6004.; } else if (icm.wtemp == "D65") { tempv4 = 6504.; } else if (icm.wtemp == "D80") { tempv4 = 8000.; + } else if (icm.wtemp == "INC") { + tempv4 = 5003.; } - printf("tempv4=%f \n", tempv4); + //printf("tempv4=%f \n", tempv4); } @@ -1786,6 +1793,7 @@ cmsHPROFILE rtengine::ICCStore::createCustomGammaOutputProfile(const procparams: } else { cmsWhitePointFromTemp(&xyD, (double)temp); } + if (icm.wtemp == "INC") xyD = {0.447573, 0.407440, 1.0}; cmsToneCurve* GammaTRC[3]; diff --git a/rtgui/icmpanel.cc b/rtgui/icmpanel.cc index 68bdc434f..c647b2c04 100644 --- a/rtgui/icmpanel.cc +++ b/rtgui/icmpanel.cc @@ -326,6 +326,8 @@ ICMPanel::ICMPanel() : FoldableToolPanel(this, "icm", M("TP_ICM_LABEL")), iuncha wtemp->append(M("TP_GAMMA_TEMP_60")); wtemp->append(M("TP_GAMMA_TEMP_65")); wtemp->append(M("TP_GAMMA_TEMP_80")); + wtemp->append(M("TP_GAMMA_TEMP_INC")); + wtemp->set_active(0); wtemp->set_tooltip_text(M("TP_GAMMA_TEMP_TOOLTIP")); @@ -643,6 +645,8 @@ void ICMPanel::read(const ProcParams* pp, const ParamsEdited* pedited) wtemp->set_active(5); } else if (pp->icm.wtemp == "D80") { wtemp->set_active(6); + } else if (pp->icm.wtemp == "INC") { + wtemp->set_active(7); } @@ -836,6 +840,8 @@ void ICMPanel::write(ProcParams* pp, ParamsEdited* pedited) pp->icm.wtemp = "D65"; } else if (wtemp->get_active_row_number() == 6) { pp->icm.wtemp = "D80"; + } else if (wtemp->get_active_row_number() == 7) { + pp->icm.wtemp = "INC"; } pp->icm.freegamma = freegamma->get_active();