diff --git a/rtdata/iccprofiles/output/ACES.icc b/rtdata/iccprofiles/output/ACES.icc
deleted file mode 100644
index cb87b8bf2..000000000
Binary files a/rtdata/iccprofiles/output/ACES.icc and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_Large_g10.icc b/rtdata/iccprofiles/output/RT_Large_g10.icc
deleted file mode 100644
index 1889a5457..000000000
Binary files a/rtdata/iccprofiles/output/RT_Large_g10.icc and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_Large_gBT709.icc b/rtdata/iccprofiles/output/RT_Large_gBT709.icc
deleted file mode 100644
index bd9785f14..000000000
Binary files a/rtdata/iccprofiles/output/RT_Large_gBT709.icc and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_Large_gsRGB.icc b/rtdata/iccprofiles/output/RT_Large_gsRGB.icc
deleted file mode 100644
index 11be3c733..000000000
Binary files a/rtdata/iccprofiles/output/RT_Large_gsRGB.icc and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_Medium_gsRGB.icc b/rtdata/iccprofiles/output/RT_Medium_gsRGB.icc
deleted file mode 100644
index 6c6233d74..000000000
Binary files a/rtdata/iccprofiles/output/RT_Medium_gsRGB.icc and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_sRGB.icm b/rtdata/iccprofiles/output/RT_sRGB.icm
deleted file mode 100644
index 3d0822ef7..000000000
Binary files a/rtdata/iccprofiles/output/RT_sRGB.icm and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_sRGB_g10.icm b/rtdata/iccprofiles/output/RT_sRGB_g10.icm
deleted file mode 100644
index f8afb8e17..000000000
Binary files a/rtdata/iccprofiles/output/RT_sRGB_g10.icm and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RT_sRGB_gBT709.icm b/rtdata/iccprofiles/output/RT_sRGB_gBT709.icm
deleted file mode 100644
index c5c44b7a4..000000000
Binary files a/rtdata/iccprofiles/output/RT_sRGB_gBT709.icm and /dev/null differ
diff --git a/rtdata/iccprofiles/output/RTv2_ACES-AP0.icc b/rtdata/iccprofiles/output/RTv2_ACES-AP0.icc
new file mode 100644
index 000000000..818187898
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_ACES-AP0.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_ACES-AP1.icc b/rtdata/iccprofiles/output/RTv2_ACES-AP1.icc
new file mode 100644
index 000000000..413360817
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_ACES-AP1.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Best.icc b/rtdata/iccprofiles/output/RTv2_Best.icc
new file mode 100644
index 000000000..3f9db89e0
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Best.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Beta.icc b/rtdata/iccprofiles/output/RTv2_Beta.icc
new file mode 100644
index 000000000..ebd5005e2
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Beta.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Bruce.icc b/rtdata/iccprofiles/output/RTv2_Bruce.icc
new file mode 100644
index 000000000..c795da140
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Bruce.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Large.icc b/rtdata/iccprofiles/output/RTv2_Large.icc
new file mode 100644
index 000000000..40f86fcf1
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Large.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Medium.icc b/rtdata/iccprofiles/output/RTv2_Medium.icc
new file mode 100644
index 000000000..59bdf6706
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Medium.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Rec2020.icc b/rtdata/iccprofiles/output/RTv2_Rec2020.icc
new file mode 100644
index 000000000..b6969a6f1
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Rec2020.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_Wide.icc b/rtdata/iccprofiles/output/RTv2_Wide.icc
new file mode 100644
index 000000000..32ce13c7d
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_Wide.icc differ
diff --git a/rtdata/iccprofiles/output/RTv2_sRGB.icc b/rtdata/iccprofiles/output/RTv2_sRGB.icc
new file mode 100644
index 000000000..5efc365f8
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv2_sRGB.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_ACES-AP0.icc b/rtdata/iccprofiles/output/RTv4_ACES-AP0.icc
new file mode 100644
index 000000000..5dbe25a69
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_ACES-AP0.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_ACES-AP1.icc b/rtdata/iccprofiles/output/RTv4_ACES-AP1.icc
new file mode 100644
index 000000000..5dfb4cb0d
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_ACES-AP1.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Best.icc b/rtdata/iccprofiles/output/RTv4_Best.icc
new file mode 100644
index 000000000..c67688686
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Best.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Beta.icc b/rtdata/iccprofiles/output/RTv4_Beta.icc
new file mode 100644
index 000000000..86825164a
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Beta.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Bruce.icc b/rtdata/iccprofiles/output/RTv4_Bruce.icc
new file mode 100644
index 000000000..c3a01b116
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Bruce.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Large.icc b/rtdata/iccprofiles/output/RTv4_Large.icc
new file mode 100644
index 000000000..176bff9a7
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Large.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Medium.icc b/rtdata/iccprofiles/output/RTv4_Medium.icc
new file mode 100644
index 000000000..d63965fa5
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Medium.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Rec2020.icc b/rtdata/iccprofiles/output/RTv4_Rec2020.icc
new file mode 100644
index 000000000..27b1f8c49
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Rec2020.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_Wide.icc b/rtdata/iccprofiles/output/RTv4_Wide.icc
new file mode 100644
index 000000000..f95587797
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_Wide.icc differ
diff --git a/rtdata/iccprofiles/output/RTv4_sRGB.icc b/rtdata/iccprofiles/output/RTv4_sRGB.icc
new file mode 100644
index 000000000..af95e0fd4
Binary files /dev/null and b/rtdata/iccprofiles/output/RTv4_sRGB.icc differ
diff --git a/rtdata/iccprofiles/output/Rec2020.icm b/rtdata/iccprofiles/output/Rec2020.icm
deleted file mode 100644
index 0decaf6dc..000000000
Binary files a/rtdata/iccprofiles/output/Rec2020.icm and /dev/null differ
diff --git a/rtdata/images/Dark/actions/gamut-plus.png b/rtdata/images/Dark/actions/gamut-plus.png
new file mode 100644
index 000000000..2ef6f6041
Binary files /dev/null and b/rtdata/images/Dark/actions/gamut-plus.png differ
diff --git a/rtdata/images/Light/actions/gamut-plus.png b/rtdata/images/Light/actions/gamut-plus.png
new file mode 100644
index 000000000..0270d145d
Binary files /dev/null and b/rtdata/images/Light/actions/gamut-plus.png differ
diff --git a/rtdata/images/themed/png/dark/gamut-plus.png b/rtdata/images/themed/png/dark/gamut-plus.png
new file mode 100644
index 000000000..091e38337
Binary files /dev/null and b/rtdata/images/themed/png/dark/gamut-plus.png differ
diff --git a/rtdata/images/themed/png/light/gamut-plus.png b/rtdata/images/themed/png/light/gamut-plus.png
new file mode 100644
index 000000000..43c0c321a
Binary files /dev/null and b/rtdata/images/themed/png/light/gamut-plus.png differ
diff --git a/rtdata/images/themed/svg/gamut-plus.svg b/rtdata/images/themed/svg/gamut-plus.svg
new file mode 100644
index 000000000..4f4ed503b
--- /dev/null
+++ b/rtdata/images/themed/svg/gamut-plus.svg
@@ -0,0 +1,118 @@
+
+
+
+
diff --git a/rtdata/languages/Catala b/rtdata/languages/Catala
index 8f6faf352..042f5cd56 100644
--- a/rtdata/languages/Catala
+++ b/rtdata/languages/Catala
@@ -999,7 +999,7 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1011,6 +1011,7 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!GENERAL_CLOSE;Close
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTOGRAM_TOOLTIP_CHRO;Show/Hide chromaticity histogram.
@@ -1323,6 +1324,12 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1341,6 +1348,42 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1370,6 +1413,7 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1853,6 +1897,12 @@ ZOOMPANEL_ZOOMOUT;Allunya\nDrecera: -
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LABCURVE_CHROMA_TOOLTIP;To apply B&W toning, set Chromaticity to -100.
!TP_LABCURVE_CURVEEDITOR_CL;CL
!TP_LABCURVE_CURVEEDITOR_CL_TOOLTIP;Chromaticity according to luminance C=f(L)
diff --git a/rtdata/languages/Chinese (Simplified) b/rtdata/languages/Chinese (Simplified)
index d81d1667e..b9ff12214 100644
--- a/rtdata/languages/Chinese (Simplified)
+++ b/rtdata/languages/Chinese (Simplified)
@@ -1060,6 +1060,7 @@ ZOOMPANEL_ZOOMOUT;缩放拉远\n快捷键: -
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTOGRAM_TOOLTIP_BAR;Show/Hide RGB indicator bar.\nRight-click on image preview to freeze/unfreeze.
@@ -1430,6 +1431,12 @@ ZOOMPANEL_ZOOMOUT;缩放拉远\n快捷键: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1447,6 +1454,42 @@ ZOOMPANEL_ZOOMOUT;缩放拉远\n快捷键: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1476,6 +1519,7 @@ ZOOMPANEL_ZOOMOUT;缩放拉远\n快捷键: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1803,6 +1847,12 @@ ZOOMPANEL_ZOOMOUT;缩放拉远\n快捷键: -
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LABCURVE_CHROMA_TOOLTIP;To apply B&W toning, set Chromaticity to -100.
!TP_LABCURVE_CURVEEDITOR_A_RANGE1;Green Saturated
!TP_LABCURVE_CURVEEDITOR_A_RANGE2;Green Pastel
diff --git a/rtdata/languages/Chinese (Traditional) b/rtdata/languages/Chinese (Traditional)
index 2bef0697a..ad3e5c68d 100644
--- a/rtdata/languages/Chinese (Traditional)
+++ b/rtdata/languages/Chinese (Traditional)
@@ -565,7 +565,7 @@ TP_WBALANCE_TEMPERATURE;色溫
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -579,6 +579,7 @@ TP_WBALANCE_TEMPERATURE;色溫
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_WARNING;Warning
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
@@ -985,6 +986,12 @@ TP_WBALANCE_TEMPERATURE;色溫
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1003,6 +1010,42 @@ TP_WBALANCE_TEMPERATURE;色溫
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1033,6 +1076,7 @@ TP_WBALANCE_TEMPERATURE;色溫
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1671,10 +1715,6 @@ TP_WBALANCE_TEMPERATURE;色溫
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1721,6 +1761,12 @@ TP_WBALANCE_TEMPERATURE;色溫
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Czech b/rtdata/languages/Czech
index 7ee30d6d5..e57ebe06d 100644
--- a/rtdata/languages/Czech
+++ b/rtdata/languages/Czech
@@ -2226,6 +2226,7 @@ ZOOMPANEL_ZOOMOUT;Oddálit\nZkratka: -
!ADJUSTER_RESET_TO_DEFAULT;Click - reset to default value.\nCtrl+click - reset to initial value.
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!HISTORY_MSG_235;B&W - CM - Auto
!HISTORY_MSG_237;B&W - CM
!HISTORY_MSG_273;CT - Color Balance SMH
@@ -2234,6 +2235,12 @@ ZOOMPANEL_ZOOMOUT;Oddálit\nZkratka: -
!HISTORY_MSG_489;DRC - Threshold
!HISTORY_MSG_490;DRC - Amount
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_MICROCONTRAST_CONTRAST;Microcontrast - Contrast threshold
!HISTORY_MSG_PIXELSHIFT_DEMOSAIC;PS - Demosaic method for motion
!HISTORY_MSG_PRSHARPEN_CONTRAST;PRS - Contrast threshold
@@ -2243,6 +2250,48 @@ ZOOMPANEL_ZOOMOUT;Oddálit\nZkratka: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_TOOLTIP_PREVIEWSHARPMASK;Preview the Sharpening Contrast Mask.\nShortcut: None\n\nOnly works when sharpening is enabled and zoom >= 100%.
!PARTIALPASTE_PREPROCESS_PDAFLINESFILTER;PDAF lines filter
!PARTIALPASTE_RAW_BORDER;Raw border
@@ -2252,6 +2301,12 @@ ZOOMPANEL_ZOOMOUT;Oddálit\nZkratka: -
!SAMPLEFORMAT_64;32-bit floating-point
!TP_BWMIX_MIXC;Channel Mixer
!TP_BWMIX_NEUTRAL;Reset
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_RAW_2PASS;1-pass+fast
!TP_RAW_4PASS;3-pass+fast
!TP_RAW_AMAZEVNG4;AMaZE+VNG4
diff --git a/rtdata/languages/Dansk b/rtdata/languages/Dansk
index 39dbfa855..f34c8c8f2 100644
--- a/rtdata/languages/Dansk
+++ b/rtdata/languages/Dansk
@@ -557,7 +557,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -573,6 +573,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -980,6 +981,12 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -998,6 +1005,42 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1028,6 +1071,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1668,10 +1712,6 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1718,6 +1758,12 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Deutsch b/rtdata/languages/Deutsch
index 0a1608184..01349994d 100644
--- a/rtdata/languages/Deutsch
+++ b/rtdata/languages/Deutsch
@@ -2318,3 +2318,62 @@ ZOOMPANEL_ZOOMFITSCREEN;An Bildschirm anpassen\nTaste: Alt + f
ZOOMPANEL_ZOOMIN;Hineinzoomen\nTaste: +
ZOOMPANEL_ZOOMOUT;Herauszoomen\nTaste: -
+!!!!!!!!!!!!!!!!!!!!!!!!!
+! Untranslated keys follow; remove the ! prefix after an entry is translated.
+!!!!!!!!!!!!!!!!!!!!!!!!!
+
+!GENERAL_SAVE_AS;Save as...
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
diff --git a/rtdata/languages/English (UK) b/rtdata/languages/English (UK)
index 47de0e9eb..b36207d72 100644
--- a/rtdata/languages/English (UK)
+++ b/rtdata/languages/English (UK)
@@ -2,7 +2,7 @@ EXPORT_BYPASS_RAW_CCSTEPS;Bypass [raw] False Colour Suppression
FILEBROWSER_COLORLABEL_TOOLTIP;Colour label.\n\nUse dropdown menu or shortcuts:\nShift-Ctrl-0 No Colour\nShift-Ctrl-1 Red\nShift-Ctrl-2 Yellow\nShift-Ctrl-3 Green\nShift-Ctrl-4 Blue\nShift-Ctrl-5 Purple
FILEBROWSER_POPUPCOLORLABEL;Colour label
FILEBROWSER_SHOWUNCOLORHINT;Show images without a colour label.\nShortcut: Alt-0
-FILECHOOSER_FILTER_COLPROF;Colour profiles
+FILECHOOSER_FILTER_COLPROF;Colour profiles (*.icc)
HISTORY_MSG_46;Colour denoising
HISTORY_MSG_69;Working colour space
HISTORY_MSG_70;Output colour space
@@ -343,6 +343,7 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!GENERAL_PORTRAIT;Portrait
!GENERAL_RESET;Reset
!GENERAL_SAVE;Save
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -816,6 +817,12 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!HISTORY_MSG_493;L*a*b* Adjustments
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -837,6 +844,42 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
!HISTORY_SNAPSHOT;Snapshot
!HISTORY_SNAPSHOTS;Snapshots
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORY;Category
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITY;City
@@ -884,6 +927,7 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1631,10 +1675,6 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!TP_FLATFIELD_BT_VERTICAL;Vertical
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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_X_TOOLTIP;Shift gradient to the left (negative values) or right (positive values).
!TP_GRADIENT_CENTER_Y_TOOLTIP;Shift gradient up (negative values) or down (positive values).
@@ -1685,6 +1725,12 @@ TP_WBALANCE_EQBLUERED_TOOLTIP;Allows to deviate from the normal behaviour of "wh
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
!TP_ICM_WORKINGPROFILE;Working Profile
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_BRIGHTNESS;Lightness
diff --git a/rtdata/languages/English (US) b/rtdata/languages/English (US)
index 01328cdaa..4b6707a3f 100644
--- a/rtdata/languages/English (US)
+++ b/rtdata/languages/English (US)
@@ -206,7 +206,7 @@
!FILEBROWSER_ZOOMINHINT;Increase thumbnail size.\n\nShortcuts:\n+ - Multiple Editor Tabs Mode,\nAlt-+ - Single Editor Tab Mode.
!FILEBROWSER_ZOOMOUTHINT;Decrease thumbnail size.\n\nShortcuts:\n- - Multiple Editor Tabs Mode,\nAlt-- - Single Editor Tab Mode.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -234,6 +234,7 @@
!GENERAL_PORTRAIT;Portrait
!GENERAL_RESET;Reset
!GENERAL_SAVE;Save
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -730,6 +731,12 @@
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -751,6 +758,42 @@
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
!HISTORY_SNAPSHOT;Snapshot
!HISTORY_SNAPSHOTS;Snapshots
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORY;Category
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITY;City
@@ -798,6 +841,7 @@
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1604,10 +1648,6 @@
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1668,6 +1708,12 @@
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
!TP_ICM_WORKINGPROFILE;Working Profile
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Espanol b/rtdata/languages/Espanol
index 078424424..3402cf13f 100644
--- a/rtdata/languages/Espanol
+++ b/rtdata/languages/Espanol
@@ -1507,7 +1507,7 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1517,6 +1517,7 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_166;Exposure - Reset
@@ -1710,6 +1711,12 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1727,6 +1734,42 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1756,6 +1799,7 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
!MAIN_TAB_ADVANCED_TOOLTIP;Shortcut: Alt-w
@@ -1964,6 +2008,12 @@ ZOOMPANEL_ZOOMOUT;Reducir Zoom\nAtajo: -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LABCURVE_CURVEEDITOR_CC;CC
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
diff --git a/rtdata/languages/Euskara b/rtdata/languages/Euskara
index 7a9f36f96..7a88eb4f1 100644
--- a/rtdata/languages/Euskara
+++ b/rtdata/languages/Euskara
@@ -558,7 +558,7 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -574,6 +574,7 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -981,6 +982,12 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -999,6 +1006,42 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1029,6 +1072,7 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1669,10 +1713,6 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1719,6 +1759,12 @@ TP_WBALANCE_TEMPERATURE;Tenperatura
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Francais b/rtdata/languages/Francais
index ea8fbfc27..269287073 100644
--- a/rtdata/languages/Francais
+++ b/rtdata/languages/Francais
@@ -201,7 +201,7 @@ FILEBROWSER_UNRANK_TOOLTIP;Effacer le rang\nRaccourci: Shift-0
FILEBROWSER_ZOOMINHINT;Augmenter la taille des vignettes.\nRaccourci: +\n\nRaccourcis dans le mode Éditeur Unique: Alt-+
FILEBROWSER_ZOOMOUTHINT;Diminuer la taille des vignettes.\nRaccourci: -\n\nRaccourcis dans le mode Éditeur Unique: Alt--
FILECHOOSER_FILTER_ANY;Tous les fichiers
-FILECHOOSER_FILTER_COLPROF;Profils couleur
+FILECHOOSER_FILTER_COLPROF;Profils couleur (*.icc)
FILECHOOSER_FILTER_CURVE;Fichiers de courbe
FILECHOOSER_FILTER_LCP;Profils de correction d'objectif
FILECHOOSER_FILTER_PP;Fichiers de traitement
@@ -228,6 +228,7 @@ GENERAL_OK;OK
GENERAL_OPEN;Ouvrir
GENERAL_PORTRAIT;Portrait
GENERAL_SAVE;Enregistrer
+GENERAL_SAVE_AS;Enregistrer sous...
GENERAL_SLIDER;Curseur
GENERAL_UNCHANGED;(Inchangé)
GENERAL_WARNING;Attention
@@ -725,6 +726,46 @@ HISTORY_NEWSNAPSHOT;Ajouter
HISTORY_NEWSNAPSHOT_TOOLTIP;Raccourci: Alt-s
HISTORY_SNAPSHOT;Capture
HISTORY_SNAPSHOTS;Captures
+ICCPROFCREATOR_ADD_PARAM_IN_DESC;Ajoute le paramètre Gamma et Pente (Slope) à la fin de la description
+ICCPROFCREATOR_COPYRIGHT;Copyright:
+ICCPROFCREATOR_CUSTOM;Personnalisé
+ICCPROFCREATOR_DESCRIPTION;Description:
+ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Laisser vide pour que mettre la description par défaut
+ICCPROFCREATOR_GAMMA;Gamma
+ICCPROFCREATOR_ICCVERSION;Version du profil généré:
+ICCPROFCREATOR_ILL;Illuminant:
+ICCPROFCREATOR_ILL_41;D41
+ICCPROFCREATOR_ILL_50;D50
+ICCPROFCREATOR_ILL_55;D55
+ICCPROFCREATOR_ILL_60;D60
+ICCPROFCREATOR_ILL_65;D65
+ICCPROFCREATOR_ILL_80;D80
+ICCPROFCREATOR_ILL_DEF;Valeur par défaut
+ICCPROFCREATOR_ILL_INC;StdA 2856K
+ICCPROFCREATOR_ILL_TOOLTIP;Vous ne pouvez régler l'Illuminant que pour les profils ICC v4
+ICCPROFCREATOR_PRIMARIES;Primaires:
+ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+ICCPROFCREATOR_PRIM_BEST;BestRGB
+ICCPROFCREATOR_PRIM_BETA;BetaRGB
+ICCPROFCREATOR_PRIM_BLUX;Bleu X
+ICCPROFCREATOR_PRIM_BLUY;Bleu Y
+ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+ICCPROFCREATOR_PRIM_GREX;Vert X
+ICCPROFCREATOR_PRIM_GREY;Vert Y
+ICCPROFCREATOR_PRIM_PROPH;Prophoto
+ICCPROFCREATOR_PRIM_REC2020;Rec2020
+ICCPROFCREATOR_PRIM_REDX;Rouge X
+ICCPROFCREATOR_PRIM_REDY;Rouge Y
+ICCPROFCREATOR_PRIM_SRGB;sRGB
+ICCPROFCREATOR_PRIM_TOOLTIP;Vous ne pouvez régler des Primaires personnalisées que pour les profils ICC v4
+ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+ICCPROFCREATOR_PROF_V2;ICC v2
+ICCPROFCREATOR_PROF_V4;ICC v4
+ICCPROFCREATOR_SAVEDIALOG_TITLE;Enregistrer le profil ICC sous...
+ICCPROFCREATOR_SLOPE;Pente
+ICCPROFCREATOR_TRC_PRESET;Courbe de réponse tonale:
IPTCPANEL_CATEGORY;Catégorie
IPTCPANEL_CATEGORYHINT;Identifie le sujet de l'image selon l'opinion du fournisseur.
IPTCPANEL_CITY;Ville
@@ -772,6 +813,7 @@ LENSPROFILE_CORRECTION_LCPFILE;Fichier LCP
LENSPROFILE_CORRECTION_MANUAL;Paramètres de correction manuel
LENSPROFILE_LENS_WARNING;Attention: la taille du capteur utilisé pour le profilage de l'objectif est plus grand que celui de l'appareil sélectionné, le résultat peut être faux.
MAIN_BUTTON_FULLSCREEN;Plein écran
+MAIN_BUTTON_ICCPROFCREATOR;Créateur de Profil ICC
MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigue à l'image Suivante relativement à l'image ouverte dans l'Éditeur\nRaccourci: Shift-F4\n\nPour naviguer à l'image Suivante relativement à la vignette sélectionnée dans le Navigateur de fichiers\nRaccourci: F4
MAIN_BUTTON_NAVPREV_TOOLTIP;Navigue à l'image Précédente relativement à l'image ouverte dans l'Éditeur\nRaccourci: Shift-F3\n\nPour naviguer à l'image Précédente relativement à la vignette sélectionnée dans le Navigateur de fichiers\nRaccourci: F3
MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronise le Navigateur de fichiers avec l'Éditeur pour révéler la vignette de l'image actuellement ouverte, et efface les filtres dans le Navigateur de fichiers\nRaccourci: x\n\nComme ci-dessus, mais sans effacer les filtres dans le Navigateur de fichiers\nRaccourci: y\n(Notez que la vignette ne sera pas visible si elle a été filtrée).
@@ -860,7 +902,7 @@ NAVIGATOR_S;S:
NAVIGATOR_V;V:
NAVIGATOR_XY_FULL;Largeur = %1, Hauteur = %2
NAVIGATOR_XY_NA;x = n/d, y = n/d
-OPTIONS_BUNDLED_MISSING;Le profile fourni "%1" n'a pas été trouvé!\n\nVotre installation peut être endomagé.\n\nLes valeurs internes par défaut seront utilisées à la place.
+OPTIONS_BUNDLED_MISSING;Le profil fourni "%1" n'a pas été trouvé!\n\nVotre installation peut être endomagé.\n\nLes valeurs internes par défaut seront utilisées à la place.
OPTIONS_DEFIMG_MISSING;Le profil par défaut pour les images standards n'a pas été trouvé ou n'a pas été réglé.\n\nVérifiez le dossier de vos profils, il peut être manquant ou endommagé\n\n"%1" sera utilisé à la place.
OPTIONS_DEFRAW_MISSING;Le profil par défaut pour les images Raw n'a pas été trouvé ou n'a pas été réglé.\n\nVérifiez le dossier de vos profils, il peut être manquant ou endommagé\n\n"%1" sera utilisé à la place.
PARTIALPASTE_ADVANCEDGROUP;Réglages Avancés
@@ -1576,10 +1618,10 @@ TP_FLATFIELD_BT_VERTICAL;Vertical
TP_FLATFIELD_CLIPCONTROL;Control de l'écrêtage
TP_FLATFIELD_CLIPCONTROL_TOOLTIP;"Contrôle de l'écrêtage" évite les hautes lumière brûlées dûs à l'application du champ uniforme. S'il y a déjà des hautes lumières brûlées avant l'application du champ uniforme, "Contrôle de l'écrêtage" peut conduire à une dérive couleur.
TP_FLATFIELD_LABEL;Champ Uniforme
-TP_GAMMA_CURV;Gamma
-TP_GAMMA_FREE;Manuel
-TP_GAMMA_OUTPUT;Gamma de sortie
-TP_GAMMA_SLOP;Pente (linéaire)
+TP_GAMMA_CURV;Gamma:
+TP_GAMMA_CUSTOM;Manuel
+TP_GAMMA_OUTPUT_TRC_PRESET;Courbe de réponse tonale (TRC):
+TP_GAMMA_SLOP;Pente (linéaire):
TP_GENERAL_11SCALE_TOOLTIP;Les effets de cet outil ne sont visible ou fiable qu'avec un aperçu à l'échelle 1:1.
TP_GRADIENT_CENTER;Centre
TP_GRADIENT_CENTER_X;Centre X
@@ -1640,6 +1682,12 @@ TP_ICM_SAVEREFERENCE_TOOLTIP;Sauvegarde une image TIFF linéaire avant que le pr
TP_ICM_TONECURVE;Utiliser la courbe tonale du profil DCP
TP_ICM_TONECURVE_TOOLTIP;Utilise la courbe tonale DCP incluse. Ce paramètre ne sera actif que si le profil DCP contient une courbe tonale
TP_ICM_WORKINGPROFILE;Profil de Travail
+TP_ICM_WORKTRC;Courbe de réponse tonale:
+TP_ICM_WORKTRC_CUSTOM;Personnalisé
+TP_ICM_WORKTRC_GAMMA;Gamma
+TP_ICM_WORKTRC_NONE;Aucune
+TP_ICM_WORKTRC_SLOPE;Pente
+TP_ICM_WORKTRC_TOOLTIP;Seulement pour les profils internes
TP_IMPULSEDENOISE_LABEL;Réduction du bruit d'impulsion
TP_IMPULSEDENOISE_THRESH;Seuil
TP_LABCURVE_AVOIDCOLORSHIFT;Éviter les dérives de teinte
@@ -2206,6 +2254,12 @@ ZOOMPANEL_ZOOMOUT;Zoom Arrière\nRaccourci: -
!HISTORY_MSG_490;DRC - Amount
!HISTORY_MSG_CLAMPOOG;Out-of-gamut color clipping
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_MICROCONTRAST_CONTRAST;Microcontrast - Contrast threshold
!HISTORY_MSG_PIXELSHIFT_DEMOSAIC;PS - Demosaic method for motion
!HISTORY_MSG_PREPROCESS_LINEDENOISE_DIRECTION;Line noise filter direction
diff --git a/rtdata/languages/Greek b/rtdata/languages/Greek
index 16ee27341..e84d3967f 100644
--- a/rtdata/languages/Greek
+++ b/rtdata/languages/Greek
@@ -557,7 +557,7 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -573,6 +573,7 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -980,6 +981,12 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -998,6 +1005,42 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1028,6 +1071,7 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1668,10 +1712,6 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1718,6 +1758,12 @@ TP_WBALANCE_TEMPERATURE;Θερμοκρασία
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Hebrew b/rtdata/languages/Hebrew
index 92a1c425d..02f097c5e 100644
--- a/rtdata/languages/Hebrew
+++ b/rtdata/languages/Hebrew
@@ -558,7 +558,7 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -574,6 +574,7 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -981,6 +982,12 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -999,6 +1006,42 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1029,6 +1072,7 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1669,10 +1713,6 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1719,6 +1759,12 @@ TP_WBALANCE_TEMPERATURE;מידת חום
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Italiano b/rtdata/languages/Italiano
index 4e146747d..b0f71895a 100644
--- a/rtdata/languages/Italiano
+++ b/rtdata/languages/Italiano
@@ -1342,7 +1342,7 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1352,6 +1352,7 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_166;Exposure - Reset
@@ -1585,6 +1586,12 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1602,6 +1609,42 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1631,6 +1674,7 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_SENDTOEDITOR;Edit image in external editor
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
@@ -1891,6 +1935,12 @@ ZOOMPANEL_ZOOMOUT;Rimpicciolisci.\nScorciatoia: -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Japanese b/rtdata/languages/Japanese
index a573146ab..389f9afeb 100644
--- a/rtdata/languages/Japanese
+++ b/rtdata/languages/Japanese
@@ -2257,3 +2257,62 @@ ZOOMPANEL_ZOOMFITSCREEN;画像全体を画面に合わせる\nショートカッ
ZOOMPANEL_ZOOMIN;ズームイン\nショートカット: +
ZOOMPANEL_ZOOMOUT;ズームアウト\nショートカット: -
+!!!!!!!!!!!!!!!!!!!!!!!!!
+! Untranslated keys follow; remove the ! prefix after an entry is translated.
+!!!!!!!!!!!!!!!!!!!!!!!!!
+
+!GENERAL_SAVE_AS;Save as...
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
diff --git a/rtdata/languages/Latvian b/rtdata/languages/Latvian
index c39b5c03e..90ac6ca8d 100644
--- a/rtdata/languages/Latvian
+++ b/rtdata/languages/Latvian
@@ -558,7 +558,7 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -574,6 +574,7 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -981,6 +982,12 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -999,6 +1006,42 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1029,6 +1072,7 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1669,10 +1713,6 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1719,6 +1759,12 @@ TP_WBALANCE_TEMPERATURE;Temperatūra
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Magyar b/rtdata/languages/Magyar
index 0538c9bc5..5e5676dd6 100644
--- a/rtdata/languages/Magyar
+++ b/rtdata/languages/Magyar
@@ -922,7 +922,7 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -934,6 +934,7 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!GENERAL_CLOSE;Close
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_WARNING;Warning
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
@@ -1254,6 +1255,12 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1272,6 +1279,42 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1301,6 +1344,7 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1817,6 +1861,12 @@ ZOOMPANEL_ZOOMOUT;Kicsinyítés -
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
!TP_LABCURVE_AVOIDCOLORSHIFT_TOOLTIP;Fit colors into gamut of the working color space and apply Munsell correction.
!TP_LABCURVE_CHROMATICITY;Chromaticity
diff --git a/rtdata/languages/Nederlands b/rtdata/languages/Nederlands
index 48fd3852f..b28c0739c 100644
--- a/rtdata/languages/Nederlands
+++ b/rtdata/languages/Nederlands
@@ -2111,6 +2111,7 @@ ZOOMPANEL_ZOOMOUT;Zoom uit\nSneltoets: -
!EXIFFILTER_IMAGETYPE;Image type
!EXIFPANEL_SHOWALL;Show all
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_173;NR - Detail recovery
@@ -2145,6 +2146,12 @@ ZOOMPANEL_ZOOMOUT;Zoom uit\nSneltoets: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -2162,10 +2169,52 @@ ZOOMPANEL_ZOOMOUT;Zoom uit\nSneltoets: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!LENSPROFILE_CORRECTION_AUTOMATCH;Auto-matched correction parameters
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
!MAIN_TAB_ADVANCED_TOOLTIP;Shortcut: Alt-w
@@ -2230,6 +2279,12 @@ ZOOMPANEL_ZOOMOUT;Zoom uit\nSneltoets: -
!TP_EXPOSURE_CLAMPOOG;Clip out-of-gamut colors
!TP_EXPOSURE_HISTMATCHING;Auto-Matched Tone Curve
!TP_EXPOSURE_HISTMATCHING_TOOLTIP;Automatically adjust sliders and curves (except exposure compensation) to match the look of the embedded JPEG thumbnail.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Norsk BM b/rtdata/languages/Norsk BM
index 405244ad1..12e84894f 100644
--- a/rtdata/languages/Norsk BM
+++ b/rtdata/languages/Norsk BM
@@ -557,7 +557,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -573,6 +573,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -980,6 +981,12 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -998,6 +1005,42 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1028,6 +1071,7 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1668,10 +1712,6 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1718,6 +1758,12 @@ TP_WBALANCE_TEMPERATURE;Temperatur
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Polish b/rtdata/languages/Polish
index 1774227b8..530063bf7 100644
--- a/rtdata/languages/Polish
+++ b/rtdata/languages/Polish
@@ -1464,7 +1464,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1474,6 +1474,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_166;Exposure - Reset
@@ -1667,6 +1668,12 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1684,6 +1691,42 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1713,6 +1756,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_SENDTOEDITOR;Edit image in external editor
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
@@ -1912,6 +1956,12 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrót: -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Polish (Latin Characters) b/rtdata/languages/Polish (Latin Characters)
index 68619769d..9b06baa9c 100644
--- a/rtdata/languages/Polish (Latin Characters)
+++ b/rtdata/languages/Polish (Latin Characters)
@@ -1464,7 +1464,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1474,6 +1474,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_166;Exposure - Reset
@@ -1667,6 +1668,12 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1684,6 +1691,42 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1713,6 +1756,7 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_SENDTOEDITOR;Edit image in external editor
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
@@ -1912,6 +1956,12 @@ ZOOMPANEL_ZOOMOUT;Oddal\nSkrot: -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Portugues (Brasil) b/rtdata/languages/Portugues (Brasil)
index 7db8a0168..d02d05157 100644
--- a/rtdata/languages/Portugues (Brasil)
+++ b/rtdata/languages/Portugues (Brasil)
@@ -2226,3 +2226,62 @@ ZOOMPANEL_ZOOMFITSCREEN;Ajustar toda a imagem à tela\nAtalho: Alt-f
ZOOMPANEL_ZOOMIN;Mais Zoom\nAtalho: +
ZOOMPANEL_ZOOMOUT;Menos Zoom\nAtalho: -
+!!!!!!!!!!!!!!!!!!!!!!!!!
+! Untranslated keys follow; remove the ! prefix after an entry is translated.
+!!!!!!!!!!!!!!!!!!!!!!!!!
+
+!GENERAL_SAVE_AS;Save as...
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
diff --git a/rtdata/languages/Russian b/rtdata/languages/Russian
index f79a3a6a5..0af662b62 100644
--- a/rtdata/languages/Russian
+++ b/rtdata/languages/Russian
@@ -1419,6 +1419,7 @@ ZOOMPANEL_ZOOMOUT;Отдалить\nГорячая клавиша: -
!FILECHOOSER_FILTER_PP;Processing profiles
!FILECHOOSER_FILTER_SAME;Same format as current photo
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_235;B&W - CM - Auto
!HISTORY_MSG_237;B&W - CM
@@ -1646,6 +1647,12 @@ ZOOMPANEL_ZOOMOUT;Отдалить\nГорячая клавиша: -
!HISTORY_MSG_CLAMPOOG;Out-of-gamut color clipping
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_MICROCONTRAST_CONTRAST;Microcontrast - Contrast threshold
!HISTORY_MSG_PIXELSHIFT_DEMOSAIC;PS - Demosaic method for motion
!HISTORY_MSG_PREPROCESS_LINEDENOISE_DIRECTION;Line noise filter direction
@@ -1657,6 +1664,47 @@ ZOOMPANEL_ZOOMOUT;Отдалить\nГорячая клавиша: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+!ICCPROFCREATOR_COPYRIGHT;Copyright:
+!ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_DESCRIPTION;Description:
+!ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1682,6 +1730,7 @@ ZOOMPANEL_ZOOMOUT;Отдалить\nГорячая клавиша: -
!IPTCPANEL_TITLEHINT;Enter a short verbal and human readable name for the image, this may be the file name.
!IPTCPANEL_TRANSREFERENCE;Job ID
!IPTCPANEL_TRANSREFERENCEHINT;Enter a number or identifier needed for workflow control or tracking.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TOOLTIP_BACKCOLOR3;Background color of the preview: Middle grey\nShortcut: 9
!MAIN_TOOLTIP_PREVIEWSHARPMASK;Preview the Sharpening Contrast Mask.\nShortcut: None\n\nOnly works when sharpening is enabled and zoom >= 100%.
@@ -1928,6 +1977,12 @@ ZOOMPANEL_ZOOMOUT;Отдалить\nГорячая клавиша: -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_PREPROCESS_DEADPIXFILT;Dead pixel filter
!TP_PREPROCESS_DEADPIXFILT_TOOLTIP;Tries to suppress dead pixels.
!TP_PREPROCESS_HOTPIXFILT;Hot pixel filter
diff --git a/rtdata/languages/Serbian (Cyrilic Characters) b/rtdata/languages/Serbian (Cyrilic Characters)
index f4805db5d..eb1895e74 100644
--- a/rtdata/languages/Serbian (Cyrilic Characters)
+++ b/rtdata/languages/Serbian (Cyrilic Characters)
@@ -1315,7 +1315,7 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1325,6 +1325,7 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_173;NR - Detail recovery
@@ -1561,6 +1562,12 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1578,6 +1585,42 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1607,6 +1650,7 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
!MAIN_TAB_ADVANCED_TOOLTIP;Shortcut: Alt-w
@@ -1893,6 +1937,12 @@ ZOOMPANEL_ZOOMOUT;Умањује приказ слике -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Serbian (Latin Characters) b/rtdata/languages/Serbian (Latin Characters)
index b2b74a879..7eae9ae88 100644
--- a/rtdata/languages/Serbian (Latin Characters)
+++ b/rtdata/languages/Serbian (Latin Characters)
@@ -1315,7 +1315,7 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!FILEBROWSER_SHOWNOTTRASHHINT;Show only non-deleted images.
!FILEBROWSER_SHOWORIGINALHINT;Show only original images.\n\nWhen several images exist with the same filename but different extensions, the one considered original is the one whose extension is nearest the top of the parsed extensions list in Preferences > File Browser > Parsed Extensions.
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -1325,6 +1325,7 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!GENERAL_ASIMAGE;As Image
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_173;NR - Detail recovery
@@ -1561,6 +1562,12 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1578,6 +1585,42 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1607,6 +1650,7 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
!MAIN_TAB_ADVANCED_TOOLTIP;Shortcut: Alt-w
@@ -1893,6 +1937,12 @@ ZOOMPANEL_ZOOMOUT;Umanjuje prikaz slike -
!TP_ICM_SAVEREFERENCE;Save Reference Image
!TP_ICM_SAVEREFERENCE_APPLYWB;Apply white balance
!TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP;Generally, apply the white balance when saving images to create ICC profiles, and do not apply the white balance to create DCP profiles.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Slovak b/rtdata/languages/Slovak
index 001f83720..9e09836d0 100644
--- a/rtdata/languages/Slovak
+++ b/rtdata/languages/Slovak
@@ -633,7 +633,7 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -647,6 +647,7 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_WARNING;Warning
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
@@ -1043,6 +1044,12 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1061,6 +1068,42 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1090,6 +1133,7 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1698,10 +1742,6 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1748,6 +1788,12 @@ ZOOMPANEL_ZOOMOUT;Oddialiť -
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
!TP_LABCURVE_AVOIDCOLORSHIFT_TOOLTIP;Fit colors into gamut of the working color space and apply Munsell correction.
!TP_LABCURVE_CHROMATICITY;Chromaticity
diff --git a/rtdata/languages/Suomi b/rtdata/languages/Suomi
index 4fff8a26b..ee286ef7e 100644
--- a/rtdata/languages/Suomi
+++ b/rtdata/languages/Suomi
@@ -559,7 +559,7 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -575,6 +575,7 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -982,6 +983,12 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1000,6 +1007,42 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1030,6 +1073,7 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1669,10 +1713,6 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1719,6 +1759,12 @@ TP_WBALANCE_TEMPERATURE;Lämpötila [K]
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/Swedish b/rtdata/languages/Swedish
index 25a3541f5..d171f33ce 100644
--- a/rtdata/languages/Swedish
+++ b/rtdata/languages/Swedish
@@ -1876,6 +1876,7 @@ ZOOMPANEL_ZOOMOUT;Förminska.\nKortkommando: -
!EXPORT_USE_NORMAL_PIPELINE;Standard (bypass some steps, resize at the end)
!FILEBROWSER_RESETDEFAULTPROFILE;Reset to default
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GIMP_PLUGIN_INFO;Welcome to the RawTherapee GIMP plugin!\nOnce you are done editing, simply close the main RawTherapee window and the image will be automatically imported in GIMP.
!HISTORY_MSG_173;NR - Detail recovery
@@ -1947,6 +1948,12 @@ ZOOMPANEL_ZOOMOUT;Förminska.\nKortkommando: -
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -1964,6 +1971,42 @@ ZOOMPANEL_ZOOMOUT;Förminska.\nKortkommando: -
!HISTORY_MSG_SOFTLIGHT_ENABLED;Soft light
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1993,6 +2036,7 @@ ZOOMPANEL_ZOOMOUT;Förminska.\nKortkommando: -
!LENSPROFILE_CORRECTION_LCPFILE;LCP File
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_MSG_TOOMANYOPENEDITORS;Too many open editors.\nPlease close an editor to continue.
!MAIN_TAB_ADVANCED;Advanced
!MAIN_TAB_ADVANCED_TOOLTIP;Shortcut: Alt-w
@@ -2100,6 +2144,12 @@ ZOOMPANEL_ZOOMOUT;Förminska.\nKortkommando: -
!TP_ICM_APPLYLOOKTABLE;Look table
!TP_ICM_PROFILEINTENT;Rendering Intent
!TP_ICM_SAVEREFERENCE;Save Reference Image
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_LOCALCONTRAST_AMOUNT;Amount
!TP_LOCALCONTRAST_DARKNESS;Darkness level
!TP_LOCALCONTRAST_LABEL;Local Contrast
diff --git a/rtdata/languages/Turkish b/rtdata/languages/Turkish
index 4ede26e9f..35a9fa43b 100644
--- a/rtdata/languages/Turkish
+++ b/rtdata/languages/Turkish
@@ -558,7 +558,7 @@ TP_WBALANCE_TEMPERATURE;Isı
!FILEBROWSER_SHOWUNCOLORHINT;Show images without a color label.\nShortcut: Alt-0
!FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
!FILECHOOSER_FILTER_ANY;All files
-!FILECHOOSER_FILTER_COLPROF;Color profiles
+!FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
!FILECHOOSER_FILTER_CURVE;Curve files
!FILECHOOSER_FILTER_LCP;Lens correction profiles
!FILECHOOSER_FILTER_PP;Processing profiles
@@ -574,6 +574,7 @@ TP_WBALANCE_TEMPERATURE;Isı
!GENERAL_NONE;None
!GENERAL_OPEN;Open
!GENERAL_RESET;Reset
+!GENERAL_SAVE_AS;Save as...
!GENERAL_SLIDER;Slider
!GENERAL_UNCHANGED;(Unchanged)
!GENERAL_WARNING;Warning
@@ -981,6 +982,12 @@ TP_WBALANCE_TEMPERATURE;Isı
!HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
!HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
!HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+!HISTORY_MSG_ICMGAMM;Working gamma
+!HISTORY_MSG_ICMPRIMARI;Output profile primaries
+!HISTORY_MSG_ICMPROFILE;Output profile type
+!HISTORY_MSG_ICMSLOP;Working slope
+!HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+!HISTORY_MSG_ICMTRCIN;TRC working method
!HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
!HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
!HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -999,6 +1006,42 @@ TP_WBALANCE_TEMPERATURE;Isı
!HISTORY_MSG_SOFTLIGHT_STRENGTH;Soft light - Strength
!HISTORY_MSG_TM_FATTAL_ANCHOR;DRC - Anchor
!HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
+!ICCPROFCREATOR_CUSTOM;Custom
+!ICCPROFCREATOR_GAMMA;Gamma
+!ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+!ICCPROFCREATOR_ILL;Illuminant:
+!ICCPROFCREATOR_ILL_41;D41
+!ICCPROFCREATOR_ILL_50;D50
+!ICCPROFCREATOR_ILL_55;D55
+!ICCPROFCREATOR_ILL_60;D60
+!ICCPROFCREATOR_ILL_65;D65
+!ICCPROFCREATOR_ILL_80;D80
+!ICCPROFCREATOR_ILL_DEF;Default
+!ICCPROFCREATOR_ILL_INC;StdA 2856K
+!ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+!ICCPROFCREATOR_PRIMARIES;Primaries:
+!ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+!ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+!ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+!ICCPROFCREATOR_PRIM_BEST;BestRGB
+!ICCPROFCREATOR_PRIM_BETA;BetaRGB
+!ICCPROFCREATOR_PRIM_BLUX;Blue X
+!ICCPROFCREATOR_PRIM_BLUY;Blue Y
+!ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+!ICCPROFCREATOR_PRIM_GREX;Green X
+!ICCPROFCREATOR_PRIM_GREY;Green Y
+!ICCPROFCREATOR_PRIM_PROPH;Prophoto
+!ICCPROFCREATOR_PRIM_REC2020;Rec2020
+!ICCPROFCREATOR_PRIM_REDX;Red X
+!ICCPROFCREATOR_PRIM_REDY;Red Y
+!ICCPROFCREATOR_PRIM_SRGB;sRGB
+!ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+!ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+!ICCPROFCREATOR_PROF_V2;ICC v2
+!ICCPROFCREATOR_PROF_V4;ICC v4
+!ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+!ICCPROFCREATOR_SLOPE;Slope
+!ICCPROFCREATOR_TRC_PRESET;Tone response curve:
!IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
!IPTCPANEL_CITYHINT;Enter the name of the city pictured in this image.
!IPTCPANEL_COPYRIGHT;Copyright notice
@@ -1029,6 +1072,7 @@ TP_WBALANCE_TEMPERATURE;Isı
!LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
!LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
!MAIN_BUTTON_FULLSCREEN;Fullscreen
+!MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
!MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
!MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
!MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1668,10 +1712,6 @@ TP_WBALANCE_TEMPERATURE;Isı
!TP_FLATFIELD_CLIPCONTROL;Clip control
!TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
!TP_FLATFIELD_LABEL;Flat-Field
-!TP_GAMMA_CURV;Gamma
-!TP_GAMMA_FREE;Free gamma
-!TP_GAMMA_OUTPUT;Output gamma
-!TP_GAMMA_SLOP;Slope (linear)
!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
!TP_GRADIENT_CENTER_X;Center X
@@ -1718,6 +1758,12 @@ TP_WBALANCE_TEMPERATURE;Isı
!TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile is applied. The result can be used for calibration purposes and generation of a camera profile.
!TP_ICM_TONECURVE;Tone curve
!TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
+!TP_ICM_WORKTRC;Tone response curve:
+!TP_ICM_WORKTRC_CUSTOM;Custom
+!TP_ICM_WORKTRC_GAMMA;Gamma
+!TP_ICM_WORKTRC_NONE;None
+!TP_ICM_WORKTRC_SLOPE;Slope
+!TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
!TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
!TP_IMPULSEDENOISE_THRESH;Threshold
!TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtdata/languages/default b/rtdata/languages/default
index 9bd32e982..4bde22209 100644
--- a/rtdata/languages/default
+++ b/rtdata/languages/default
@@ -205,7 +205,7 @@ FILEBROWSER_UNRANK_TOOLTIP;Unrank.\nShortcut: Shift-0
FILEBROWSER_ZOOMINHINT;Increase thumbnail size.\n\nShortcuts:\n+ - Multiple Editor Tabs Mode,\nAlt-+ - Single Editor Tab Mode.
FILEBROWSER_ZOOMOUTHINT;Decrease thumbnail size.\n\nShortcuts:\n- - Multiple Editor Tabs Mode,\nAlt-- - Single Editor Tab Mode.
FILECHOOSER_FILTER_ANY;All files
-FILECHOOSER_FILTER_COLPROF;Color profiles
+FILECHOOSER_FILTER_COLPROF;Color profiles (*.icc)
FILECHOOSER_FILTER_CURVE;Curve files
FILECHOOSER_FILTER_LCP;Lens correction profiles
FILECHOOSER_FILTER_PP;Processing profiles
@@ -233,6 +233,7 @@ GENERAL_OPEN;Open
GENERAL_PORTRAIT;Portrait
GENERAL_RESET;Reset
GENERAL_SAVE;Save
+GENERAL_SAVE_AS;Save as...
GENERAL_SLIDER;Slider
GENERAL_UNCHANGED;(Unchanged)
GENERAL_WARNING;Warning
@@ -729,6 +730,12 @@ HISTORY_MSG_CLAMPOOG;Out-of-gamut color clipping
HISTORY_MSG_COLORTONING_LABGRID_VALUE;CT - Color correction
HISTORY_MSG_DUALDEMOSAIC_CONTRAST;AMaZE+VNG4 - Contrast threshold
HISTORY_MSG_HISTMATCHING;Auto-Matched Tone Curve
+HISTORY_MSG_ICMGAMM;Working gamma
+HISTORY_MSG_ICMPRIMARI;Output profile primaries
+HISTORY_MSG_ICMPROFILE;Output profile type
+HISTORY_MSG_ICMSLOP;Working slope
+HISTORY_MSG_ICMTEMP;Output IccV4 D illuminant
+HISTORY_MSG_ICMTRCIN;TRC working method
HISTORY_MSG_LOCALCONTRAST_AMOUNT;Local Contrast - Amount
HISTORY_MSG_LOCALCONTRAST_DARKNESS;Local Contrast - Darkness
HISTORY_MSG_LOCALCONTRAST_ENABLED;Local Contrast
@@ -750,6 +757,47 @@ HISTORY_NEWSNAPSHOT;Add
HISTORY_NEWSNAPSHOT_TOOLTIP;Shortcut: Alt-s
HISTORY_SNAPSHOT;Snapshot
HISTORY_SNAPSHOTS;Snapshots
+ICCPROFCREATOR_ADD_PARAM_IN_DESC;Append Gamma and Slope values to the description
+ICCPROFCREATOR_COPYRIGHT;Copyright:
+ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP;Reset to the default copyright, granted to "RawTherapee, CC0"
+ICCPROFCREATOR_CUSTOM;Custom
+ICCPROFCREATOR_DESCRIPTION;Description:
+ICCPROFCREATOR_DESCRIPTION_TOOLTIP;Leave empty to set the default description
+ICCPROFCREATOR_GAMMA;Gamma
+ICCPROFCREATOR_ICCVERSION;Generated profile's version:
+ICCPROFCREATOR_ILL;Illuminant:
+ICCPROFCREATOR_ILL_41;D41
+ICCPROFCREATOR_ILL_50;D50
+ICCPROFCREATOR_ILL_55;D55
+ICCPROFCREATOR_ILL_60;D60
+ICCPROFCREATOR_ILL_65;D65
+ICCPROFCREATOR_ILL_80;D80
+ICCPROFCREATOR_ILL_DEF;Default
+ICCPROFCREATOR_ILL_INC;StdA 2856K
+ICCPROFCREATOR_ILL_TOOLTIP;You can only set Illuminant with ICC v4 profiles
+ICCPROFCREATOR_PRIMARIES;Primaries:
+ICCPROFCREATOR_PRIM_ACESP0;ACES AP0
+ICCPROFCREATOR_PRIM_ACESP1;ACES AP1
+ICCPROFCREATOR_PRIM_ADOBE;Adobe RGB (1998)
+ICCPROFCREATOR_PRIM_BEST;BestRGB
+ICCPROFCREATOR_PRIM_BETA;BetaRGB
+ICCPROFCREATOR_PRIM_BLUX;Blue X
+ICCPROFCREATOR_PRIM_BLUY;Blue Y
+ICCPROFCREATOR_PRIM_BRUCE;BruceRGB
+ICCPROFCREATOR_PRIM_GREX;Green X
+ICCPROFCREATOR_PRIM_GREY;Green Y
+ICCPROFCREATOR_PRIM_PROPH;Prophoto
+ICCPROFCREATOR_PRIM_REC2020;Rec2020
+ICCPROFCREATOR_PRIM_REDX;Red X
+ICCPROFCREATOR_PRIM_REDY;Red Y
+ICCPROFCREATOR_PRIM_SRGB;sRGB
+ICCPROFCREATOR_PRIM_TOOLTIP;You can only set Custom Primaries with ICC v4 profiles
+ICCPROFCREATOR_PRIM_WIDEG;Widegamut
+ICCPROFCREATOR_PROF_V2;ICC v2
+ICCPROFCREATOR_PROF_V4;ICC v4
+ICCPROFCREATOR_SAVEDIALOG_TITLE;Save ICC profile as...
+ICCPROFCREATOR_SLOPE;Slope
+ICCPROFCREATOR_TRC_PRESET;Tone response curve:
IPTCPANEL_CATEGORY;Category
IPTCPANEL_CATEGORYHINT;Identifies the subject of the image in the opinion of the provider.
IPTCPANEL_CITY;City
@@ -797,6 +845,7 @@ LENSPROFILE_CORRECTION_LCPFILE;LCP File
LENSPROFILE_CORRECTION_MANUAL;Manual correction parameters
LENSPROFILE_LENS_WARNING;Warning: the crop factor used for lens profiling is larger than the crop factor of the camera, the results might be wrong.
MAIN_BUTTON_FULLSCREEN;Fullscreen
+MAIN_BUTTON_ICCPROFCREATOR;ICC Profile Creator
MAIN_BUTTON_NAVNEXT_TOOLTIP;Navigate to the next image relative to image opened in the Editor.\nShortcut: Shift-F4\n\nTo navigate to the next image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F4
MAIN_BUTTON_NAVPREV_TOOLTIP;Navigate to the previous image relative to image opened in the Editor.\nShortcut: Shift-F3\n\nTo navigate to the previous image relative to the currently selected thumbnail in the File Browser or Filmstrip:\nShortcut: F3
MAIN_BUTTON_NAVSYNC_TOOLTIP;Synchronize the File Browser or Filmstrip with the Editor to reveal the thumbnail of the currently opened image, and clear any active filters.\nShortcut: x\n\nAs above, but without clearing active filters:\nShortcut: y\n(Note that the thumbnail of the opened image will not be shown if filtered out).
@@ -1603,10 +1652,6 @@ TP_FLATFIELD_BT_VERTICAL;Vertical
TP_FLATFIELD_CLIPCONTROL;Clip control
TP_FLATFIELD_CLIPCONTROL_TOOLTIP;Clip control avoids clipped highlights caused by applying the flat field. If there are already clipped highlights before applying the flat field, clip control can lead to color cast.
TP_FLATFIELD_LABEL;Flat-Field
-TP_GAMMA_CURV;Gamma
-TP_GAMMA_FREE;Free gamma
-TP_GAMMA_OUTPUT;Output gamma
-TP_GAMMA_SLOP;Slope (linear)
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
TP_GRADIENT_CENTER_X;Center X
@@ -1667,6 +1712,12 @@ TP_ICM_SAVEREFERENCE_TOOLTIP;Save the linear TIFF image before the input profile
TP_ICM_TONECURVE;Tone curve
TP_ICM_TONECURVE_TOOLTIP;Employ the embedded DCP tone curve. The setting is only available if the selected DCP has a tone curve.
TP_ICM_WORKINGPROFILE;Working Profile
+TP_ICM_WORKTRC;Tone response curve:
+TP_ICM_WORKTRC_CUSTOM;Custom
+TP_ICM_WORKTRC_GAMMA;Gamma
+TP_ICM_WORKTRC_NONE;None
+TP_ICM_WORKTRC_SLOPE;Slope
+TP_ICM_WORKTRC_TOOLTIP;Only for build in profiles
TP_IMPULSEDENOISE_LABEL;Impulse Noise Reduction
TP_IMPULSEDENOISE_THRESH;Threshold
TP_LABCURVE_AVOIDCOLORSHIFT;Avoid color shift
diff --git a/rtengine/FTblockDN.cc b/rtengine/FTblockDN.cc
index cfb237d82..0e5cd58a2 100644
--- a/rtengine/FTblockDN.cc
+++ b/rtengine/FTblockDN.cc
@@ -547,7 +547,7 @@ BENCHFUN
if (useNoiseLCurve || useNoiseCCurve) {
int hei = calclum->getHeight();
int wid = calclum->getWidth();
- TMatrix wprofi = ICCStore::getInstance()->workingSpaceMatrix(params->icm.working);
+ TMatrix wprofi = ICCStore::getInstance()->workingSpaceMatrix(params->icm.workingProfile);
const float wpi[3][3] = {
{static_cast(wprofi[0][0]), static_cast(wprofi[0][1]), static_cast(wprofi[0][2])},
@@ -815,7 +815,7 @@ BENCHFUN
}
}
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix(params->icm.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix(params->icm.workingProfile);
//inverse matrix user select
const float wip[3][3] = {
{static_cast(wiprof[0][0]), static_cast(wiprof[0][1]), static_cast(wiprof[0][2])},
@@ -823,7 +823,7 @@ BENCHFUN
{static_cast(wiprof[2][0]), static_cast(wiprof[2][1]), static_cast(wiprof[2][2])}
};
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix(params->icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix(params->icm.workingProfile);
const float wp[3][3] = {
{static_cast(wprof[0][0]), static_cast(wprof[0][1]), static_cast(wprof[0][2])},
@@ -3166,7 +3166,7 @@ void ImProcFunctions::RGB_denoise_info(Imagefloat * src, Imagefloat * provicalc,
float** bcalc;
hei = provicalc->getHeight();
wid = provicalc->getWidth();
- TMatrix wprofi = ICCStore::getInstance()->workingSpaceMatrix(params->icm.working);
+ TMatrix wprofi = ICCStore::getInstance()->workingSpaceMatrix(params->icm.workingProfile);
const float wpi[3][3] = {
{static_cast(wprofi[0][0]), static_cast(wprofi[0][1]), static_cast(wprofi[0][2])},
@@ -3241,7 +3241,7 @@ void ImProcFunctions::RGB_denoise_info(Imagefloat * src, Imagefloat * provicalc,
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix(params->icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix(params->icm.workingProfile);
const float wp[3][3] = {
{static_cast(wprof[0][0]), static_cast(wprof[0][1]), static_cast(wprof[0][2])},
{static_cast(wprof[1][0]), static_cast(wprof[1][1]), static_cast(wprof[1][2])},
diff --git a/rtengine/clutstore.cc b/rtengine/clutstore.cc
index 4124e38bb..87ce25d97 100644
--- a/rtengine/clutstore.cc
+++ b/rtengine/clutstore.cc
@@ -50,7 +50,7 @@ bool loadFile(
const PreviewProps pp(0, 0, fw, fh, 1);
rtengine::procparams::ColorManagementParams icm;
- icm.working = working_color_space;
+ icm.workingProfile = working_color_space;
img_src.getImage(curr_wb, TR_NONE, img_float.get(), pp, rtengine::procparams::ToneCurveParams(), rtengine::procparams::RAWParams());
diff --git a/rtengine/color.cc b/rtengine/color.cc
index 3cedcaaa6..599aceaa1 100644
--- a/rtengine/color.cc
+++ b/rtengine/color.cc
@@ -190,7 +190,6 @@ void Color::init ()
{
gammatab_srgb[i] = gammatab_srgb1[i] = gamma2(i / 65535.0);
}
-
gammatab_srgb *= 65535.f;
gamma2curve.share(gammatab_srgb, LUT_CLIP_BELOW | LUT_CLIP_ABOVE); // shares the buffer with gammatab_srgb but has different clip flags
}
@@ -394,7 +393,7 @@ void Color::rgb2lab01 (const Glib::ustring &profile, const Glib::ustring &profil
r = pow_F(r, 1.8f);
g = pow_F(g, 1.8f);
b = pow_F(b, 1.8f);
- } else if (profile == "Rec2020") {
+ } else if (profileW == "Rec2020") {
if (r > 0.0795f) {
r = pow_F(((r + 0.0954f) / 1.0954f), 2.2f);
} else {
@@ -418,17 +417,17 @@ void Color::rgb2lab01 (const Glib::ustring &profile, const Glib::ustring &profil
b = pow_F(b, 2.2f);
}
} else { //display output profile
- if (profile == "RT_sRGB" || profile == "RT_sRGB_gBT709" || profile == "RT_sRGB_g10") {
+ if (profile == settings->srgb) {
// use default "sRGB"
- } else if (profile == "ProPhoto" || profile == "RT_Large_gBT709" || profile == "RT_Large_g10" || profile == "RT_Large_gsRGB") {
+ } else if (profile == "ProPhoto" || profile == settings->prophoto) {
profileCalc = "ProPhoto";
- } else if (profile == "AdobeRGB1998" || profile == "RT_Medium_gsRGB") {
+ } else if (profile == "AdobeRGB1998" || profile == settings->adobe) {
profileCalc = "Adobe RGB";
- } else if (profile == "WideGamutRGB") {
+ } else if (profile == settings->widegamut) {
profileCalc = "WideGamut";
}
- if (profile == "RT_sRGB" || profile == "RT_Large_gsRGB" || profile == "RT_Medium_gsRGB") { //apply sRGB inverse gamma
+ if (profile == settings->srgb || profile == settings->adobe) { //apply sRGB inverse gamma
if (r > 0.04045f) {
r = pow_F(((r + 0.055f) / 1.055f), rtengine::Color::sRGBGammaCurve);
} else {
@@ -446,7 +445,7 @@ void Color::rgb2lab01 (const Glib::ustring &profile, const Glib::ustring &profil
} else {
b /= 12.92f;
}
- } else if (profile == "RT_sRGB_gBT709" || profile == "RT_Large_gBT709" || profile == "Rec2020") {
+ } else if (profile == settings->prophoto || profile == settings->rec2020) {
if (r > 0.0795f) {
r = pow_F(((r + 0.0954f) / 1.0954f), 2.2f);
} else {
@@ -470,9 +469,6 @@ void Color::rgb2lab01 (const Glib::ustring &profile, const Glib::ustring &profil
r = pow_F(r, 1.8f);
g = pow_F(g, 1.8f);
b = pow_F(b, 1.8f);
- } else if (profile == "RT_sRGB_g10" || profile == "RT_Large_g10") {
- // gamma 1.0, do nothing
-
} else {// apply inverse gamma 2.2
r = pow_F(r, 2.2f);
@@ -1594,7 +1590,7 @@ void Color::calcGamma (double pwr, double ts, int mode, GammaValues &gamma)
bnd[g[1] >= 1.] = 1.;
if (g[1] && (g[1] - 1.) * (g[0] - 1.) <= 0.) {
- for (i = 0; i < 48; i++) {
+ for (i = 0; i < 99; i++) {
g[2] = (bnd[0] + bnd[1]) / 2.;
if (g[0]) {
diff --git a/rtengine/color.h b/rtengine/color.h
index 3310f6fa6..33c170a69 100644
--- a/rtengine/color.h
+++ b/rtengine/color.h
@@ -1074,25 +1074,35 @@ public:
/**
* @brief sRGB gamma
- * See also calcGamma above with the following values: pwr=2.4 ts=12.92 mode=0.003041 imax=0.055011
+ * See also calcGamma above with the following values: pwr=2.399 ts=12.92310 mode=0.003041 imax=0.055
* @param x red, green or blue channel's value [0 ; 1]
* @return the gamma modified's value [0 ; 1]
*/
static inline double gamma2 (double x) // g3 1+g4
{
- return x <= 0.003041 ? x * 12.92 : 1.055011 * exp(log(x) / sRGBGammaCurve) - 0.055011;
+ // return x <= 0.003041 ? x * 12.92310 : 1.055 * exp(log(x) / 2.39990) - 0.055;//calculate with calcgamma
+ //return x <= 0.0031308 ? x * 12.92310 : 1.055 * exp(log(x) / sRGBGammaCurve) - 0.055;//standard discontinuous
+ //very small differences between the 2
+ return x <= 0.003040 ? x * 12.92310 : 1.055 * exp(log(x) / sRGBGammaCurve) - 0.055;//continuous
+ // return x <= 0.003041 ? x * 12.92310 : 1.055011 * exp(log(x) / sRGBGammaCurve) - 0.055011;//continuous
+
}
/**
* @brief Inverse sRGB gamma
- * See also calcGamma above with the following values: pwr=2.4 ts=12.92 mode=0.003041 imax=0.055011
+ * See also calcGamma above with the following values: pwr=2.3999 ts=12.92310 mode=0.003041 imax=0.055
* @param x red, green or blue channel's value [0 ; 1]
* @return the inverse gamma modified's value [0 ; 1]
*/
static inline double igamma2 (double x) //g2
{
- return x <= 0.039293 ? x / 12.92 : exp(log((x + 0.055011) / 1.055011) * sRGBGammaCurve);
+ // return x <= 0.039289 ? x / 12.92310 : exp(log((x + 0.055) / 1.055) * 2.39990);//calculate with calcgamma
+ // return x <= 0.04045 ? x / 12.92310 : exp(log((x + 0.055) / 1.055) * sRGBGammaCurve);//standard discontinuous
+ //very small differences between the 4
+ return x <= 0.039286 ? x / 12.92310 : exp(log((x + 0.055) / 1.055) * sRGBGammaCurve);//continuous
+ // return x <= 0.039293 ? x / 12.92310 : exp(log((x + 0.055011) / 1.055011) * sRGBGammaCurve);//continuous
+
}
diff --git a/rtengine/curves.h b/rtengine/curves.h
index 635c21da9..98934f13a 100644
--- a/rtengine/curves.h
+++ b/rtengine/curves.h
@@ -267,19 +267,19 @@ public:
// standard srgb gamma and its inverse
static inline double gamma2 (double x)
{
- return x <= 0.00304 ? x * 12.92 : 1.055 * exp(log(x) / sRGBGammaCurve) - 0.055;
+ return x <= 0.00304 ? x * 12.92310 : 1.055 * exp(log(x) / sRGBGammaCurve) - 0.055;
}
static inline double igamma2 (double x)
{
- return x <= 0.03928 ? x / 12.92 : exp(log((x + 0.055) / 1.055) * sRGBGammaCurve);
+ return x <= 0.03928 ? x / 12.92310 : exp(log((x + 0.055) / 1.055) * sRGBGammaCurve);
}
static inline float gamma2 (float x)
{
- return x <= 0.00304 ? x * 12.92 : 1.055 * expf(logf(x) / sRGBGammaCurve) - 0.055;
+ return x <= 0.00304 ? x * 12.92310 : 1.055 * expf(logf(x) / sRGBGammaCurve) - 0.055;
}
static inline float igamma2 (float x)
{
- return x <= 0.03928 ? x / 12.92 : expf(logf((x + 0.055) / 1.055) * sRGBGammaCurve);
+ return x <= 0.03928 ? x / 12.92310 : expf(logf((x + 0.055) / 1.055) * sRGBGammaCurve);
}
// gamma function with adjustable parameters
static inline double gamma (double x, double gamma, double start, double slope, double mul, double add)
diff --git a/rtengine/dcraw.cc b/rtengine/dcraw.cc
index 859aea3a1..0d629b9bc 100644
--- a/rtengine/dcraw.cc
+++ b/rtengine/dcraw.cc
@@ -2896,7 +2896,7 @@ void CLASS lossy_dng_load_raw()
}
order = sorder;
} else {
- gamma_curve (1/2.4, 12.92, 1, 255);
+ gamma_curve (1/2.4, 12.92310, 1, 255);
FORC3 memcpy (cur[c], curve, sizeof cur[0]);
}
cinfo.err = jpeg_std_error (&jerr);
@@ -6608,7 +6608,7 @@ void CLASS apply_tiff()
if (model[0] == 'N') load_flags = 80;
} else if (raw_width*raw_height*3 == tiff_ifd[raw].bytes) {
load_raw = &CLASS nikon_yuv_load_raw;
- gamma_curve (1/2.4, 12.92, 1, 4095);
+ gamma_curve (1/2.4, 12.92310, 1, 4095);
memset (cblack, 0, sizeof cblack);
filters = 0;
} else if (raw_width*raw_height*2 == tiff_ifd[raw].bytes) {
@@ -8920,7 +8920,7 @@ void CLASS identify()
strcpy (model,"One");
parse_redcine();
load_raw = &CLASS redcine_load_raw;
- gamma_curve (1/2.4, 12.92, 1, 4095);
+ gamma_curve (1/2.4, 12.92310, 1, 4095);
filters = 0x49494949;
} else if (!memcmp (head,"DSC-Image",9))
parse_rollei();
diff --git a/rtengine/dcrop.cc b/rtengine/dcrop.cc
index 99aeccbe8..ebcef3ab6 100644
--- a/rtengine/dcrop.cc
+++ b/rtengine/dcrop.cc
@@ -28,9 +28,9 @@ namespace
// "ceil" rounding
template
-constexpr T skips (T a, T b)
+constexpr T skips(T a, T b)
{
- return a / b + static_cast (a % b);
+ return a / b + static_cast(a % b);
}
}
@@ -40,47 +40,47 @@ namespace rtengine
extern const Settings* settings;
-Crop::Crop (ImProcCoordinator* parent, EditDataProvider *editDataProvider, bool isDetailWindow)
- : PipetteBuffer (editDataProvider), origCrop (nullptr), laboCrop (nullptr), labnCrop (nullptr),
+Crop::Crop(ImProcCoordinator* parent, EditDataProvider *editDataProvider, bool isDetailWindow)
+ : PipetteBuffer(editDataProvider), origCrop(nullptr), laboCrop(nullptr), labnCrop(nullptr),
cropImg (nullptr), transCrop (nullptr), cieCrop (nullptr),
- updating (false), newUpdatePending (false), skip (10),
- cropx (0), cropy (0), cropw (-1), croph (-1),
- trafx (0), trafy (0), trafw (-1), trafh (-1),
- rqcropx (0), rqcropy (0), rqcropw (-1), rqcroph (-1),
- borderRequested (32), upperBorder (0), leftBorder (0),
- cropAllocated (false),
- cropImageListener (nullptr), parent (parent), isDetailWindow (isDetailWindow)
+ updating(false), newUpdatePending(false), skip(10),
+ cropx(0), cropy(0), cropw(-1), croph(-1),
+ trafx(0), trafy(0), trafw(-1), trafh(-1),
+ rqcropx(0), rqcropy(0), rqcropw(-1), rqcroph(-1),
+ borderRequested(32), upperBorder(0), leftBorder(0),
+ cropAllocated(false),
+ cropImageListener(nullptr), parent(parent), isDetailWindow(isDetailWindow)
{
- parent->crops.push_back (this);
+ parent->crops.push_back(this);
}
-Crop::~Crop ()
+Crop::~Crop()
{
- MyMutex::MyLock cropLock (cropMutex);
+ MyMutex::MyLock cropLock(cropMutex);
- std::vector::iterator i = std::find (parent->crops.begin(), parent->crops.end(), this);
+ std::vector::iterator i = std::find(parent->crops.begin(), parent->crops.end(), this);
- if (i != parent->crops.end ()) {
- parent->crops.erase (i);
+ if (i != parent->crops.end()) {
+ parent->crops.erase(i);
}
- MyMutex::MyLock processingLock (parent->mProcessing);
- freeAll ();
-}
-
-void Crop::destroy ()
-{
- MyMutex::MyLock lock (cropMutex);
- MyMutex::MyLock processingLock (parent->mProcessing);
+ MyMutex::MyLock processingLock(parent->mProcessing);
freeAll();
}
-void Crop::setListener (DetailedCropListener* il)
+void Crop::destroy()
+{
+ MyMutex::MyLock lock(cropMutex);
+ MyMutex::MyLock processingLock(parent->mProcessing);
+ freeAll();
+}
+
+void Crop::setListener(DetailedCropListener* il)
{
// We can make reads in the IF, because the mProcessing lock is only needed for change
if (cropImageListener != il) {
- MyMutex::MyLock lock (cropMutex);
+ MyMutex::MyLock lock(cropMutex);
cropImageListener = il;
}
}
@@ -95,9 +95,9 @@ EditUniqueID Crop::getCurrEditID()
* Delete the edit image buffer if there's no subscriber anymore.
* If allocation has to be done, it is deferred to Crop::update
*/
-void Crop::setEditSubscriber (EditSubscriber* newSubscriber)
+void Crop::setEditSubscriber(EditSubscriber* newSubscriber)
{
- MyMutex::MyLock lock (cropMutex);
+ MyMutex::MyLock lock(cropMutex);
// At this point, editCrop.dataProvider->currSubscriber is the old subscriber
EditSubscriber *oldSubscriber = PipetteBuffer::dataProvider ? PipetteBuffer::dataProvider->getCurrSubscriber() : nullptr;
@@ -123,13 +123,13 @@ void Crop::setEditSubscriber (EditSubscriber* newSubscriber)
bool Crop::hasListener()
{
- MyMutex::MyLock cropLock (cropMutex);
+ MyMutex::MyLock cropLock(cropMutex);
return cropImageListener;
}
-void Crop::update (int todo)
+void Crop::update(int todo)
{
- MyMutex::MyLock cropLock (cropMutex);
+ MyMutex::MyLock cropLock(cropMutex);
ProcParams& params = parent->params;
// CropGUIListener* cropgl;
@@ -142,16 +142,16 @@ void Crop::update (int todo)
bool overrideWindow = false;
if (cropImageListener) {
- overrideWindow = cropImageListener->getWindow (wx, wy, ww, wh, ws);
+ overrideWindow = cropImageListener->getWindow(wx, wy, ww, wh, ws);
}
// re-allocate sub-images and arrays if their dimensions changed
bool needsinitupdate = false;
if (!overrideWindow) {
- needsinitupdate = setCropSizes (rqcropx, rqcropy, rqcropw, rqcroph, skip, true);
+ needsinitupdate = setCropSizes(rqcropx, rqcropy, rqcropw, rqcroph, skip, true);
} else {
- needsinitupdate = setCropSizes (wx, wy, ww, wh, ws, true); // this set skip=ws
+ needsinitupdate = setCropSizes(wx, wy, ww, wh, ws, true); // this set skip=ws
}
// it something has been reallocated, all processing steps have to be performed
@@ -160,7 +160,7 @@ void Crop::update (int todo)
}
// Tells to the ImProcFunctions' tool what is the preview scale, which may lead to some simplifications
- parent->ipf.setScale (skip);
+ parent->ipf.setScale(skip);
Imagefloat* baseCrop = origCrop;
int widIm = parent->fw;//full image
@@ -169,12 +169,12 @@ void Crop::update (int todo)
bool needstransform = parent->ipf.needsTransform();
if (todo & (M_INIT | M_LINDENOISE | M_HDR)) {
- MyMutex::MyLock lock (parent->minit); // Also used in improccoord
+ MyMutex::MyLock lock(parent->minit); // Also used in improccoord
- int tr = getCoarseBitMask (params.coarse);
+ int tr = getCoarseBitMask(params.coarse);
if (!needsinitupdate) {
- setCropSizes (rqcropx, rqcropy, rqcropw, rqcroph, skip, true);
+ setCropSizes(rqcropx, rqcropy, rqcropw, rqcroph, skip, true);
}
// printf("x=%d y=%d crow=%d croh=%d skip=%d\n",rqcropx, rqcropy, rqcropw, rqcroph, skip);
@@ -186,7 +186,7 @@ void Crop::update (int todo)
float autoNR = (float) settings->nrauto;//
float autoNRmax = (float) settings->nrautomax;//
- params.dirpyrDenoise.getCurves (noiseLCurve, noiseCCurve);
+ params.dirpyrDenoise.getCurves(noiseLCurve, noiseCCurve);
int tilesize;
int overlap;
@@ -204,7 +204,7 @@ void Crop::update (int todo)
int numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip;
int kall = 2;
- parent->ipf.Tile_calc (tilesize, overlap, kall, widIm, heiIm, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
+ parent->ipf.Tile_calc(tilesize, overlap, kall, widIm, heiIm, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
kall = 0;
float *min_b = new float [9];
@@ -226,20 +226,20 @@ void Crop::update (int todo)
}
if (settings->leveldnautsimpl == 1) {
- if (params.dirpyrDenoise.Cmethod == "MAN" || params.dirpyrDenoise.Cmethod == "PON" ) {
- PreviewProps pp (trafx, trafy, trafw * skip, trafh * skip, skip);
- parent->imgsrc->getImage (parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw );
+ if (params.dirpyrDenoise.Cmethod == "MAN" || params.dirpyrDenoise.Cmethod == "PON") {
+ PreviewProps pp(trafx, trafy, trafw * skip, trafh * skip, skip);
+ parent->imgsrc->getImage(parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw);
}
} else {
if (params.dirpyrDenoise.C2method == "MANU") {
- PreviewProps pp (trafx, trafy, trafw * skip, trafh * skip, skip);
- parent->imgsrc->getImage (parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw );
+ PreviewProps pp(trafx, trafy, trafw * skip, trafh * skip, skip);
+ parent->imgsrc->getImage(parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw);
}
}
if ((settings->leveldnautsimpl == 1 && params.dirpyrDenoise.Cmethod == "PRE") || (settings->leveldnautsimpl == 0 && params.dirpyrDenoise.C2method == "PREV")) {
- PreviewProps pp (trafx, trafy, trafw * skip, trafh * skip, skip);
- parent->imgsrc->getImage (parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw );
+ PreviewProps pp(trafx, trafy, trafw * skip, trafh * skip, skip);
+ parent->imgsrc->getImage(parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw);
if ((!isDetailWindow) && parent->adnListener && skip == 1 && params.dirpyrDenoise.enabled) {
float lowdenoise = 1.f;
@@ -257,15 +257,15 @@ void Crop::update (int todo)
int poscenterY = 0;
for (int cc = 0; cc < numtiles_W; cc++) {
- if (abs (centerTile_X[cc] - CenterPreview_X) < minimuX) {
- minimuX = abs (centerTile_X[cc] - CenterPreview_X);
+ if (abs(centerTile_X[cc] - CenterPreview_X) < minimuX) {
+ minimuX = abs(centerTile_X[cc] - CenterPreview_X);
poscenterX = cc;
}
}
for (int cc = 0; cc < numtiles_H; cc++) {
- if (abs (centerTile_Y[cc] - CenterPreview_Y) < minimuY) {
- minimuY = abs (centerTile_Y[cc] - CenterPreview_Y);
+ if (abs(centerTile_Y[cc] - CenterPreview_Y) < minimuY) {
+ minimuY = abs(centerTile_Y[cc] - CenterPreview_Y);
poscenterY = cc;
}
}
@@ -292,24 +292,24 @@ void Crop::update (int todo)
float adjustr = 1.f;
- if (params.icm.working == "ProPhoto") {
+ if (params.icm.workingProfile == "ProPhoto") {
adjustr = 1.f;
- } else if (params.icm.working == "Adobe RGB") {
+ } else if (params.icm.workingProfile == "Adobe RGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "sRGB") {
+ } else if (params.icm.workingProfile == "sRGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "WideGamut") {
+ } else if (params.icm.workingProfile == "WideGamut") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Beta RGB") {
+ } else if (params.icm.workingProfile == "Beta RGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BestRGB") {
+ } else if (params.icm.workingProfile == "BestRGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BruceRGB") {
+ } else if (params.icm.workingProfile == "BruceRGB") {
adjustr = 1.f / 1.2f;
}
if (parent->adnListener) {
- parent->adnListener->noiseTilePrev (centerTile_X[poscenterX], centerTile_Y[poscenterY], CenterPreview_X, CenterPreview_Y, crW, trafw * skip);
+ parent->adnListener->noiseTilePrev(centerTile_X[poscenterX], centerTile_Y[poscenterY], CenterPreview_X, CenterPreview_Y, crW, trafw * skip);
}
// I have tried "blind" some solutions..to move review ...but GUI is not my truc !
@@ -323,17 +323,17 @@ void Crop::update (int todo)
// we only need image reduced to 1/4 here
int W = origCrop->getWidth();
int H = origCrop->getHeight();
- Imagefloat *provicalc = new Imagefloat ((W + 1) / 2, (H + 1) / 2); //for denoise curves
+ Imagefloat *provicalc = new Imagefloat((W + 1) / 2, (H + 1) / 2); //for denoise curves
for (int ii = 0; ii < H; ii += 2) {
for (int jj = 0; jj < W; jj += 2) {
- provicalc->r (ii >> 1, jj >> 1) = origCrop->r (ii, jj);
- provicalc->g (ii >> 1, jj >> 1) = origCrop->g (ii, jj);
- provicalc->b (ii >> 1, jj >> 1) = origCrop->b (ii, jj);
+ provicalc->r(ii >> 1, jj >> 1) = origCrop->r(ii, jj);
+ provicalc->g(ii >> 1, jj >> 1) = origCrop->g(ii, jj);
+ provicalc->b(ii >> 1, jj >> 1) = origCrop->b(ii, jj);
}
}
- parent->imgsrc->convertColorSpace (provicalc, params.icm, parent->currWB); //for denoise luminance curve
+ parent->imgsrc->convertColorSpace(provicalc, params.icm, parent->currWB); //for denoise luminance curve
float maxr = 0.f;
float maxb = 0.f;
@@ -347,10 +347,10 @@ void Crop::update (int todo)
maxblueaut = 0.f;
minredaut = 0.f;
minblueaut = 0.f;
- LUTf gamcurve (65536, 0);
+ LUTf gamcurve(65536, 0);
float gam, gamthresh, gamslope;
- parent->ipf.RGB_denoise_infoGamCurve (params.dirpyrDenoise, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope);
- parent->ipf.RGB_denoise_info (origCrop, provicalc, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope, params.dirpyrDenoise, parent->imgsrc->getDirPyrDenoiseExpComp(), chaut, Nb, redaut, blueaut, maxredaut, maxblueaut, minredaut, minblueaut, chromina, sigma, lumema, sigma_L, redyel, skinc, nsknc, true);
+ parent->ipf.RGB_denoise_infoGamCurve(params.dirpyrDenoise, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope);
+ parent->ipf.RGB_denoise_info(origCrop, provicalc, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope, params.dirpyrDenoise, parent->imgsrc->getDirPyrDenoiseExpComp(), chaut, Nb, redaut, blueaut, maxredaut, maxblueaut, minredaut, minblueaut, chromina, sigma, lumema, sigma_L, redyel, skinc, nsknc, true);
// printf("redy=%f skin=%f pcskin=%f\n",redyel, skinc,nsknc);
// printf("DCROP skip=%d cha=%4.0f Nb=%d red=%4.0f bl=%4.0f redM=%4.0f bluM=%4.0f L=%4.0f sigL=%4.0f Ch=%4.0f Si=%4.0f\n",skip, chaut,Nb, redaut,blueaut, maxredaut, maxblueaut, lumema, sigma_L, chromina, sigma);
float multip = 1.f;
@@ -359,12 +359,12 @@ void Crop::update (int todo)
multip = 2.f; //take into account gamma for TIF / JPG approximate value...not good for gamma=1
}
- float maxmax = max (maxredaut, maxblueaut);
+ float maxmax = max(maxredaut, maxblueaut);
float delta;
int mode = 0;
// float redyel, skinc, nsknc;
int lissage = settings->leveldnliss;
- parent->ipf.calcautodn_info (chaut, delta, Nb, levaut, maxmax, lumema, chromina, mode, lissage, redyel, skinc, nsknc);
+ parent->ipf.calcautodn_info(chaut, delta, Nb, levaut, maxmax, lumema, chromina, mode, lissage, redyel, skinc, nsknc);
if (maxredaut > maxblueaut) {
@@ -387,7 +387,7 @@ void Crop::update (int todo)
params.dirpyrDenoise.chroma = chaut / (autoNR * multip * adjustr * lowdenoise);
params.dirpyrDenoise.redchro = maxr;
params.dirpyrDenoise.bluechro = maxb;
- parent->adnListener->chromaChanged (params.dirpyrDenoise.chroma, params.dirpyrDenoise.redchro, params.dirpyrDenoise.bluechro);
+ parent->adnListener->chromaChanged(params.dirpyrDenoise.chroma, params.dirpyrDenoise.redchro, params.dirpyrDenoise.bluechro);
delete provicalc;
}
@@ -423,16 +423,16 @@ void Crop::update (int todo)
lowdenoise = 0.7f;
}
- LUTf gamcurve (65536, 0);
+ LUTf gamcurve(65536, 0);
float gam, gamthresh, gamslope;
- parent->ipf.RGB_denoise_infoGamCurve (params.dirpyrDenoise, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope);
+ parent->ipf.RGB_denoise_infoGamCurve(params.dirpyrDenoise, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope);
int Nb[9];
#ifdef _OPENMP
#pragma omp parallel
#endif
{
- Imagefloat *origCropPart = new Imagefloat (crW, crH);//allocate memory
- Imagefloat *provicalc = new Imagefloat ((crW + 1) / 2, (crH + 1) / 2); //for denoise curves
+ Imagefloat *origCropPart = new Imagefloat(crW, crH); //allocate memory
+ Imagefloat *provicalc = new Imagefloat((crW + 1) / 2, (crH + 1) / 2); //for denoise curves
int coordW[3];//coordinate of part of image to measure noise
int coordH[3];
@@ -450,24 +450,24 @@ void Crop::update (int todo)
for (int wcr = 0; wcr <= 2; wcr++) {
for (int hcr = 0; hcr <= 2; hcr++) {
- PreviewProps ppP (coordW[wcr], coordH[hcr], crW, crH, 1);
- parent->imgsrc->getImage (parent->currWB, tr, origCropPart, ppP, params.toneCurve, params.raw );
+ PreviewProps ppP(coordW[wcr], coordH[hcr], crW, crH, 1);
+ parent->imgsrc->getImage(parent->currWB, tr, origCropPart, ppP, params.toneCurve, params.raw);
// we only need image reduced to 1/4 here
for (int ii = 0; ii < crH; ii += 2) {
for (int jj = 0; jj < crW; jj += 2) {
- provicalc->r (ii >> 1, jj >> 1) = origCropPart->r (ii, jj);
- provicalc->g (ii >> 1, jj >> 1) = origCropPart->g (ii, jj);
- provicalc->b (ii >> 1, jj >> 1) = origCropPart->b (ii, jj);
+ provicalc->r(ii >> 1, jj >> 1) = origCropPart->r(ii, jj);
+ provicalc->g(ii >> 1, jj >> 1) = origCropPart->g(ii, jj);
+ provicalc->b(ii >> 1, jj >> 1) = origCropPart->b(ii, jj);
}
}
- parent->imgsrc->convertColorSpace (provicalc, params.icm, parent->currWB); //for denoise luminance curve
+ parent->imgsrc->convertColorSpace(provicalc, params.icm, parent->currWB); //for denoise luminance curve
float pondcorrec = 1.0f;
float chaut = 0.f, redaut = 0.f, blueaut = 0.f, maxredaut = 0.f, maxblueaut = 0.f, minredaut = 0.f, minblueaut = 0.f, chromina = 0.f, sigma = 0.f, lumema = 0.f, sigma_L = 0.f, redyel = 0.f, skinc = 0.f, nsknc = 0.f;
int nb = 0;
- parent->ipf.RGB_denoise_info (origCropPart, provicalc, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope, params.dirpyrDenoise, parent->imgsrc->getDirPyrDenoiseExpComp(), chaut, nb, redaut, blueaut, maxredaut, maxblueaut, minredaut, minblueaut, chromina, sigma, lumema, sigma_L, redyel, skinc, nsknc);
+ parent->ipf.RGB_denoise_info(origCropPart, provicalc, parent->imgsrc->isRAW(), gamcurve, gam, gamthresh, gamslope, params.dirpyrDenoise, parent->imgsrc->getDirPyrDenoiseExpComp(), chaut, nb, redaut, blueaut, maxredaut, maxblueaut, minredaut, minblueaut, chromina, sigma, lumema, sigma_L, redyel, skinc, nsknc);
//printf("DCROP skip=%d cha=%f red=%f bl=%f redM=%f bluM=%f chrom=%f sigm=%f lum=%f\n",skip, chaut,redaut,blueaut, maxredaut, maxblueaut, chromina, sigma, lumema);
Nb[hcr * 3 + wcr] = nb;
@@ -512,19 +512,19 @@ void Crop::update (int todo)
float adjustr = 1.f;
- if (params.icm.working == "ProPhoto") {
+ if (params.icm.workingProfile == "ProPhoto") {
adjustr = 1.f; //
- } else if (params.icm.working == "Adobe RGB") {
+ } else if (params.icm.workingProfile == "Adobe RGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "sRGB") {
+ } else if (params.icm.workingProfile == "sRGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "WideGamut") {
+ } else if (params.icm.workingProfile == "WideGamut") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Beta RGB") {
+ } else if (params.icm.workingProfile == "Beta RGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BestRGB") {
+ } else if (params.icm.workingProfile == "BestRGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BruceRGB") {
+ } else if (params.icm.workingProfile == "BruceRGB") {
adjustr = 1.f / 1.2f;
}
@@ -533,8 +533,8 @@ void Crop::update (int todo)
int lissage = settings->leveldnliss;
for (int k = 0; k < 9; k++) {
- float maxmax = max (parent->denoiseInfoStore.max_r[k], parent->denoiseInfoStore.max_b[k]);
- parent->ipf.calcautodn_info (parent->denoiseInfoStore.ch_M[k], delta[k], Nb[k], levaut, maxmax, lumL[k], chromC[k], mode, lissage, ry[k], sk[k], pcsk[k]);
+ float maxmax = max(parent->denoiseInfoStore.max_r[k], parent->denoiseInfoStore.max_b[k]);
+ parent->ipf.calcautodn_info(parent->denoiseInfoStore.ch_M[k], delta[k], Nb[k], levaut, maxmax, lumL[k], chromC[k], mode, lissage, ry[k], sk[k], pcsk[k]);
// printf("ch_M=%f delta=%f\n",ch_M[k], delta[k]);
}
@@ -599,12 +599,12 @@ void Crop::update (int todo)
parent->denoiseInfoStore.valid = true;
if (parent->adnListener) {
- parent->adnListener->chromaChanged (params.dirpyrDenoise.chroma, params.dirpyrDenoise.redchro, params.dirpyrDenoise.bluechro);
+ parent->adnListener->chromaChanged(params.dirpyrDenoise.chroma, params.dirpyrDenoise.redchro, params.dirpyrDenoise.bluechro);
}
if (settings->verbose) {
t2aue.set();
- printf ("Info denoise auto performed in %d usec:\n", t2aue.etime (t1aue));
+ printf("Info denoise auto performed in %d usec:\n", t2aue.etime(t1aue));
}
//end evaluate noise
@@ -612,8 +612,8 @@ void Crop::update (int todo)
// if(params.dirpyrDenoise.Cmethod=="AUT" || params.dirpyrDenoise.Cmethod=="PON") {//reinit origCrop after Auto
if ((settings->leveldnautsimpl == 1 && params.dirpyrDenoise.Cmethod == "AUT") || (settings->leveldnautsimpl == 0 && params.dirpyrDenoise.C2method == "AUTO")) { //reinit origCrop after Auto
- PreviewProps pp (trafx, trafy, trafw * skip, trafh * skip, skip);
- parent->imgsrc->getImage (parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw );
+ PreviewProps pp(trafx, trafy, trafw * skip, trafh * skip, skip);
+ parent->imgsrc->getImage(parent->currWB, tr, origCrop, pp, params.toneCurve, params.raw);
}
DirPyrDenoiseParams denoiseParams = params.dirpyrDenoise;
@@ -628,25 +628,25 @@ void Crop::update (int todo)
noiseLCurve.Reset();
}
- if ((noiseLCurve || noiseCCurve ) && skip == 1 && denoiseParams.enabled) { //only allocate memory if enabled and skip
+ if ((noiseLCurve || noiseCCurve) && skip == 1 && denoiseParams.enabled) { //only allocate memory if enabled and skip
// we only need image reduced to 1/4 here
int W = origCrop->getWidth();
int H = origCrop->getHeight();
- calclum = new Imagefloat ((W + 1) / 2, (H + 1) / 2); //for denoise curves
+ calclum = new Imagefloat((W + 1) / 2, (H + 1) / 2); //for denoise curves
for (int ii = 0; ii < H; ii += 2) {
for (int jj = 0; jj < W; jj += 2) {
- calclum->r (ii >> 1, jj >> 1) = origCrop->r (ii, jj);
- calclum->g (ii >> 1, jj >> 1) = origCrop->g (ii, jj);
- calclum->b (ii >> 1, jj >> 1) = origCrop->b (ii, jj);
+ calclum->r(ii >> 1, jj >> 1) = origCrop->r(ii, jj);
+ calclum->g(ii >> 1, jj >> 1) = origCrop->g(ii, jj);
+ calclum->b(ii >> 1, jj >> 1) = origCrop->b(ii, jj);
}
}
- parent->imgsrc->convertColorSpace (calclum, params.icm, parent->currWB); //for denoise luminance curve
+ parent->imgsrc->convertColorSpace(calclum, params.icm, parent->currWB); //for denoise luminance curve
}
if (skip != 1) if (parent->adnListener) {
- parent->adnListener->noiseChanged (0.f, 0.f);
+ parent->adnListener->noiseChanged(0.f, 0.f);
}
if (todo & M_LINDENOISE) {
@@ -654,26 +654,26 @@ void Crop::update (int todo)
int kall = 0;
float nresi, highresi;
- parent->ipf.RGB_denoise (kall, origCrop, origCrop, calclum, parent->denoiseInfoStore.ch_M, parent->denoiseInfoStore.max_r, parent->denoiseInfoStore.max_b, parent->imgsrc->isRAW(), /*Roffset,*/ denoiseParams, parent->imgsrc->getDirPyrDenoiseExpComp(), noiseLCurve, noiseCCurve, nresi, highresi);
+ parent->ipf.RGB_denoise(kall, origCrop, origCrop, calclum, parent->denoiseInfoStore.ch_M, parent->denoiseInfoStore.max_r, parent->denoiseInfoStore.max_b, parent->imgsrc->isRAW(), /*Roffset,*/ denoiseParams, parent->imgsrc->getDirPyrDenoiseExpComp(), noiseLCurve, noiseCCurve, nresi, highresi);
if (parent->adnListener) {
- parent->adnListener->noiseChanged (nresi, highresi);
+ parent->adnListener->noiseChanged(nresi, highresi);
}
if (settings->leveldnautsimpl == 1) {
if ((denoiseParams.Cmethod == "AUT" || denoiseParams.Cmethod == "PRE") && (parent->adnListener)) { // force display value of sliders
- parent->adnListener->chromaChanged (denoiseParams.chroma, denoiseParams.redchro, denoiseParams.bluechro);
+ parent->adnListener->chromaChanged(denoiseParams.chroma, denoiseParams.redchro, denoiseParams.bluechro);
}
} else {
if ((denoiseParams.C2method == "AUTO" || denoiseParams.C2method == "PREV") && (parent->adnListener)) { // force display value of sliders
- parent->adnListener->chromaChanged (denoiseParams.chroma, denoiseParams.redchro, denoiseParams.bluechro);
+ parent->adnListener->chromaChanged(denoiseParams.chroma, denoiseParams.redchro, denoiseParams.bluechro);
}
}
}
}
- parent->imgsrc->convertColorSpace (origCrop, params.icm, parent->currWB);
+ parent->imgsrc->convertColorSpace(origCrop, params.icm, parent->currWB);
delete [] min_r;
delete [] min_b;
@@ -688,9 +688,10 @@ void Crop::update (int todo)
}
// has to be called after setCropSizes! Tools prior to this point can't handle the Edit mechanism, but that shouldn't be a problem.
- createBuffer (cropw, croph);
+ createBuffer(cropw, croph);
std::unique_ptr fattalCrop;
+
if ((todo & M_HDR) && params.fattal.enabled) {
Imagefloat *f = origCrop;
int fw = skips(parent->fw, skip);
@@ -700,6 +701,7 @@ void Crop::update (int todo)
if (trafx || trafy || trafw != fw || trafh != fh) {
need_cropping = true;
+
// fattal needs to work on the full image. So here we get the full
// image from imgsrc, and replace the denoised crop in case
if (!params.dirpyrDenoise.enabled && skip == 1 && parent->fattal_11_dcrop_cache) {
@@ -708,7 +710,7 @@ void Crop::update (int todo)
} else {
f = new Imagefloat(fw, fh);
fattalCrop.reset(f);
- PreviewProps pp (0, 0, parent->fw, parent->fh, skip);
+ PreviewProps pp(0, 0, parent->fw, parent->fh, skip);
int tr = getCoarseBitMask(params.coarse);
parent->imgsrc->getImage(parent->currWB, tr, f, pp, params.toneCurve, params.raw);
parent->imgsrc->convertColorSpace(f, params.icm, parent->currWB);
@@ -720,8 +722,10 @@ void Crop::update (int todo)
#ifdef _OPENMP
#pragma omp parallel for
#endif
+
for (int y = 0; y < baseCrop->getHeight(); ++y) {
int dy = oy + y;
+
for (int x = 0; x < baseCrop->getWidth(); ++x) {
int dx = ox + x;
f->r(dy, dx) = baseCrop->r(y, x);
@@ -735,6 +739,7 @@ void Crop::update (int todo)
}
}
}
+
if (need_fattal) {
parent->ipf.ToneMapFattal02(f);
}
@@ -748,8 +753,10 @@ void Crop::update (int todo)
#ifdef _OPENMP
#pragma omp parallel for
#endif
+
for (int y = 0; y < trafh; ++y) {
int cy = y + oy;
+
for (int x = 0; x < trafw; ++x) {
int cx = x + ox;
c->r(y, x) = f->r(cy, cx);
@@ -757,24 +764,25 @@ void Crop::update (int todo)
c->b(y, x) = f->b(cy, cx);
}
}
+
baseCrop = c;
} else {
baseCrop = f;
}
}
-
+
// transform
if (needstransform || ((todo & (M_TRANSFORM | M_RGBCURVE)) && params.dirpyrequalizer.cbdlMethod == "bef" && params.dirpyrequalizer.enabled && !params.colorappearance.enabled)) {
if (!transCrop) {
- transCrop = new Imagefloat (cropw, croph);
+ transCrop = new Imagefloat(cropw, croph);
}
if (needstransform)
- parent->ipf.transform (baseCrop, transCrop, cropx / skip, cropy / skip, trafx / skip, trafy / skip, skips (parent->fw, skip), skips (parent->fh, skip), parent->getFullWidth(), parent->getFullHeight(),
- parent->imgsrc->getMetaData(),
- parent->imgsrc->getRotateDegree(), false);
+ parent->ipf.transform(baseCrop, transCrop, cropx / skip, cropy / skip, trafx / skip, trafy / skip, skips(parent->fw, skip), skips(parent->fh, skip), parent->getFullWidth(), parent->getFullHeight(),
+ parent->imgsrc->getMetaData(),
+ parent->imgsrc->getRotateDegree(), false);
else {
- baseCrop->copyData (transCrop);
+ baseCrop->copyData(transCrop);
}
if (transCrop) {
@@ -792,23 +800,66 @@ void Crop::update (int todo)
const int W = baseCrop->getWidth();
const int H = baseCrop->getHeight();
- LabImage labcbdl (W, H);
- parent->ipf.rgb2lab (*baseCrop, labcbdl, params.icm.working);
- parent->ipf.dirpyrequalizer (&labcbdl, skip);
- parent->ipf.lab2rgb (labcbdl, *baseCrop, params.icm.working);
+ LabImage labcbdl(W, H);
+ parent->ipf.rgb2lab(*baseCrop, labcbdl, params.icm.workingProfile);
+ parent->ipf.dirpyrequalizer(&labcbdl, skip);
+ parent->ipf.lab2rgb(labcbdl, *baseCrop, params.icm.workingProfile);
}
+ if (todo & M_INIT) {
+ if (params.icm.workingTRC == "Custom") { //exec TRC IN free
+ Glib::ustring profile;
+ profile = params.icm.workingProfile;
+
+ if (profile == "sRGB" || profile == "Adobe RGB" || profile == "ProPhoto" || profile == "WideGamut" || profile == "BruceRGB" || profile == "Beta RGB" || profile == "BestRGB" || profile == "Rec2020" || profile == "ACESp0" || profile == "ACESp1") {
+
+ //first put gamma TRC to 1
+ int cw = baseCrop->getWidth();
+ int ch = baseCrop->getHeight();
+ Imagefloat* readyImg0 = NULL;
+
+ readyImg0 = parent->ipf.workingtrc(baseCrop, cw, ch, -5, params.icm.workingProfile, 2.4, 12.92310);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ baseCrop->r(row, col) = (float)readyImg0->r(row, col);
+ baseCrop->g(row, col) = (float)readyImg0->g(row, col);
+ baseCrop->b(row, col) = (float)readyImg0->b(row, col);
+ }
+ }
+
+ delete readyImg0;
+
+ //adjust gamma TRC
+ Imagefloat* readyImg = NULL;
+ readyImg = parent->ipf.workingtrc(baseCrop, cw, ch, 5, params.icm.workingProfile, params.icm.workingTRCGamma, params.icm.workingTRCSlope);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ baseCrop->r(row, col) = (float)readyImg->r(row, col);
+ baseCrop->g(row, col) = (float)readyImg->g(row, col);
+ baseCrop->b(row, col) = (float)readyImg->b(row, col);
+ }
+ }
+
+ delete readyImg;
+ }
+ }
+ }
+
if (todo & M_RGBCURVE) {
double rrm, ggm, bbm;
DCPProfile::ApplyState as;
- DCPProfile *dcpProf = parent->imgsrc->getDCP (params.icm, as);
+ DCPProfile *dcpProf = parent->imgsrc->getDCP(params.icm, as);
LUTu histToneCurve;
parent->ipf.rgbProc (baseCrop, laboCrop, this, parent->hltonecurve, parent->shtonecurve, parent->tonecurve,
- params.toneCurve.saturation, parent->rCurve, parent->gCurve, parent->bCurve, parent->colourToningSatLimit, parent->colourToningSatLimitOpacity, parent->ctColorCurve, parent->ctOpacityCurve, parent->opautili, parent->clToningcurve, parent->cl2Toningcurve,
- parent->customToneCurve1, parent->customToneCurve2, parent->beforeToneCurveBW, parent->afterToneCurveBW, rrm, ggm, bbm,
- parent->bwAutoR, parent->bwAutoG, parent->bwAutoB, dcpProf, as, histToneCurve);
+ params.toneCurve.saturation, parent->rCurve, parent->gCurve, parent->bCurve, parent->colourToningSatLimit, parent->colourToningSatLimitOpacity, parent->ctColorCurve, parent->ctOpacityCurve, parent->opautili, parent->clToningcurve, parent->cl2Toningcurve,
+ parent->customToneCurve1, parent->customToneCurve2, parent->beforeToneCurveBW, parent->afterToneCurveBW, rrm, ggm, bbm,
+ parent->bwAutoR, parent->bwAutoG, parent->bwAutoB, dcpProf, as, histToneCurve);
}
/*xref=000;yref=000;
@@ -830,7 +881,7 @@ void Crop::update (int todo)
// apply luminance operations
if (todo & (M_LUMINANCE + M_COLOR)) {
//I made a little change here. Rather than have luminanceCurve (and others) use in/out lab images, we can do more if we copy right here.
- labnCrop->CopyFrom (laboCrop);
+ labnCrop->CopyFrom(laboCrop);
//parent->ipf.luminanceCurve (labnCrop, labnCrop, parent->lumacurve);
@@ -843,25 +894,25 @@ void Crop::update (int todo)
LUTu dummy;
// parent->ipf.MSR(labnCrop, labnCrop->W, labnCrop->H, 1);
- parent->ipf.chromiLuminanceCurve (this, 1, labnCrop, labnCrop, parent->chroma_acurve, parent->chroma_bcurve, parent->satcurve, parent->lhskcurve, parent->clcurve, parent->lumacurve, utili, autili, butili, ccutili, cclutili, clcutili, dummy, dummy);
- parent->ipf.vibrance (labnCrop);
+ parent->ipf.chromiLuminanceCurve(this, 1, labnCrop, labnCrop, parent->chroma_acurve, parent->chroma_bcurve, parent->satcurve, parent->lhskcurve, parent->clcurve, parent->lumacurve, utili, autili, butili, ccutili, cclutili, clcutili, dummy, dummy);
+ parent->ipf.vibrance(labnCrop);
- if ((params.colorappearance.enabled && !params.colorappearance.tonecie) || (!params.colorappearance.enabled)) {
- parent->ipf.EPDToneMap (labnCrop, 5, skip);
+ if ((params.colorappearance.enabled && !params.colorappearance.tonecie) || (!params.colorappearance.enabled)) {
+ parent->ipf.EPDToneMap(labnCrop, 5, skip);
}
//parent->ipf.EPDToneMap(labnCrop, 5, 1); //Go with much fewer than normal iterates for fast redisplay.
// for all treatments Defringe, Sharpening, Contrast detail , Microcontrast they are activated if "CIECAM" function are disabled
if (skip == 1) {
if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) {
- parent->ipf.impulsedenoise (labnCrop);
+ parent->ipf.impulsedenoise(labnCrop);
}
- if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled) ) {
- parent->ipf.defringe (labnCrop);
+ if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) {
+ parent->ipf.defringe(labnCrop);
}
- parent->ipf.MLsharpen (labnCrop);
+ parent->ipf.MLsharpen(labnCrop);
if ((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) {
parent->ipf.MLmicrocontrast (labnCrop);
@@ -874,13 +925,13 @@ void Crop::update (int todo)
if (params.dirpyrequalizer.cbdlMethod == "aft") {
if (((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled))) {
- parent->ipf.dirpyrequalizer (labnCrop, skip);
+ parent->ipf.dirpyrequalizer(labnCrop, skip);
// parent->ipf.Lanczoslab (labnCrop,labnCrop , 1.f/skip);
}
}
int kall = 0;
- int minwin = min (labnCrop->W, labnCrop->H);
+ int minwin = min(labnCrop->W, labnCrop->H);
int maxlevelcrop = 10;
// if(cp.mul[9]!=0)maxlevelcrop=10;
@@ -920,10 +971,10 @@ void Crop::update (int todo)
int numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip;
- parent->ipf.Tile_calc (tilesize, overlap, kall, labnCrop->W, labnCrop->H, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
+ parent->ipf.Tile_calc(tilesize, overlap, kall, labnCrop->W, labnCrop->H, numtiles_W, numtiles_H, tilewidth, tileheight, tileWskip, tileHskip);
//now we have tile dimensions, overlaps
//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- int minsizetile = min (tilewidth, tileheight);
+ int minsizetile = min(tilewidth, tileheight);
int maxlev2 = 10;
if (minsizetile < 1024 && maxlevelcrop == 10) {
@@ -942,10 +993,10 @@ void Crop::update (int todo)
maxlev2 = 6;
}
- int maxL = min (maxlev2, maxlevelcrop);
+ int maxL = min(maxlev2, maxlevelcrop);
if (parent->awavListener) {
- parent->awavListener->wavChanged (float (maxL));
+ parent->awavListener->wavChanged(float (maxL));
}
if ((params.wavelet.enabled)) {
@@ -957,28 +1008,28 @@ void Crop::update (int todo)
LUTf wavclCurve;
LUTu dummy;
- params.wavelet.getCurves (wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL);
+ params.wavelet.getCurves(wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL);
- parent->ipf.ip_wavelet (labnCrop, labnCrop, kall, WaveParams, wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL, parent->wavclCurve, skip);
+ parent->ipf.ip_wavelet(labnCrop, labnCrop, kall, WaveParams, wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL, parent->wavclCurve, skip);
}
// }
// }
if (params.colorappearance.enabled) {
- float fnum = parent->imgsrc->getMetaData()->getFNumber (); // F number
- float fiso = parent->imgsrc->getMetaData()->getISOSpeed () ; // ISO
- float fspeed = parent->imgsrc->getMetaData()->getShutterSpeed () ; // Speed
- double fcomp = parent->imgsrc->getMetaData()->getExpComp (); // Compensation +/-
+ float fnum = parent->imgsrc->getMetaData()->getFNumber(); // F number
+ float fiso = parent->imgsrc->getMetaData()->getISOSpeed() ; // ISO
+ float fspeed = parent->imgsrc->getMetaData()->getShutterSpeed() ; // Speed
+ double fcomp = parent->imgsrc->getMetaData()->getExpComp(); // Compensation +/-
double adap; // Scene's luminosity adaptation factor
if (fnum < 0.3f || fiso < 5.f || fspeed < 0.00001f) { //if no exif data or wrong
adap = 2000.;
} else {
- double E_V = fcomp + log2 (double ((fnum * fnum) / fspeed / (fiso / 100.f)));
+ double E_V = fcomp + log2(double ((fnum * fnum) / fspeed / (fiso / 100.f)));
E_V += params.toneCurve.expcomp;// exposure compensation in tonecurve ==> direct EV
- E_V += log2 (params.raw.expos); // exposure raw white point ; log2 ==> linear to EV
- adap = pow (2., E_V - 3.); // cd / m2
+ E_V += log2(params.raw.expos); // exposure raw white point ; log2 ==> linear to EV
+ adap = pow(2., E_V - 3.); // cd / m2
// end calculation adaptation scene luminosity
}
@@ -989,12 +1040,12 @@ void Crop::update (int todo)
}
if (!cieCrop) {
- cieCrop = new CieImage (cropw, croph);
+ cieCrop = new CieImage(cropw, croph);
}
float d, dj, yb; // not used after this block
- parent->ipf.ciecam_02float (cieCrop, float (adap), 1, 2, labnCrop, ¶ms, parent->customColCurve1, parent->customColCurve2, parent->customColCurve3,
- dummy, dummy, parent->CAMBrightCurveJ, parent->CAMBrightCurveQ, parent->CAMMean, 5, skip, execsharp, d, dj, yb, 1, parent->sharpMask);
+ parent->ipf.ciecam_02float(cieCrop, float (adap), 1, 2, labnCrop, ¶ms, parent->customColCurve1, parent->customColCurve2, parent->customColCurve3,
+ dummy, dummy, parent->CAMBrightCurveJ, parent->CAMBrightCurveQ, parent->CAMMean, 5, skip, execsharp, d, dj, yb, 1, parent->sharpMask);
} else {
// CIECAM is disabled, we free up its image buffer to save some space
if (cieCrop) {
@@ -1009,13 +1060,13 @@ void Crop::update (int todo)
PipetteBuffer::setReady();
// Computing the preview image, i.e. converting from lab->Monitor color space (soft-proofing disabled) or lab->Output profile->Monitor color space (soft-proofing enabled)
- parent->ipf.lab2monitorRgb (labnCrop, cropImg);
+ parent->ipf.lab2monitorRgb(labnCrop, cropImg);
if (cropImageListener) {
// Computing the internal image for analysis, i.e. conversion from lab->Output profile (rtSettings.HistogramWorking disabled) or lab->WCS (rtSettings.HistogramWorking enabled)
// internal image in output color space for analysis
- Image8 *cropImgtrue = parent->ipf.lab2rgb (labnCrop, 0, 0, cropw, croph, params.icm);
+ Image8 *cropImgtrue = parent->ipf.lab2rgb(labnCrop, 0, 0, cropw, croph, params.icm);
int finalW = rqcropw;
@@ -1029,30 +1080,30 @@ void Crop::update (int todo)
finalH = cropImg->getHeight() - upperBorder;
}
- Image8* final = new Image8 (finalW, finalH);
- Image8* finaltrue = new Image8 (finalW, finalH);
+ Image8* final = new Image8(finalW, finalH);
+ Image8* finaltrue = new Image8(finalW, finalH);
for (int i = 0; i < finalH; i++) {
- memcpy (final->data + 3 * i * finalW, cropImg->data + 3 * (i + upperBorder)*cropw + 3 * leftBorder, 3 * finalW);
- memcpy (finaltrue->data + 3 * i * finalW, cropImgtrue->data + 3 * (i + upperBorder)*cropw + 3 * leftBorder, 3 * finalW);
+ memcpy(final->data + 3 * i * finalW, cropImg->data + 3 * (i + upperBorder)*cropw + 3 * leftBorder, 3 * finalW);
+ memcpy(finaltrue->data + 3 * i * finalW, cropImgtrue->data + 3 * (i + upperBorder)*cropw + 3 * leftBorder, 3 * finalW);
}
- cropImageListener->setDetailedCrop (final, finaltrue, params.icm, params.crop, rqcropx, rqcropy, rqcropw, rqcroph, skip);
+ cropImageListener->setDetailedCrop(final, finaltrue, params.icm, params.crop, rqcropx, rqcropy, rqcropw, rqcroph, skip);
delete final;
delete finaltrue;
delete cropImgtrue;
}
}
-void Crop::freeAll ()
+void Crop::freeAll()
{
if (settings->verbose) {
- printf ("freeallcrop starts %d\n", (int)cropAllocated);
+ printf("freeallcrop starts %d\n", (int)cropAllocated);
}
if (cropAllocated) {
- if (origCrop ) {
+ if (origCrop) {
delete origCrop;
origCrop = nullptr;
}
@@ -1062,22 +1113,22 @@ void Crop::freeAll ()
transCrop = nullptr;
}
- if (laboCrop ) {
+ if (laboCrop) {
delete laboCrop;
laboCrop = nullptr;
}
- if (labnCrop ) {
+ if (labnCrop) {
delete labnCrop;
labnCrop = nullptr;
}
- if (cropImg ) {
+ if (cropImg) {
delete cropImg;
cropImg = nullptr;
}
- if (cieCrop ) {
+ if (cieCrop) {
delete cieCrop;
cieCrop = nullptr;
}
@@ -1092,7 +1143,7 @@ void Crop::freeAll ()
namespace
{
-bool check_need_larger_crop_for_lcp_distortion (int fw, int fh, int x, int y, int w, int h, const ProcParams ¶ms)
+bool check_need_larger_crop_for_lcp_distortion(int fw, int fh, int x, int y, int w, int h, const ProcParams ¶ms)
{
if (x == 0 && y == 0 && w == fw && h == fh) {
return false;
@@ -1107,15 +1158,15 @@ bool check_need_larger_crop_for_lcp_distortion (int fw, int fh, int x, int y, in
* If the scale changes, this method will free all buffers and reallocate ones of the new size.
* It will then tell to the SizeListener that size has changed (sizeChanged)
*/
-bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool internal)
+bool Crop::setCropSizes(int rcx, int rcy, int rcw, int rch, int skip, bool internal)
{
if (settings->verbose) {
- printf ("setcropsizes before lock\n");
+ printf("setcropsizes before lock\n");
}
if (!internal) {
- cropMutex.lock ();
+ cropMutex.lock();
}
bool changed = false;
@@ -1126,12 +1177,12 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
rqcroph = rch;
// store and set requested crop size
- int rqx1 = LIM (rqcropx, 0, parent->fullw - 1);
- int rqy1 = LIM (rqcropy, 0, parent->fullh - 1);
+ int rqx1 = LIM(rqcropx, 0, parent->fullw - 1);
+ int rqy1 = LIM(rqcropy, 0, parent->fullh - 1);
int rqx2 = rqx1 + rqcropw - 1;
int rqy2 = rqy1 + rqcroph - 1;
- rqx2 = LIM (rqx2, 0, parent->fullw - 1);
- rqy2 = LIM (rqy2, 0, parent->fullh - 1);
+ rqx2 = LIM(rqx2, 0, parent->fullw - 1);
+ rqy2 = LIM(rqy2, 0, parent->fullh - 1);
this->skip = skip;
@@ -1141,10 +1192,10 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
int bx2 = rqx2 + skip * borderRequested;
int by2 = rqy2 + skip * borderRequested;
// clip it to fit into image area
- bx1 = LIM (bx1, 0, parent->fullw - 1);
- by1 = LIM (by1, 0, parent->fullh - 1);
- bx2 = LIM (bx2, 0, parent->fullw - 1);
- by2 = LIM (by2, 0, parent->fullh - 1);
+ bx1 = LIM(bx1, 0, parent->fullw - 1);
+ by1 = LIM(by1, 0, parent->fullh - 1);
+ bx2 = LIM(bx2, 0, parent->fullw - 1);
+ by2 = LIM(by2, 0, parent->fullh - 1);
int bw = bx2 - bx1 + 1;
int bh = by2 - by1 + 1;
@@ -1155,9 +1206,9 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
orw = bw;
orh = bh;
- parent->ipf.transCoord (parent->fw, parent->fh, bx1, by1, bw, bh, orx, ory, orw, orh);
+ parent->ipf.transCoord(parent->fw, parent->fh, bx1, by1, bw, bh, orx, ory, orw, orh);
- if (check_need_larger_crop_for_lcp_distortion (parent->fw, parent->fh, orx, ory, orw, orh, parent->params)) {
+ if (check_need_larger_crop_for_lcp_distortion(parent->fw, parent->fh, orx, ory, orw, orh, parent->params)) {
// TODO - this is an estimate of the max distortion relative to the image size. ATM it is hardcoded to be 15%, which seems enough. If not, need to revise
int dW = int (double (parent->fw) * 0.15 / (2 * skip));
int dH = int (double (parent->fh) * 0.15 / (2 * skip));
@@ -1186,34 +1237,34 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
y2 = parent->fh;
}
- orx = max (x1, 0);
- ory = max (y1, 0);
- orw = min (x2 - x1, parent->fw - orx);
- orh = min (y2 - y1, parent->fh - ory);
+ orx = max(x1, 0);
+ ory = max(y1, 0);
+ orw = min(x2 - x1, parent->fw - orx);
+ orh = min(y2 - y1, parent->fh - ory);
}
- leftBorder = skips (rqx1 - bx1, skip);
- upperBorder = skips (rqy1 - by1, skip);
+ leftBorder = skips(rqx1 - bx1, skip);
+ upperBorder = skips(rqy1 - by1, skip);
- PreviewProps cp (orx, ory, orw, orh, skip);
+ PreviewProps cp(orx, ory, orw, orh, skip);
int orW, orH;
- parent->imgsrc->getSize (cp, orW, orH);
+ parent->imgsrc->getSize(cp, orW, orH);
trafx = orx;
trafy = ory;
- int cw = skips (bw, skip);
- int ch = skips (bh, skip);
+ int cw = skips(bw, skip);
+ int ch = skips(bh, skip);
if (settings->verbose) {
- printf ("setsizes starts (%d, %d, %d, %d, %d, %d)\n", orW, orH, trafw, trafh, cw, ch);
+ printf("setsizes starts (%d, %d, %d, %d, %d, %d)\n", orW, orH, trafw, trafh, cw, ch);
}
EditType editType = ET_PIPETTE;
- if (const auto editProvider = PipetteBuffer::getDataProvider ()) {
- if (const auto editSubscriber = editProvider->getCurrSubscriber ()) {
- editType = editSubscriber->getEditingType ();
+ if (const auto editProvider = PipetteBuffer::getDataProvider()) {
+ if (const auto editSubscriber = editProvider->getCurrSubscriber()) {
+ editType = editSubscriber->getEditingType();
}
}
@@ -1228,30 +1279,30 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
origCrop = new Imagefloat;
}
- origCrop->allocate (trafw, trafh); // Resizing the buffer (optimization)
+ origCrop->allocate(trafw, trafh); // Resizing the buffer (optimization)
// if transCrop doesn't exist yet, it'll be created where necessary
if (transCrop) {
- transCrop->allocate (cropw, croph);
+ transCrop->allocate(cropw, croph);
}
if (laboCrop) {
delete laboCrop; // laboCrop can't be resized
}
- laboCrop = new LabImage (cropw, croph);
+ laboCrop = new LabImage(cropw, croph);
if (labnCrop) {
delete labnCrop; // labnCrop can't be resized
}
- labnCrop = new LabImage (cropw, croph);
+ labnCrop = new LabImage(cropw, croph);
if (!cropImg) {
cropImg = new Image8;
}
- cropImg->allocate (cropw, croph); // Resizing the buffer (optimization)
+ cropImg->allocate(cropw, croph); // Resizing the buffer (optimization)
//cieCrop is only used in Crop::update, it is destroyed now but will be allocated on first use
if (cieCrop) {
@@ -1260,7 +1311,7 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
}
if (editType == ET_PIPETTE) {
- PipetteBuffer::resize (cropw, croph);
+ PipetteBuffer::resize(cropw, croph);
} else if (PipetteBuffer::bufferCreated()) {
PipetteBuffer::flush();
}
@@ -1274,11 +1325,11 @@ bool Crop::setCropSizes (int rcx, int rcy, int rcw, int rch, int skip, bool inte
cropy = by1;
if (settings->verbose) {
- printf ("setsizes ends\n");
+ printf("setsizes ends\n");
}
if (!internal) {
- cropMutex.unlock ();
+ cropMutex.unlock();
}
return changed;
@@ -1313,20 +1364,20 @@ bool Crop::tryUpdate()
*
* This method is called when the visible part of the crop has changed (resize, zoom, etc..), so it needs a full update
*/
-void Crop::fullUpdate ()
+void Crop::fullUpdate()
{
- parent->updaterThreadStart.lock ();
+ parent->updaterThreadStart.lock();
if (parent->updaterRunning && parent->thread) {
// Do NOT reset changes here, since in a long chain of events it will lead to chroma_scale not being updated,
// causing Color::lab2rgb to return a black image on some opens
//parent->changeSinceLast = 0;
- parent->thread->join ();
+ parent->thread->join();
}
if (parent->plistener) {
- parent->plistener->setProgressState (true);
+ parent->plistener->setProgressState(true);
}
// If there are more update request, the following WHILE will collect it
@@ -1334,33 +1385,33 @@ void Crop::fullUpdate ()
while (newUpdatePending) {
newUpdatePending = false;
- update (ALL);
+ update(ALL);
}
updating = false; // end of crop update
if (parent->plistener) {
- parent->plistener->setProgressState (false);
+ parent->plistener->setProgressState(false);
}
- parent->updaterThreadStart.unlock ();
+ parent->updaterThreadStart.unlock();
}
int Crop::get_skip()
{
- MyMutex::MyLock lock (cropMutex);
+ MyMutex::MyLock lock(cropMutex);
return skip;
}
int Crop::getLeftBorder()
{
- MyMutex::MyLock lock (cropMutex);
+ MyMutex::MyLock lock(cropMutex);
return leftBorder;
}
int Crop::getUpperBorder()
{
- MyMutex::MyLock lock (cropMutex);
+ MyMutex::MyLock lock(cropMutex);
return upperBorder;
}
diff --git a/rtengine/gamutwarning.cc b/rtengine/gamutwarning.cc
index 87be430b2..84b4b3c08 100644
--- a/rtengine/gamutwarning.cc
+++ b/rtengine/gamutwarning.cc
@@ -34,7 +34,7 @@ GamutWarning::GamutWarning(cmsHPROFILE iprof, cmsHPROFILE gamutprof, RenderingIn
softproof2ref(nullptr)
{
if (cmsIsMatrixShaper(gamutprof) && !cmsIsCLUT(gamutprof, intent, LCMS_USED_AS_OUTPUT)) {
- cmsHPROFILE aces = ICCStore::getInstance()->getProfile("ACES");
+ cmsHPROFILE aces = ICCStore::getInstance()->getProfile("RTv4_ACES-AP0");
if (aces) {
lab2ref = cmsCreateTransform(iprof, TYPE_Lab_FLT, aces, TYPE_RGB_FLT, INTENT_ABSOLUTE_COLORIMETRIC, cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE);
lab2softproof = cmsCreateTransform(iprof, TYPE_Lab_FLT, gamutprof, TYPE_RGB_FLT, INTENT_ABSOLUTE_COLORIMETRIC, cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE);
diff --git a/rtengine/histmatching.cc b/rtengine/histmatching.cc
index 23def70ca..2dfcc6d3b 100644
--- a/rtengine/histmatching.cc
+++ b/rtengine/histmatching.cc
@@ -187,7 +187,7 @@ void RawImageSource::getAutoMatchedToneCurve(const ColorManagementParams &cp, st
const auto same_profile =
[](const ColorManagementParams &a, const ColorManagementParams &b) -> bool
{
- return (a.input == b.input
+ return (a.inputProfile == b.inputProfile
&& a.toneCurve == b.toneCurve
&& a.applyLookTable == b.applyLookTable
&& a.applyBaselineExposureOffset == b.applyBaselineExposureOffset
@@ -220,9 +220,7 @@ void RawImageSource::getAutoMatchedToneCurve(const ColorManagementParams &cp, st
neutral.icm = cp;
neutral.raw.bayersensor.method = RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::FAST);
neutral.raw.xtranssensor.method = RAWParams::XTransSensor::getMethodString(RAWParams::XTransSensor::Method::FAST);
- neutral.icm.output = "sRGB";
- neutral.icm.gamma = "default";
- neutral.icm.freegamma = false;
+ neutral.icm.outputProfile = "sRGB";
std::unique_ptr source;
{
diff --git a/rtengine/iccmatrices.h b/rtengine/iccmatrices.h
index a6fd8d9e6..d20cb70c3 100644
--- a/rtengine/iccmatrices.h
+++ b/rtengine/iccmatrices.h
@@ -32,6 +32,19 @@ constexpr double d50_d65[3][3] = {
{ -0.0092345, 0.0150436, 0.7521316}
};
+//J.Desmis 04 2018
+constexpr double d50_d60[3][3] = {
+ { 1.034368, 0.016908, -0.037658},
+ {0.021752, 0.992183, -0.012785},
+ { -0.006971, 0.011377, 0.812150}
+};
+
+constexpr double d60_d50[3][3] = {
+ { 0.96743198, -0.01699717, 0.044590689},
+ {-0.02109893, 1.008067172, 0.014890785},
+ {0.008598998, -0.01426777, 1.231474467}
+};
+
// Color space conversion to/from XYZ; color spaces adapted to D65
constexpr double xyz_sRGBd65[3][3] = {
{0.4124564, 0.3575761, 0.1804375},
@@ -66,6 +79,31 @@ constexpr double xyz_sRGB[3][3] = {
{0.0139322, 0.0971045, 0.7141733}
};
+constexpr double xyz_ACESp0[3][3] = {
+ {0.9525523959, 0.0, 0.0000936786},
+ {0.3439664498, 0.7281660966 , -0.0721325464},
+ {0.0, -0.0, 1.0088251844}
+};
+
+constexpr double ACESp0_xyz[3][3] = {
+ {1.0498110175, 0.0, -0.0000974845},
+ {-0.4959030231, 1.3733130458 , 0.0982400361},
+ {0.0, 0.0, 0.9912520182}
+};
+
+constexpr double xyz_ACESp1[3][3] = {
+ {0.689697, 0.149944, 0.124559},
+ {0.284448, 0.671758 , 0.043794},
+ {-0.006043, 0.009998, 0.820945}
+};
+
+constexpr double ACESp1_xyz[3][3] = {
+ {1.5932624, -0.352316, -0.222945},
+ {-0.6759496, 1.639286 , 0.01511026},
+ {0.0199602, -0.0225577, 1.2162833}
+};
+
+
constexpr double sRGB_xyz[3][3] = {
{3.1338561, -1.6168667, -0.4906146},
{ -0.9787684, 1.9161415, 0.0334540},
diff --git a/rtengine/iccstore.cc b/rtengine/iccstore.cc
index eeb9ef1c4..4d490c0a0 100644
--- a/rtengine/iccstore.cc
+++ b/rtengine/iccstore.cc
@@ -36,9 +36,10 @@
#include "../rtgui/options.h"
#include "../rtgui/threadutils.h"
+#include "lcms2_plugin.h"
#include "cJSON.h"
-
+#define inkc_constant 0x696E6B43
namespace rtengine
{
@@ -157,6 +158,7 @@ bool loadProfile(
if (profileContents) {
profileContents->emplace(name, content);
}
+
return true;
}
}
@@ -196,12 +198,11 @@ cmsHPROFILE createXYZProfile()
return rtengine::ICCStore::createFromMatrix(mat, false, "XYZ");
}
-const double(*wprofiles[])[3] = {xyz_sRGB, xyz_adobe, xyz_prophoto, xyz_widegamut, xyz_bruce, xyz_beta, xyz_best, xyz_rec2020};
-const double(*iwprofiles[])[3] = {sRGB_xyz, adobe_xyz, prophoto_xyz, widegamut_xyz, bruce_xyz, beta_xyz, best_xyz, rec2020_xyz};
-const char* wpnames[] = {"sRGB", "Adobe RGB", "ProPhoto", "WideGamut", "BruceRGB", "Beta RGB", "BestRGB", "Rec2020"};
-const char* wpgamma[] = {"default", "BT709_g2.2_s4.5", "sRGB_g2.4_s12.92", "linear_g1.0", "standard_g2.2", "standard_g1.8", "High_g1.3_s3.35", "Low_g2.6_s6.9"}; //gamma free
+const double(*wprofiles[])[3] = {xyz_sRGB, xyz_adobe, xyz_prophoto, xyz_widegamut, xyz_bruce, xyz_beta, xyz_best, xyz_rec2020, xyz_ACESp0, xyz_ACESp1};//
+const double(*iwprofiles[])[3] = {sRGB_xyz, adobe_xyz, prophoto_xyz, widegamut_xyz, bruce_xyz, beta_xyz, best_xyz, rec2020_xyz, ACESp0_xyz, ACESp1_xyz};//
+const char* wpnames[] = {"sRGB", "Adobe RGB", "ProPhoto", "WideGamut", "BruceRGB", "Beta RGB", "BestRGB", "Rec2020", "ACESp0", "ACESp1"};//
//default = gamma inside profile
-//BT709 g=2.22 s=4.5 sRGB g=2.4 s=12.92
+//BT709 g=2.22 s=4.5 sRGB g=2.4 s=12.92310
//linear g=1.0
//std22 g=2.2 std18 g=1.8
// high g=1.3 s=3.35 for high dynamic images
@@ -221,7 +222,8 @@ rtengine::ProfileContent::ProfileContent(const Glib::ustring& fileName)
fseek(f, 0, SEEK_END);
long length = ftell(f);
- if(length > 0) {
+
+ if (length > 0) {
char* d = new char[length + 1];
fseek(f, 0, SEEK_SET);
length = fread(d, 1, length, f);
@@ -231,6 +233,7 @@ rtengine::ProfileContent::ProfileContent(const Glib::ustring& fileName)
} else {
data.clear();
}
+
fclose(f);
}
@@ -255,8 +258,8 @@ cmsHPROFILE rtengine::ProfileContent::toProfile() const
return
!data.empty()
- ? cmsOpenProfileFromMem(data.c_str(), data.size())
- : nullptr;
+ ? cmsOpenProfileFromMem(data.c_str(), data.size())
+ : nullptr;
}
const std::string& rtengine::ProfileContent::getData() const
@@ -291,20 +294,23 @@ public:
cmsCloseProfile(p.second);
}
}
+
// for (auto &p : wProfilesGamma) {
// if (p.second) {
// cmsCloseProfile(p.second);
// }
// }
for (auto &p : fileProfiles) {
- if(p.second) {
+ if (p.second) {
cmsCloseProfile(p.second);
}
}
- if(srgb) {
+
+ if (srgb) {
cmsCloseProfile(srgb);
}
- if(xyz) {
+
+ if (xyz) {
cmsCloseProfile(xyz);
}
}
@@ -322,6 +328,7 @@ public:
userICCDir = usrICCDir;
fileProfiles.clear();
fileProfileContents.clear();
+
if (loadAll) {
loadProfiles(profilesDir, &fileProfiles, &fileProfileContents, nullptr, false);
loadProfiles(userICCDir, &fileProfiles, &fileProfileContents, nullptr, false);
@@ -332,6 +339,7 @@ public:
stdProfilesDir = Glib::build_filename(rtICCDir, "input");
fileStdProfiles.clear();
fileStdProfilesFileNames.clear();
+
if (loadAll) {
loadProfiles(stdProfilesDir, nullptr, nullptr, &fileStdProfilesFileNames, true);
Glib::ustring user_input_icc_dir = Glib::build_filename(options.rtdir, "iccprofiles", "input");
@@ -342,7 +350,7 @@ public:
loadWorkingSpaces(rtICCDir);
loadWorkingSpaces(userICCDir);
-
+
// initialize the alarm colours for lcms gamut checking -- we use bright green
cmsUInt16Number cms_alarm_codes[cmsMAXCHANNELS] = { 0, 65535, 65535 };
cmsSetAlarmCodes(cms_alarm_codes);
@@ -354,8 +362,8 @@ public:
return
r != wProfiles.end()
- ? r->second
- : wProfiles.find("sRGB")->second;
+ ? r->second
+ : wProfiles.find("sRGB")->second;
}
// cmsHPROFILE workingSpaceGamma(const Glib::ustring& name) const
@@ -375,8 +383,8 @@ public:
return
r != wMatrices.end()
- ? r->second
- : wMatrices.find("sRGB")->second;
+ ? r->second
+ : wMatrices.find("sRGB")->second;
}
TMatrix workingSpaceInverseMatrix(const Glib::ustring& name) const
@@ -386,8 +394,8 @@ public:
return
r != iwMatrices.end()
- ? r->second
- : iwMatrices.find("sRGB")->second;
+ ? r->second
+ : iwMatrices.find("sRGB")->second;
}
bool outputProfileExist(const Glib::ustring& name) const
@@ -421,7 +429,9 @@ public:
if (!loadProfile(name, profilesDir, &fileProfiles, &fileProfileContents)) {
loadProfile(name, userICCDir, &fileProfiles, &fileProfileContents);
}
+
const ProfileMap::const_iterator r = fileProfiles.find(name);
+
if (r != fileProfiles.end()) {
return r->second;
}
@@ -446,7 +456,9 @@ public:
if (!loadProfile(name, profilesDir, &fileProfiles, &fileProfileContents)) {
loadProfile(name, userICCDir, &fileProfiles, &fileProfileContents);
}
+
const ProfileMap::const_iterator r = fileProfiles.find(name);
+
if (r != fileProfiles.end()) {
return r->second;
}
@@ -481,8 +493,8 @@ public:
return
r != fileProfileContents.end()
- ? r->second
- : ProfileContent();
+ ? r->second
+ : ProfileContent();
}
cmsHPROFILE getXYZProfile() const
@@ -503,22 +515,22 @@ public:
for (const auto profile : fileProfiles) {
if (
- (
- type==ICCStore::ProfileType::MONITOR
- && cmsGetDeviceClass(profile.second) == cmsSigDisplayClass
- && cmsGetColorSpace(profile.second) == cmsSigRgbData
- )
- ||(
- type==ICCStore::ProfileType::PRINTER
- && cmsGetDeviceClass(profile.second) == cmsSigOutputClass
- )
- ||(
- type==ICCStore::ProfileType::OUTPUT
- && (cmsGetDeviceClass(profile.second) == cmsSigDisplayClass
- || cmsGetDeviceClass(profile.second) == cmsSigInputClass
- || cmsGetDeviceClass(profile.second) == cmsSigOutputClass)
- && cmsGetColorSpace(profile.second) == cmsSigRgbData
- )
+ (
+ type == ICCStore::ProfileType::MONITOR
+ && cmsGetDeviceClass(profile.second) == cmsSigDisplayClass
+ && cmsGetColorSpace(profile.second) == cmsSigRgbData
+ )
+ || (
+ type == ICCStore::ProfileType::PRINTER
+ && cmsGetDeviceClass(profile.second) == cmsSigOutputClass
+ )
+ || (
+ type == ICCStore::ProfileType::OUTPUT
+ && (cmsGetDeviceClass(profile.second) == cmsSigDisplayClass
+ || cmsGetDeviceClass(profile.second) == cmsSigInputClass
+ || cmsGetDeviceClass(profile.second) == cmsSigOutputClass)
+ && cmsGetColorSpace(profile.second) == cmsSigRgbData
+ )
) {
res.push_back(profile.first);
}
@@ -601,7 +613,7 @@ public:
for (const auto &p : wProfiles) {
res.push_back(p.first);
}
-
+
return res;
}
@@ -619,11 +631,13 @@ private:
CMatrix toMatrix() const
{
CMatrix ret;
+
for (int i = 0; i < 3; ++i) {
for (int j = 0; j < 3; ++j) {
ret[i][j] = matrix[i][j];
}
}
+
return ret;
}
@@ -640,22 +654,28 @@ private:
bool computeWorkingSpaceMatrix(const Glib::ustring &path, const Glib::ustring &filename, PMatrix &out)
{
Glib::ustring fullpath = filename;
+
if (!Glib::path_is_absolute(fullpath)) {
fullpath = Glib::build_filename(path, filename);
}
+
ProfileContent content(fullpath);
cmsHPROFILE prof = content.toProfile();
+
if (!prof) {
return false;
}
+
if (cmsGetColorSpace(prof) != cmsSigRgbData) {
cmsCloseProfile(prof);
return false;
}
+
if (!cmsIsMatrixShaper(prof)) {
cmsCloseProfile(prof);
return false;
}
+
cmsCIEXYZ *red = static_cast(cmsReadTag(prof, cmsSigRedMatrixColumnTag));
cmsCIEXYZ *green = static_cast(cmsReadTag(prof, cmsSigGreenMatrixColumnTag));
cmsCIEXYZ *blue = static_cast(cmsReadTag(prof, cmsSigBlueMatrixColumnTag));
@@ -670,13 +690,18 @@ private:
CVector({ red->Y, green->Y, blue->Y }),
CVector({ red->Z, green->Z, blue->Z })
};
-
+ m[1][0] = red->Y;
+ m[1][1] = green->Y;
+ m[1][2] = blue->Y;
+ m[2][0] = red->Z;
+ m[2][1] = green->Z;
+ m[2][2] = blue->Z;
out.set(m);
-
+
cmsCloseProfile(prof);
return true;
}
-
+
bool loadWorkingSpaces(const Glib::ustring &path)
{
Glib::ustring fileName = Glib::build_filename(path, "workingspaces.json");
@@ -685,29 +710,32 @@ private:
if (settings->verbose) {
std::cout << "trying to load extra working spaces from " << fileName << std::flush;
}
-
+
if (!f) {
if (settings->verbose) {
std::cout << " FAIL" << std::endl;
}
+
return false;
}
fseek(f, 0, SEEK_END);
long length = ftell(f);
+
if (length <= 0) {
if (settings->verbose) {
std::cout << " FAIL" << std::endl;
}
+
fclose(f);
return false;
}
-
+
char *buf = new char[length + 1];
fseek(f, 0, SEEK_SET);
length = fread(buf, 1, length, f);
buf[length] = 0;
-
+
fclose(f);
cJSON_Minify(buf);
@@ -717,21 +745,23 @@ private:
if (settings->verbose) {
std::cout << " FAIL" << std::endl;
}
+
return false;
}
delete[] buf;
cJSON *js = cJSON_GetObjectItem(root, "working_spaces");
+
if (!js) {
goto parse_error;
}
-
+
for (js = js->child; js != nullptr; js = js->next) {
cJSON *ji = cJSON_GetObjectItem(js, "name");
std::unique_ptr m(new PMatrix);
std::string name;
-
+
if (!ji || ji->type != cJSON_String) {
goto parse_error;
}
@@ -743,19 +773,22 @@ private:
}
bool found_matrix = false;
-
+
ji = cJSON_GetObjectItem(js, "matrix");
+
if (ji) {
if (ji->type != cJSON_Array) {
goto parse_error;
}
ji = ji->child;
+
for (int i = 0; i < 3; ++i) {
for (int j = 0; j < 3; ++j, ji = ji->next) {
if (!ji || ji->type != cJSON_Number) {
goto parse_error;
}
+
m->matrix[i][j] = ji->valuedouble;
}
}
@@ -763,12 +796,15 @@ private:
if (ji) {
goto parse_error;
}
+
found_matrix = true;
} else {
ji = cJSON_GetObjectItem(js, "file");
+
if (!ji || ji->type != cJSON_String) {
goto parse_error;
}
+
found_matrix = computeWorkingSpaceMatrix(path, ji->valuestring, *m);
}
@@ -776,6 +812,7 @@ private:
if (settings->verbose) {
std::cout << "Could not find suitable matrix for working space: " << name << std::endl;
}
+
continue;
}
@@ -783,10 +820,12 @@ private:
TMatrix w = pMatrices.back()->matrix;
CMatrix b = {};
+
if (!rtengine::invertMatrix(pMatrices.back()->toMatrix(), b)) {
if (settings->verbose) {
std::cout << "Matrix for working space: " << name << " is not invertible, skipping" << std::endl;
}
+
pMatrices.pop_back();
} else {
wMatrices[name] = w;
@@ -798,29 +837,36 @@ private:
if (settings->verbose) {
std::cout << "Added working space: " << name << std::endl;
std::cout << " matrix: [";
+
for (int i = 0; i < 3; ++i) {
std::cout << " [";
+
for (int j = 0; j < 3; ++j) {
std::cout << " " << w[i][j];
}
+
std::cout << "]";
}
+
std::cout << " ]" << std::endl;
}
}
}
cJSON_Delete(root);
+
if (settings->verbose) {
std::cout << " OK" << std::endl;
}
+
return true;
- parse_error:
+parse_error:
+
if (settings->verbose) {
std::cout << " ERROR in parsing " << fileName << std::endl;
}
-
+
cJSON_Delete(root);
return false;
}
@@ -983,88 +1029,6 @@ std::vector rtengine::ICCStore::getWorkingProfiles()
return implementation->getWorkingProfiles();
}
-std::vector rtengine::ICCStore::getGamma()
-{
-
- std::vector res;
-
- for (unsigned int i = 0; i < sizeof(wpgamma) / sizeof(wpgamma[0]); i++) {
- res.push_back(wpgamma[i]);
- }
-
- return res;
-}
-
-void rtengine::ICCStore::getGammaArray(const procparams::ColorManagementParams &icm, GammaValues &ga)
-{
- const double eps = 0.000000001; // not divide by zero
- if (!icm.freegamma) {//if Free gamma not selected
- // gamma : ga[0],ga[1],ga[2],ga[3],ga[4],ga[5] by calcul
- if(icm.gamma == "BT709_g2.2_s4.5") {
- ga[0] = 2.22; //BT709 2.2 4.5 - my preferred as D.Coffin
- ga[1] = 0.909995;
- ga[2] = 0.090005;
- ga[3] = 0.222222;
- ga[4] = 0.081071;
- } else if (icm.gamma == "sRGB_g2.4_s12.92") {
- ga[0] = 2.40; //sRGB 2.4 12.92 - RT default as Lightroom
- ga[1] = 0.947858;
- ga[2] = 0.052142;
- ga[3] = 0.077399;
- ga[4] = 0.039293;
- } else if (icm.gamma == "High_g1.3_s3.35") {
- ga[0] = 1.3 ; //for high dynamic images
- ga[1] = 0.998279;
- ga[2] = 0.001721;
- ga[3] = 0.298507;
- ga[4] = 0.005746;
- } else if (icm.gamma == "Low_g2.6_s6.9") {
- ga[0] = 2.6 ; //gamma 2.6 variable : for low contrast images
- ga[1] = 0.891161;
- ga[2] = 0.108839;
- ga[3] = 0.144928;
- ga[4] = 0.076332;
- } else if (icm.gamma == "standard_g2.2") {
- ga[0] = 2.2; //gamma=2.2(as gamma of Adobe, Widegamut...)
- ga[1] = 1.;
- ga[2] = 0.;
- ga[3] = 1. / eps;
- ga[4] = 0.;
- } else if (icm.gamma == "standard_g1.8") {
- ga[0] = 1.8; //gamma=1.8(as gamma of Prophoto)
- ga[1] = 1.;
- ga[2] = 0.;
- ga[3] = 1. / eps;
- ga[4] = 0.;
- } else /* if (icm.gamma == "linear_g1.0") */ {
- ga[0] = 1.0; //gamma=1 linear : for high dynamic images(cf : D.Coffin...)
- ga[1] = 1.;
- ga[2] = 0.;
- ga[3] = 1. / eps;
- ga[4] = 0.;
- }
- ga[5] = 0.0;
- ga[6] = 0.0;
- } else { //free gamma selected
- GammaValues g_a; //gamma parameters
- double pwr = 1.0 / icm.gampos;
- double ts = icm.slpos;
- double slope = icm.slpos == 0 ? eps : icm.slpos;
-
- int mode = 0;
- Color::calcGamma(pwr, ts, mode, g_a); // call to calcGamma with selected gamma and slope : return parameters for LCMS2
- ga[4] = g_a[3] * ts;
- //printf("g_a.gamma0=%f g_a.gamma1=%f g_a.gamma2=%f g_a.gamma3=%f g_a.gamma4=%f\n", g_a.gamma0,g_a.gamma1,g_a.gamma2,g_a.gamma3,g_a.gamma4);
- ga[0] = icm.gampos;
- ga[1] = 1. /(1.0 + g_a[4]);
- ga[2] = g_a[4] /(1.0 + g_a[4]);
- ga[3] = 1. / slope;
- ga[5] = 0.0;
- ga[6] = 0.0;
- //printf("ga[0]=%f ga[1]=%f ga[2]=%f ga[3]=%f ga[4]=%f\n", ga[0],ga[1],ga[2],ga[3],ga[4]);
- }
-}
-
// WARNING: the caller must lock lcmsMutex
cmsHPROFILE rtengine::ICCStore::makeStdGammaProfile(cmsHPROFILE iprof)
{
@@ -1096,7 +1060,7 @@ cmsHPROFILE rtengine::ICCStore::makeStdGammaProfile(cmsHPROFILE iprof)
const uint32_t gamma = 0x239;
int gamma_size = 14;
- int data_size =(gamma_size + 3) & ~3;
+ int data_size = (gamma_size + 3) & ~3;
for (uint32_t i = 0; i < tag_count; i++) {
memcpy(&tags[i], p, 12);
@@ -1109,7 +1073,7 @@ cmsHPROFILE rtengine::ICCStore::makeStdGammaProfile(cmsHPROFILE iprof)
tags[i].sig != 0x67545243 && // gTRC
tags[i].sig != 0x72545243 && // rTRC
tags[i].sig != 0x6B545243) { // kTRC
- data_size +=(tags[i].size + 3) & ~3;
+ data_size += (tags[i].size + 3) & ~3;
}
}
@@ -1140,7 +1104,7 @@ cmsHPROFILE rtengine::ICCStore::makeStdGammaProfile(cmsHPROFILE iprof)
memcpy(&nd[offset + 12], &gm, 2);
}
- offset +=(gamma_size + 3) & ~3;
+ offset += (gamma_size + 3) & ~3;
}
tag.offset = htonl(gamma_offset);
@@ -1149,7 +1113,7 @@ cmsHPROFILE rtengine::ICCStore::makeStdGammaProfile(cmsHPROFILE iprof)
tag.offset = htonl(offset);
tag.size = htonl(tags[i].size);
memcpy(&nd[offset], &data[tags[i].offset], tags[i].size);
- offset +=(tags[i].size + 3) & ~3;
+ offset += (tags[i].size + 3) & ~3;
}
memcpy(&nd[128 + 4 + i * 12], &tag, 12);
@@ -1191,7 +1155,7 @@ cmsHPROFILE rtengine::ICCStore::createFromMatrix(const double matrix[3][3], bool
pcurve[2] = 1;
// pcurve[3] = 0x1f00000;// pcurve for gamma BT709 : g=2.22 s=4.5
// normalize gamma in RT, default(Emil's choice = sRGB)
- pcurve[3] = 0x2390000;//pcurve for gamma sRGB : g:2.4 s=12.92
+ pcurve[3] = 0x2390000;//pcurve for gamma sRGB : g:2.4 s=12.92310
} else {
// lcms2 up to 2.4 has a bug with linear gamma causing precision loss(banding)
@@ -1214,9 +1178,9 @@ cmsHPROFILE rtengine::ICCStore::createFromMatrix(const double matrix[3][3], bool
// 0x74657874 : text
// 0x64657363 : description tag
for (unsigned int i = 0; i < pbody[0]; i++) {
- oprof[oprof[0] / 4] = i ?(i > 1 ? 0x58595a20 : 0x64657363) : 0x74657874;
+ oprof[oprof[0] / 4] = i ? (i > 1 ? 0x58595a20 : 0x64657363) : 0x74657874;
pbody[i * 3 + 2] = oprof[0];
- oprof[0] +=(pbody[i * 3 + 3] + 3) & -4;
+ oprof[0] += (pbody[i * 3 + 3] + 3) & -4;
}
memcpy(oprof + 32, pbody, sizeof(pbody));
@@ -1255,232 +1219,3 @@ cmsHPROFILE rtengine::ICCStore::createFromMatrix(const double matrix[3][3], bool
delete [] oprof;
return p;
}
-
-cmsHPROFILE rtengine::ICCStore::createGammaProfile(const procparams::ColorManagementParams &icm, GammaValues &ga)
-{
- float p[6]; //primaries
- ga[6] = 0.0;
-
- enum class ColorTemp {
- D50 = 5003, // for Widegamut, Prophoto Best, Beta -> D50
- D65 = 6504 // for sRGB, AdobeRGB, Bruce Rec2020 -> D65
- };
- ColorTemp temp = ColorTemp::D50;
-
- //primaries for 7 working profiles ==> output profiles
- // eventually to adapt primaries if RT used special profiles !
- if (icm.output == "WideGamut") {
- p[0] = 0.7350; //Widegamut primaries
- p[1] = 0.2650;
- p[2] = 0.1150;
- p[3] = 0.8260;
- p[4] = 0.1570;
- p[5] = 0.0180;
- } else if (icm.output == "Adobe RGB") {
- p[0] = 0.6400; //Adobe primaries
- p[1] = 0.3300;
- p[2] = 0.2100;
- p[3] = 0.7100;
- p[4] = 0.1500;
- p[5] = 0.0600;
- temp = ColorTemp::D65;
- } else if (icm.output == "sRGB") {
- p[0] = 0.6400; // sRGB primaries
- p[1] = 0.3300;
- p[2] = 0.3000;
- p[3] = 0.6000;
- p[4] = 0.1500;
- p[5] = 0.0600;
- temp = ColorTemp::D65;
- } else if (icm.output == "BruceRGB") {
- p[0] = 0.6400; // Bruce primaries
- p[1] = 0.3300;
- p[2] = 0.2800;
- p[3] = 0.6500;
- p[4] = 0.1500;
- p[5] = 0.0600;
- temp = ColorTemp::D65;
- } else if (icm.output == "Beta RGB") {
- p[0] = 0.6888; // Beta primaries
- p[1] = 0.3112;
- p[2] = 0.1986;
- p[3] = 0.7551;
- p[4] = 0.1265;
- p[5] = 0.0352;
- } else if (icm.output == "BestRGB") {
- p[0] = 0.7347; // Best primaries
- p[1] = 0.2653;
- p[2] = 0.2150;
- p[3] = 0.7750;
- p[4] = 0.1300;
- p[5] = 0.0350;
- } else if (icm.output == "Rec2020") {
- p[0] = 0.7080; // Rec2020 primaries
- p[1] = 0.2920;
- p[2] = 0.1700;
- p[3] = 0.7970;
- p[4] = 0.1310;
- p[5] = 0.0460;
- temp = ColorTemp::D65;
- } else {
- p[0] = 0.7347; //ProPhoto and default primaries
- p[1] = 0.2653;
- p[2] = 0.1596;
- p[3] = 0.8404;
- p[4] = 0.0366;
- p[5] = 0.0001;
- }
-
- cmsCIExyY xyD;
- cmsCIExyYTRIPLE Primaries = {
- {p[0], p[1], 1.0}, // red
- {p[2], p[3], 1.0}, // green
- {p[4], p[5], 1.0} // blue
- };
- cmsToneCurve* GammaTRC[3];
-
- // 7 parameters for smoother curves
- cmsFloat64Number Parameters[7] = { ga[0], ga[1], ga[2], ga[3], ga[4], ga[5], ga[6] } ;
-
- //lcmsMutex->lock(); Mutex acquired by the caller
- cmsWhitePointFromTemp(&xyD,(double)temp);
- GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(nullptr, 5, Parameters); //5 = smoother than 4
- cmsHPROFILE oprofdef = cmsCreateRGBProfile(&xyD, &Primaries, GammaTRC); //oprofdef become Outputprofile
- cmsFreeToneCurve(GammaTRC[0]);
- //lcmsMutex->unlock();
-
- return oprofdef;
-}
-
-// WARNING: the caller must lock lcmsMutex
-cmsHPROFILE rtengine::ICCStore::createCustomGammaOutputProfile(const procparams::ColorManagementParams &icm, GammaValues &ga)
-{
- bool pro = false;
- Glib::ustring outProfile;
- cmsHPROFILE outputProfile = nullptr;
-
- if (icm.freegamma && icm.gampos < 1.35) {
- pro = true; //select profil with gammaTRC modified :
- } else if (icm.gamma == "linear_g1.0" ||(icm.gamma == "High_g1.3_s3.35")) {
- pro = true; //pro=0 RT_sRGB || Prophoto
- }
-
- // Check that output profiles exist, otherwise use LCMS2
- // Use the icc/icm profiles associated to possible working profiles, set in "options"
- if (icm.working == "ProPhoto" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.prophoto) && !pro) {
- outProfile = options.rtSettings.prophoto;
- } else if (icm.working == "Adobe RGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.adobe) ) {
- outProfile = options.rtSettings.adobe;
- } else if (icm.working == "WideGamut" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.widegamut) ) {
- outProfile = options.rtSettings.widegamut;
- } else if (icm.working == "Beta RGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.beta) ) {
- outProfile = options.rtSettings.beta;
- } else if (icm.working == "BestRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.best) ) {
- outProfile = options.rtSettings.best;
- } else if (icm.working == "BruceRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.bruce) ) {
- outProfile = options.rtSettings.bruce;
- } else if (icm.working == "sRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.srgb) && !pro) {
- outProfile = options.rtSettings.srgb;
- } else if (icm.working == "sRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.srgb10) && pro) {
- outProfile = options.rtSettings.srgb10;
- } else if (icm.working == "ProPhoto" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.prophoto10) && pro) {
- outProfile = options.rtSettings.prophoto10;
- } else if (icm.working == "Rec2020" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.rec2020) ) {
- outProfile = options.rtSettings.rec2020;
- } else {
- // Should not occurs
- if (settings->verbose) {
- printf("\"%s\": unknown working profile! - use LCMS2 substitution\n", icm.working.c_str() );
- }
-
- return nullptr;
- }
-
- //begin adaptation rTRC gTRC bTRC
- //"outputProfile" profile has the same characteristics than RGB values, but TRC are adapted... for applying profile
- if (settings->verbose) {
- printf("Output Gamma - profile: \"%s\"\n", outProfile.c_str() ); //c_str()
- }
-
- outputProfile = ICCStore::getInstance()->getProfile(outProfile); //get output profile
-
- if (outputProfile == nullptr) {
-
- if (settings->verbose) {
- printf("\"%s\" ICC output profile not found!\n", outProfile.c_str());
- }
- return nullptr;
- }
-
- // 7 parameters for smoother curves
- cmsFloat64Number Parameters[7] = { ga[0], ga[1], ga[2], ga[3], ga[4], ga[5], ga[6] };
-
- //change desc Tag , to "free gamma", or "BT709", etc.
- cmsMLU *mlu;
- cmsContext ContextID = cmsGetProfileContextID(outputProfile); // create context to modify some TAGs
- mlu = cmsMLUalloc(ContextID, 1);
-
- // instruction with //ICC are used to generate ICC profile
- if (mlu == nullptr) {
- printf("Description error\n");
- } else {
-
- // Description TAG : selection of gamma and Primaries
- if (!icm.freegamma) {
- std::wstring gammaStr;
-
- if(icm.gamma == "High_g1.3_s3.35") {
- gammaStr = std::wstring(L"GammaTRC: High g=1.3 s=3.35");
- } else if (icm.gamma == "Low_g2.6_s6.9") {
- gammaStr = std::wstring(L"GammaTRC: Low g=2.6 s=6.9");
- } else if (icm.gamma == "sRGB_g2.4_s12.92") {
- gammaStr = std::wstring(L"GammaTRC: sRGB g=2.4 s=12.92");
- } else if (icm.gamma == "BT709_g2.2_s4.5") {
- gammaStr = std::wstring(L"GammaTRC: BT709 g=2.2 s=4.5");
- } else if (icm.gamma == "linear_g1.0") {
- gammaStr = std::wstring(L"GammaTRC: Linear g=1.0");
- } else if (icm.gamma == "standard_g2.2") {
- gammaStr = std::wstring(L"GammaTRC: g=2.2");
- } else if (icm.gamma == "standard_g1.8") {
- gammaStr = std::wstring(L"GammaTRC: g=1.8");
- }
-
- cmsMLUsetWide(mlu, "en", "US", gammaStr.c_str());
- } else {
- // create description with gamma + slope + primaries
- std::wostringstream gammaWs;
- gammaWs.precision(2);
- gammaWs << "Manual GammaTRC: g=" <<(float)icm.gampos << " s=" <<(float)icm.slpos;
-
- cmsMLUsetWide(mlu, "en", "US", gammaWs.str().c_str());
- }
-
- cmsWriteTag(outputProfile, cmsSigProfileDescriptionTag, mlu);//desc changed
-
- /*
- cmsMLUsetWide(mlu, "en", "US", L"General Public License - AdobeRGB compatible");//adapt to profil
- cmsWriteTag(outputProfile, cmsSigCopyrightTag, mlu);
-
- cmsMLUsetWide(mlu, "en", "US", L"RawTherapee");
- cmsWriteTag(outputProfile, cmsSigDeviceMfgDescTag, mlu);
-
- cmsMLUsetWide(mlu, "en", "US", L"RTMedium"); //adapt to profil
- cmsWriteTag(outputProfile, cmsSigDeviceModelDescTag, mlu);
-
- */
-
- cmsMLUfree(mlu);
- }
-
- // Calculate output profile's rTRC gTRC bTRC
- cmsToneCurve* GammaTRC = cmsBuildParametricToneCurve(nullptr, 5, Parameters);
- cmsWriteTag(outputProfile, cmsSigRedTRCTag,(void*)GammaTRC );
- cmsWriteTag(outputProfile, cmsSigGreenTRCTag,(void*)GammaTRC );
- cmsWriteTag(outputProfile, cmsSigBlueTRCTag,(void*)GammaTRC );
-
- if (GammaTRC) {
- cmsFreeToneCurve(GammaTRC);
- }
-
- return outputProfile;
-}
diff --git a/rtengine/iccstore.h b/rtengine/iccstore.h
index c23ecd112..6b57fd072 100644
--- a/rtengine/iccstore.h
+++ b/rtengine/iccstore.h
@@ -96,13 +96,9 @@ public:
std::uint8_t getProofIntents(const Glib::ustring& name) const;
/*static*/ std::vector getWorkingProfiles();
- static std::vector getGamma();
- static void getGammaArray(const procparams::ColorManagementParams& icm, GammaValues& ga);
static cmsHPROFILE makeStdGammaProfile(cmsHPROFILE iprof);
static cmsHPROFILE createFromMatrix(const double matrix[3][3], bool gamma = false, const Glib::ustring& name = Glib::ustring());
- static cmsHPROFILE createGammaProfile(const procparams::ColorManagementParams& icm, GammaValues& ga);
- static cmsHPROFILE createCustomGammaOutputProfile(const procparams::ColorManagementParams& icm, GammaValues& ga);
private:
class Implementation;
diff --git a/rtengine/image16.cc b/rtengine/image16.cc
index 68dd4bb40..8b9b4fbc6 100644
--- a/rtengine/image16.cc
+++ b/rtengine/image16.cc
@@ -25,7 +25,7 @@
namespace
{
-void getScanline8 (const uint16_t *red, const uint16_t *green, const uint16_t *blue, int width, unsigned char* buffer)
+void getScanline8(const uint16_t *red, const uint16_t *green, const uint16_t *blue, int width, unsigned char* buffer)
{
for (int i = 0, ix = 0; i < width; i++) {
buffer[ix++] = rtengine::uint16ToUint8Rounded(red[i]);
@@ -34,7 +34,7 @@ void getScanline8 (const uint16_t *red, const uint16_t *green, const uint16_t *b
}
}
-void getScanline16 (const uint16_t *red, const uint16_t *green, const uint16_t *blue, int width, unsigned short* buffer)
+void getScanline16(const uint16_t *red, const uint16_t *green, const uint16_t *blue, int width, unsigned short* buffer)
{
for (int i = 0, ix = 0; i < width; i++) {
buffer[ix++] = red[i];
@@ -47,20 +47,20 @@ void getScanline16 (const uint16_t *red, const uint16_t *green, const uint16_t *
using namespace rtengine;
-Image16::Image16 ()
+Image16::Image16()
{
}
-Image16::Image16 (int w, int h)
+Image16::Image16(int w, int h)
{
- allocate (w, h);
+ allocate(w, h);
}
-Image16::~Image16 ()
+Image16::~Image16()
{
}
-void Image16::getScanline (int row, unsigned char* buffer, int bps)
+void Image16::getScanline(int row, unsigned char* buffer, int bps)
{
if (data == nullptr) {
@@ -68,9 +68,9 @@ void Image16::getScanline (int row, unsigned char* buffer, int bps)
}
if (bps == 16) {
- getScanline16 (r(row), g(row), b(row), width, (unsigned short*)buffer);
+ getScanline16(r(row), g(row), b(row), width, (unsigned short*)buffer);
} else if (bps == 8) {
- getScanline8 (r(row), g(row), b(row), width, buffer);
+ getScanline8(r(row), g(row), b(row), width, buffer);
}
}
@@ -78,7 +78,7 @@ void Image16::getScanline (int row, unsigned char* buffer, int bps)
* void Image16::setScanline (int row, unsigned char* buffer, int bps, int minValue[3], int maxValue[3]);
* has not been implemented yet, because as of now, this method is called for IIOSF_FLOATxx sample format only
*/
-void Image16::setScanline (int row, unsigned char* buffer, int bps, unsigned int numSamples, float *minValue, float *maxValue)
+void Image16::setScanline(int row, unsigned char* buffer, int bps, unsigned int numSamples, float *minValue, float *maxValue)
{
if (data == nullptr) {
@@ -92,7 +92,7 @@ void Image16::setScanline (int row, unsigned char* buffer, int bps, unsigned int
case (IIOSF_UNSIGNED_CHAR): {
int ix = 0;
- if(numSamples == 1) {
+ if (numSamples == 1) {
for (int i = 0; i < width; ++i) {
r(row, i) = g(row, i) = b(row, i) = static_cast(buffer[ix++]) * 257;
}
@@ -103,6 +103,7 @@ void Image16::setScanline (int row, unsigned char* buffer, int bps, unsigned int
b(row, i) = static_cast(buffer[ix++]) * 257;
}
}
+
break;
}
@@ -130,22 +131,23 @@ void Image16::setScanline (int row, unsigned char* buffer, int bps, unsigned int
*/
}
-Image16* Image16::copy ()
+Image16* Image16::copy()
{
- Image16* cp = new Image16 (width, height);
+ Image16* cp = new Image16(width, height);
copyData(cp);
return cp;
}
-void Image16::getStdImage (ColorTemp ctemp, int tran, Imagefloat* image, PreviewProps pp, bool first, procparams::ToneCurveParams hrp)
+void Image16::getStdImage(ColorTemp ctemp, int tran, Imagefloat* image, PreviewProps pp, bool first, procparams::ToneCurveParams hrp)
{
// compute channel multipliers
float rm = 1.f, gm = 1.f, bm = 1.f;
+
if (ctemp.getTemp() >= 0) {
double drm, dgm, dbm;
- ctemp.getMultipliers (drm, dgm, dbm);
+ ctemp.getMultipliers(drm, dgm, dbm);
rm = drm;
gm = dgm;
bm = dbm;
@@ -161,7 +163,7 @@ void Image16::getStdImage (ColorTemp ctemp, int tran, Imagefloat* image, Preview
int sx1, sy1, sx2, sy2;
- transform (pp, tran, sx1, sy1, sx2, sy2);
+ transform(pp, tran, sx1, sy1, sx2, sy2);
int imwidth = image->getWidth(); // Destination image
int imheight = image->getHeight(); // Destination image
@@ -271,25 +273,22 @@ void Image16::getStdImage (ColorTemp ctemp, int tran, Imagefloat* image, Preview
}
}
- if (mtran == TR_NONE)
+ if (mtran == TR_NONE)
for (int dst_x = 0, src_x = sx1; dst_x < imwidth; dst_x++, src_x += skip) {
image->r(iy, dst_x) = lineR[dst_x];
image->g(iy, dst_x) = lineG[dst_x];
image->b(iy, dst_x) = lineB[dst_x];
- }
- else if (mtran == TR_R180)
+ } else if (mtran == TR_R180)
for (int dst_x = 0; dst_x < imwidth; dst_x++) {
image->r(imheight - 1 - iy, imwidth - 1 - dst_x) = lineR[dst_x];
image->g(imheight - 1 - iy, imwidth - 1 - dst_x) = lineG[dst_x];
image->b(imheight - 1 - iy, imwidth - 1 - dst_x) = lineB[dst_x];
- }
- else if (mtran == TR_R90)
+ } else if (mtran == TR_R90)
for (int dst_x = 0, src_x = sx1; dst_x < imwidth; dst_x++, src_x += skip) {
image->r(dst_x, imheight - 1 - iy) = lineR[dst_x];
image->g(dst_x, imheight - 1 - iy) = lineG[dst_x];
image->b(dst_x, imheight - 1 - iy) = lineB[dst_x];
- }
- else if (mtran == TR_R270)
+ } else if (mtran == TR_R270)
for (int dst_x = 0, src_x = sx1; dst_x < imwidth; dst_x++, src_x += skip) {
image->r(imwidth - 1 - dst_x, iy) = lineR[dst_x];
image->g(imwidth - 1 - dst_x, iy) = lineG[dst_x];
@@ -334,6 +333,48 @@ Image16::tofloat()
return imgfloat;
}
+// Parallized transformation; create transform with cmsFLAGS_NOCACHE!
+void Image16::ExecCMSTransform(cmsHTRANSFORM hTransform)
+{
+ //cmsDoTransform(hTransform, data, data, planestride);
+
+ // LittleCMS cannot parallelize planar setups -- Hombre: LCMS2.4 can! But it we use this new feature, memory allocation have to be modified too
+ // so build temporary buffers to allow multi processor execution
+#ifdef _OPENMP
+ #pragma omp parallel
+#endif
+ {
+ AlignedBuffer buffer(width * 3);
+
+#ifdef _OPENMP
+ #pragma omp for schedule(static)
+#endif
+
+ for (int y = 0; y < height; y++)
+ {
+ unsigned short *p = buffer.data, *pR = r(y), *pG = g(y), *pB = b(y);
+
+ for (int x = 0; x < width; x++) {
+ *(p++) = *(pR++);
+ *(p++) = *(pG++);
+ *(p++) = *(pB++);
+ }
+
+ cmsDoTransform(hTransform, buffer.data, buffer.data, width);
+
+ p = buffer.data;
+ pR = r(y);
+ pG = g(y);
+ pB = b(y);
+
+ for (int x = 0; x < width; x++) {
+ *(pR++) = *(p++);
+ *(pG++) = *(p++);
+ *(pB++) = *(p++);
+ }
+ } // End of parallelization
+ }
+}
// // Parallelized transformation; create transform with cmsFLAGS_NOCACHE!
// void Image16::ExecCMSTransform(cmsHTRANSFORM hTransform, const LabImage &labImage, int cx, int cy)
diff --git a/rtengine/image16.h b/rtengine/image16.h
index af5642638..add1d6f09 100644
--- a/rtengine/image16.h
+++ b/rtengine/image16.h
@@ -36,65 +36,66 @@ class Image16 : public IImage16, public ImageIO
public:
- Image16 ();
- Image16 (int width, int height);
- ~Image16 ();
+ Image16();
+ Image16(int width, int height);
+ ~Image16();
- Image16* copy ();
+ Image16* copy();
Image8* to8();
Imagefloat* tofloat();
- virtual void getStdImage (ColorTemp ctemp, int tran, Imagefloat* image, PreviewProps pp, bool first, procparams::ToneCurveParams hrp);
+ virtual void getStdImage(ColorTemp ctemp, int tran, Imagefloat* image, PreviewProps pp, bool first, procparams::ToneCurveParams hrp);
- virtual const char* getType () const
+ virtual const char* getType() const
{
return sImage16;
}
- virtual int getBPS ()
+ virtual int getBPS()
{
return 8 * sizeof(unsigned short);
}
- virtual void getScanline (int row, unsigned char* buffer, int bps);
- virtual void setScanline (int row, unsigned char* buffer, int bps, unsigned int numSamples, float *minValue = nullptr, float *maxValue = nullptr);
+ virtual void getScanline(int row, unsigned char* buffer, int bps);
+ virtual void setScanline(int row, unsigned char* buffer, int bps, unsigned int numSamples, float *minValue = nullptr, float *maxValue = nullptr);
// functions inherited from IImage16:
- virtual MyMutex& getMutex ()
+ virtual MyMutex& getMutex()
{
- return mutex ();
+ return mutex();
}
- virtual cmsHPROFILE getProfile ()
+ virtual cmsHPROFILE getProfile()
{
- return getEmbeddedProfile ();
+ return getEmbeddedProfile();
}
- virtual int getBitsPerPixel ()
+ virtual int getBitsPerPixel()
{
return 8 * sizeof(unsigned short);
}
- virtual int saveToFile (Glib::ustring fname)
+ virtual int saveToFile(Glib::ustring fname)
{
- return save (fname);
+ return save(fname);
}
- virtual int saveAsPNG (Glib::ustring fname, int bps = -1)
+ virtual int saveAsPNG(Glib::ustring fname, int bps = -1)
{
- return savePNG (fname, bps);
+ return savePNG(fname, bps);
}
- virtual int saveAsJPEG (Glib::ustring fname, int quality = 100, int subSamp = 3)
+ virtual int saveAsJPEG(Glib::ustring fname, int quality = 100, int subSamp = 3)
{
- return saveJPEG (fname, quality, subSamp);
+ return saveJPEG(fname, quality, subSamp);
}
- virtual int saveAsTIFF (Glib::ustring fname, int bps = -1, bool uncompressed = false)
+ virtual int saveAsTIFF(Glib::ustring fname, int bps = -1, bool uncompressed = false)
{
- return saveTIFF (fname, bps, uncompressed);
+ return saveTIFF(fname, bps, uncompressed);
}
- virtual void setSaveProgressListener (ProgressListener* pl)
+ virtual void setSaveProgressListener(ProgressListener* pl)
{
- setProgressListener (pl);
+ setProgressListener(pl);
}
- virtual void free ()
+ virtual void free()
{
delete this;
}
+ void ExecCMSTransform(cmsHTRANSFORM hTransform);
/* void ExecCMSTransform(cmsHTRANSFORM hTransform, const LabImage &labImage, int cx, int cy); */
};
diff --git a/rtengine/imagefloat.cc b/rtengine/imagefloat.cc
index e79678194..277ed32ce 100644
--- a/rtengine/imagefloat.cc
+++ b/rtengine/imagefloat.cc
@@ -467,7 +467,7 @@ void Imagefloat::calcCroppedHistogram(const ProcParams ¶ms, float scale, LUT
hist.clear();
// Set up factors to calc the lightness
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.workingProfile);
float facRed = wprof[1][0];
float facGreen = wprof[1][1];
@@ -508,6 +508,52 @@ void Imagefloat::calcCroppedHistogram(const ProcParams ¶ms, float scale, LUT
}
+// Parallelized transformation; create transform with cmsFLAGS_NOCACHE!
+void Imagefloat::ExecCMSTransform2(cmsHTRANSFORM hTransform)
+{
+
+ // LittleCMS cannot parallelize planar setups -- Hombre: LCMS2.4 can! But it we use this new feature, memory allocation
+ // have to be modified too to build temporary buffers that allow multi processor execution
+#ifdef _OPENMP
+ #pragma omp parallel
+#endif
+ {
+ AlignedBuffer pBuf(width * 3);
+
+#ifdef _OPENMP
+ #pragma omp for schedule(static)
+#endif
+
+ for (int y = 0; y < height; y++)
+ {
+ float *p = pBuf.data, *pR = r(y), *pG = g(y), *pB = b(y);
+
+ for (int x = 0; x < width; x++) {
+ *(p++) = *(pR++)/ 65535.f;
+ *(p++) = *(pG++)/ 65535.f;
+ *(p++) = *(pB++)/ 65535.f;
+
+ }
+
+ cmsDoTransform (hTransform, pBuf.data, pBuf.data, width);
+
+ p = pBuf.data;
+ pR = r(y);
+ pG = g(y);
+ pB = b(y);
+
+ for (int x = 0; x < width; x++) {
+ *(pR++) = *(p++);
+ *(pG++) = *(p++);
+ *(pB++) = *(p++);
+ }
+ } // End of parallelization
+ }
+}
+
+
+
+
// Parallelized transformation; create transform with cmsFLAGS_NOCACHE!
void Imagefloat::ExecCMSTransform(cmsHTRANSFORM hTransform)
{
@@ -532,6 +578,7 @@ void Imagefloat::ExecCMSTransform(cmsHTRANSFORM hTransform)
*(p++) = *(pR++);
*(p++) = *(pG++);
*(p++) = *(pB++);
+
}
cmsDoTransform (hTransform, pBuf.data, pBuf.data, width);
diff --git a/rtengine/imagefloat.h b/rtengine/imagefloat.h
index 5246a2f6e..d48e51cee 100644
--- a/rtengine/imagefloat.h
+++ b/rtengine/imagefloat.h
@@ -104,6 +104,7 @@ public:
void normalizeFloatTo1();
void normalizeFloatTo65535();
void calcCroppedHistogram(const ProcParams ¶ms, float scale, LUTu & hist);
+ void ExecCMSTransform2(cmsHTRANSFORM hTransform);
void ExecCMSTransform(cmsHTRANSFORM hTransform);
void ExecCMSTransform(cmsHTRANSFORM hTransform, const LabImage &labImage, int cx, int cy);
diff --git a/rtengine/improccoordinator.cc b/rtengine/improccoordinator.cc
index 2ec2df5fc..01e2226f5 100644
--- a/rtengine/improccoordinator.cc
+++ b/rtengine/improccoordinator.cc
@@ -24,6 +24,11 @@
#include "colortemp.h"
#include "improcfun.h"
#include "iccstore.h"
+#include
+#include
+#include
+#include "color.h"
+
#ifdef _OPENMP
#include
#endif
@@ -32,49 +37,49 @@ namespace rtengine
extern const Settings* settings;
-ImProcCoordinator::ImProcCoordinator ()
- : orig_prev (nullptr), oprevi (nullptr), oprevl (nullptr), nprevl (nullptr), fattal_11_dcrop_cache(nullptr), previmg (nullptr), workimg (nullptr),
+ImProcCoordinator::ImProcCoordinator()
+ : orig_prev(nullptr), oprevi(nullptr), oprevl(nullptr), nprevl(nullptr), fattal_11_dcrop_cache(nullptr), previmg(nullptr), workimg(nullptr),
ncie (nullptr), imgsrc (nullptr), lastAwbEqual (0.), lastAwbTempBias (0.0), ipf (¶ms, true), monitorIntent (RI_RELATIVE),
- softProof (false), gamutCheck (false), sharpMask(false), scale (10), highDetailPreprocessComputed (false), highDetailRawComputed (false),
- allocated (false), bwAutoR (-9000.f), bwAutoG (-9000.f), bwAutoB (-9000.f), CAMMean (NAN),
+ softProof(false), gamutCheck(false), sharpMask(false), scale(10), highDetailPreprocessComputed(false), highDetailRawComputed(false),
+ allocated(false), bwAutoR(-9000.f), bwAutoG(-9000.f), bwAutoB(-9000.f), CAMMean(NAN),
- hltonecurve (65536),
- shtonecurve (65536),
- tonecurve (65536, 0), //,1);
- lumacurve (32770, 0), // lumacurve[32768] and lumacurve[32769] will be set to 32768 and 32769 later to allow linear interpolation
- chroma_acurve (65536, 0),
- chroma_bcurve (65536, 0),
- satcurve (65536, 0),
- lhskcurve (65536, 0),
- clcurve (65536, 0),
- conversionBuffer (1, 1),
- wavclCurve (65536, 0),
- clToningcurve (65536, 0),
- cl2Toningcurve (65536, 0),
- Noisecurve (65536, 0),
- NoiseCCcurve (65536, 0),
- vhist16 (65536), vhist16bw (65536),
- lhist16CAM (65536),
- lhist16CCAM (65536),
+ hltonecurve(65536),
+ shtonecurve(65536),
+ tonecurve(65536, 0), //,1);
+ lumacurve(32770, 0), // lumacurve[32768] and lumacurve[32769] will be set to 32768 and 32769 later to allow linear interpolation
+ chroma_acurve(65536, 0),
+ chroma_bcurve(65536, 0),
+ satcurve(65536, 0),
+ lhskcurve(65536, 0),
+ clcurve(65536, 0),
+ conversionBuffer(1, 1),
+ wavclCurve(65536, 0),
+ clToningcurve(65536, 0),
+ cl2Toningcurve(65536, 0),
+ Noisecurve(65536, 0),
+ NoiseCCcurve(65536, 0),
+ vhist16(65536), vhist16bw(65536),
+ lhist16CAM(65536),
+ lhist16CCAM(65536),
lhist16RETI(),
- lhist16LClad (65536),
- histRed (256), histRedRaw (256),
- histGreen (256), histGreenRaw (256),
- histBlue (256), histBlueRaw (256),
- histLuma (256),
- histToneCurve (256),
- histToneCurveBW (256),
- histLCurve (256),
- histCCurve (256),
- histLLCurve (256),
+ lhist16LClad(65536),
+ histRed(256), histRedRaw(256),
+ histGreen(256), histGreenRaw(256),
+ histBlue(256), histBlueRaw(256),
+ histLuma(256),
+ histToneCurve(256),
+ histToneCurveBW(256),
+ histLCurve(256),
+ histCCurve(256),
+ histLLCurve(256),
- histLCAM (256),
- histCCAM (256),
- histClad (256),
- bcabhist (256),
- histChroma (256),
+ histLCAM(256),
+ histCCAM(256),
+ histClad(256),
+ bcabhist(256),
+ histChroma(256),
- histLRETI (256),
+ histLRETI(256),
CAMBrightCurveJ(), CAMBrightCurveQ(),
@@ -82,35 +87,36 @@ ImProcCoordinator::ImProcCoordinator ()
gCurve(),
bCurve(),
ctColorCurve(),
- rcurvehist (256), rcurvehistCropped (256), rbeforehist (256),
- gcurvehist (256), gcurvehistCropped (256), gbeforehist (256),
- bcurvehist (256), bcurvehistCropped (256), bbeforehist (256),
- fw (0), fh (0), tr (0),
- fullw (1), fullh (1),
- pW (-1), pH (-1),
- plistener (nullptr), imageListener (nullptr), aeListener (nullptr), acListener (nullptr), abwListener (nullptr), awbListener (nullptr), frameCountListener (nullptr), imageTypeListener (nullptr), actListener (nullptr), adnListener (nullptr), awavListener (nullptr), dehaListener (nullptr), hListener (nullptr),
- resultValid (false), lastOutputProfile ("BADFOOD"), lastOutputIntent (RI__COUNT), lastOutputBPC (false), thread (nullptr), changeSinceLast (0), updaterRunning (false), destroying (false), utili (false), autili (false),
- butili (false), ccutili (false), cclutili (false), clcutili (false), opautili (false), wavcontlutili (false), colourToningSatLimit (0.f), colourToningSatLimitOpacity (0.f), highQualityComputed (false)
+ rcurvehist(256), rcurvehistCropped(256), rbeforehist(256),
+ gcurvehist(256), gcurvehistCropped(256), gbeforehist(256),
+ bcurvehist(256), bcurvehistCropped(256), bbeforehist(256),
+ fw(0), fh(0), tr(0),
+ fullw(1), fullh(1),
+ pW(-1), pH(-1),
+ plistener(nullptr), imageListener(nullptr), aeListener(nullptr), acListener(nullptr), abwListener(nullptr), awbListener(nullptr), frameCountListener(nullptr), imageTypeListener(nullptr), actListener(nullptr), adnListener(nullptr), awavListener(nullptr), dehaListener(nullptr), hListener(nullptr),
+ resultValid(false), lastOutputProfile("BADFOOD"), lastOutputIntent(RI__COUNT), lastOutputBPC(false), thread(nullptr), changeSinceLast(0), updaterRunning(false), destroying(false), utili(false), autili(false),
+ butili(false), ccutili(false), cclutili(false), clcutili(false), opautili(false), wavcontlutili(false), colourToningSatLimit(0.f), colourToningSatLimitOpacity(0.f), highQualityComputed(false)
{}
-void ImProcCoordinator::assign (ImageSource* imgsrc)
+void ImProcCoordinator::assign(ImageSource* imgsrc)
{
this->imgsrc = imgsrc;
}
-ImProcCoordinator::~ImProcCoordinator ()
+ImProcCoordinator::~ImProcCoordinator()
{
destroying = true;
- updaterThreadStart.lock ();
+ updaterThreadStart.lock();
if (updaterRunning && thread) {
- thread->join ();
+ thread->join();
}
mProcessing.lock();
mProcessing.unlock();
- freeAll ();
+ freeAll();
+
if (fattal_11_dcrop_cache) {
delete fattal_11_dcrop_cache;
fattal_11_dcrop_cache = nullptr;
@@ -122,23 +128,23 @@ ImProcCoordinator::~ImProcCoordinator ()
delete toDel[i];
}
- imgsrc->decreaseRef ();
- updaterThreadStart.unlock ();
+ imgsrc->decreaseRef();
+ updaterThreadStart.unlock();
}
-DetailedCrop* ImProcCoordinator::createCrop (::EditDataProvider *editDataProvider, bool isDetailWindow)
+DetailedCrop* ImProcCoordinator::createCrop(::EditDataProvider *editDataProvider, bool isDetailWindow)
{
- return new Crop (this, editDataProvider, isDetailWindow);
+ return new Crop(this, editDataProvider, isDetailWindow);
}
// todo: bitmask containing desired actions, taken from changesSinceLast
// cropCall: calling crop, used to prevent self-updates ...doesn't seem to be used
-void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
+void ImProcCoordinator::updatePreviewImage(int todo, Crop* cropCall)
{
- MyMutex::MyLock processingLock (mProcessing);
+ MyMutex::MyLock processingLock(mProcessing);
int numofphases = 14;
int readyphase = 0;
@@ -159,7 +165,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
// Check if any detail crops need high detail. If not, take a fast path short cut
if (!highDetailNeeded) {
for (size_t i = 0; i < crops.size(); i++)
- if (crops[i]->get_skip() == 1 ) { // skip=1 -> full resolution
+ if (crops[i]->get_skip() == 1) { // skip=1 -> full resolution
highDetailNeeded = true;
break;
}
@@ -169,7 +175,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
ColorManagementParams cmp = params.icm;
LCurveParams lcur = params.labCurve;
- if ( !highDetailNeeded ) {
+ if (!highDetailNeeded) {
// if below 100% magnification, take a fast path
if (rp.bayersensor.method != RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::NONE) && rp.bayersensor.method != RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::NONE)) {
rp.bayersensor.method = RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::FAST);
@@ -186,18 +192,18 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
//rp.deadPixelFilter = rp.hotPixelFilter = false;
}
- progress ("Applying white balance, color correction & sRGB conversion...", 100 * readyphase / numofphases);
+ progress("Applying white balance, color correction & sRGB conversion...", 100 * readyphase / numofphases);
if (frameCountListener) {
- frameCountListener->FrameCountChanged (imgsrc->getFrameCount(), params.raw.bayersensor.imageNum);
+ frameCountListener->FrameCountChanged(imgsrc->getFrameCount(), params.raw.bayersensor.imageNum);
}
// raw auto CA is bypassed if no high detail is needed, so we have to compute it when high detail is needed
- if ( (todo & M_PREPROC) || (!highDetailPreprocessComputed && highDetailNeeded)) {
- imgsrc->setCurrentFrame (params.raw.bayersensor.imageNum);
+ if ((todo & M_PREPROC) || (!highDetailPreprocessComputed && highDetailNeeded)) {
+ imgsrc->setCurrentFrame(params.raw.bayersensor.imageNum);
- imgsrc->preprocess ( rp, params.lensProf, params.coarse );
- imgsrc->getRAWHistogram ( histRedRaw, histGreenRaw, histBlueRaw );
+ imgsrc->preprocess(rp, params.lensProf, params.coarse);
+ imgsrc->getRAWHistogram(histRedRaw, histGreenRaw, histBlueRaw);
highDetailPreprocessComputed = highDetailNeeded;
}
@@ -215,19 +221,19 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
// If high detail (=100%) is newly selected, do a demosaic update, since the last was just with FAST
if (imageTypeListener) {
- imageTypeListener->imageTypeChanged (imgsrc->isRAW(), imgsrc->getSensorType() == ST_BAYER, imgsrc->getSensorType() == ST_FUJI_XTRANS, imgsrc->isMono());
+ imageTypeListener->imageTypeChanged(imgsrc->isRAW(), imgsrc->getSensorType() == ST_BAYER, imgsrc->getSensorType() == ST_FUJI_XTRANS, imgsrc->isMono());
}
- if ( (todo & M_RAW)
+ if ((todo & M_RAW)
|| (!highDetailRawComputed && highDetailNeeded)
- || ( params.toneCurve.hrenabled && params.toneCurve.method != "Color" && imgsrc->isRGBSourceModified())
+ || (params.toneCurve.hrenabled && params.toneCurve.method != "Color" && imgsrc->isRGBSourceModified())
|| (!params.toneCurve.hrenabled && params.toneCurve.method == "Color" && imgsrc->isRGBSourceModified())) {
if (settings->verbose) {
if (imgsrc->getSensorType() == ST_BAYER) {
- printf ("Demosaic Bayer image n.%d using method: %s\n", rp.bayersensor.imageNum + 1, rp.bayersensor.method.c_str());
+ printf("Demosaic Bayer image n.%d using method: %s\n", rp.bayersensor.imageNum + 1, rp.bayersensor.method.c_str());
} else if (imgsrc->getSensorType() == ST_FUJI_XTRANS) {
- printf ("Demosaic X-Trans image with using method: %s\n", rp.xtranssensor.method.c_str());
+ printf("Demosaic X-Trans image with using method: %s\n", rp.xtranssensor.method.c_str());
}
}
if(imgsrc->getSensorType() == ST_BAYER) {
@@ -239,7 +245,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
bool autoContrast = false;
double contrastThreshold = 0.f;
- imgsrc->demosaic (rp, autoContrast, contrastThreshold); //enabled demosaic
+ imgsrc->demosaic(rp, autoContrast, contrastThreshold); //enabled demosaic
// if a demosaic happened we should also call getimage later, so we need to set the M_INIT flag
todo |= M_INIT;
@@ -251,10 +257,10 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
if (params.retinex.enabled) {
- lhist16RETI (32768);
+ lhist16RETI(32768);
lhist16RETI.clear();
- imgsrc->retinexPrepareBuffers (params.icm, params.retinex, conversionBuffer, lhist16RETI);
+ imgsrc->retinexPrepareBuffers(params.icm, params.retinex, conversionBuffer, lhist16RETI);
}
}
@@ -262,47 +268,47 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
bool dehacontlutili = false;
bool mapcontlutili = false;
bool useHsl = false;
- LUTf cdcurve (65536, 0);
- LUTf mapcurve (65536, 0);
+ LUTf cdcurve(65536, 0);
+ LUTf mapcurve(65536, 0);
- imgsrc->retinexPrepareCurves (params.retinex, cdcurve, mapcurve, dehatransmissionCurve, dehagaintransmissionCurve, dehacontlutili, mapcontlutili, useHsl, lhist16RETI, histLRETI);
+ imgsrc->retinexPrepareCurves(params.retinex, cdcurve, mapcurve, dehatransmissionCurve, dehagaintransmissionCurve, dehacontlutili, mapcontlutili, useHsl, lhist16RETI, histLRETI);
float minCD, maxCD, mini, maxi, Tmean, Tsigma, Tmin, Tmax;
- imgsrc->retinex ( params.icm, params.retinex, params.toneCurve, cdcurve, mapcurve, dehatransmissionCurve, dehagaintransmissionCurve, conversionBuffer, dehacontlutili, mapcontlutili, useHsl, minCD, maxCD, mini, maxi, Tmean, Tsigma, Tmin, Tmax, histLRETI); //enabled Retinex
+ imgsrc->retinex(params.icm, params.retinex, params.toneCurve, cdcurve, mapcurve, dehatransmissionCurve, dehagaintransmissionCurve, conversionBuffer, dehacontlutili, mapcontlutili, useHsl, minCD, maxCD, mini, maxi, Tmean, Tsigma, Tmin, Tmax, histLRETI); //enabled Retinex
if (dehaListener) {
- dehaListener->minmaxChanged (maxCD, minCD, mini, maxi, Tmean, Tsigma, Tmin, Tmax);
+ dehaListener->minmaxChanged(maxCD, minCD, mini, maxi, Tmean, Tsigma, Tmin, Tmax);
}
}
if (todo & (M_INIT | M_LINDENOISE | M_HDR)) {
- MyMutex::MyLock initLock (minit); // Also used in crop window
+ MyMutex::MyLock initLock(minit); // Also used in crop window
- imgsrc->HLRecovery_Global ( params.toneCurve); // this handles Color HLRecovery
+ imgsrc->HLRecovery_Global(params.toneCurve); // this handles Color HLRecovery
if (settings->verbose) {
- printf ("Applying white balance, color correction & sRBG conversion...\n");
+ printf("Applying white balance, color correction & sRBG conversion...\n");
}
- currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
+ currWB = ColorTemp(params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
if (!params.wb.enabled) {
currWB = ColorTemp();
} else if (params.wb.method == "Camera") {
- currWB = imgsrc->getWB ();
+ currWB = imgsrc->getWB();
} else if (params.wb.method == "Auto") {
if (lastAwbEqual != params.wb.equal || lastAwbTempBias != params.wb.tempBias) {
double rm, gm, bm;
- imgsrc->getAutoWBMultipliers (rm, gm, bm);
+ imgsrc->getAutoWBMultipliers(rm, gm, bm);
if (rm != -1.) {
- autoWB.update (rm, gm, bm, params.wb.equal, params.wb.tempBias);
+ autoWB.update(rm, gm, bm, params.wb.equal, params.wb.tempBias);
lastAwbEqual = params.wb.equal;
lastAwbTempBias = params.wb.tempBias;
} else {
lastAwbEqual = -1.;
lastAwbTempBias = 0.0;
- autoWB.useDefaults (params.wb.equal);
+ autoWB.useDefaults(params.wb.equal);
}
//double rr,gg,bb;
@@ -313,25 +319,49 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
if (params.wb.enabled) {
- params.wb.temperature = currWB.getTemp ();
- params.wb.green = currWB.getGreen ();
+ params.wb.temperature = currWB.getTemp();
+ params.wb.green = currWB.getGreen();
}
if (params.wb.method == "Auto" && awbListener && params.wb.enabled) {
- awbListener->WBChanged (params.wb.temperature, params.wb.green);
+ awbListener->WBChanged(params.wb.temperature, params.wb.green);
}
- int tr = getCoarseBitMask (params.coarse);
+ /*
+ GammaValues g_a;
+ double pwr = 1.0 / params.icm.gampos;
+ double ts = params.icm.slpos;
- imgsrc->getFullSize (fw, fh, tr);
+
+ int mode = 0;
+ Color::calcGamma(pwr, ts, mode, g_a); // call to calcGamma with selected gamma and slope
+ printf("ga[0]=%f ga[1]=%f ga[2]=%f ga[3]=%f ga[4]=%f\n", g_a[0],g_a[1],g_a[2],g_a[3],g_a[4]);
+
+ Glib::ustring datal;
+ datal = "lutsrgb.txt";
+ ofstream fou(datal, ios::out | ios::trunc);
+
+ for(int i=0; i < 212; i++) {
+ //printf("igamma2=%i\n", (int) 65535.f*Color::igamma2(i/212.0));
+ float gam = Color::igamma2(i/211.0);
+ int lutga = nearbyint(65535.f* gam);
+ // fou << 65535*(int)Color::igamma2(i/212.0) << endl;
+ fou << i << " " << lutga << endl;
+
+ }
+ fou.close();
+ */
+ int tr = getCoarseBitMask(params.coarse);
+
+ imgsrc->getFullSize(fw, fh, tr);
// Will (re)allocate the preview's buffers
- setScale (scale);
- PreviewProps pp (0, 0, fw, fh, scale);
+ setScale(scale);
+ PreviewProps pp(0, 0, fw, fh, scale);
// Tells to the ImProcFunctions' tools what is the preview scale, which may lead to some simplifications
- ipf.setScale (scale);
+ ipf.setScale(scale);
- imgsrc->getImage (currWB, tr, orig_prev, pp, params.toneCurve, params.raw);
+ imgsrc->getImage(currWB, tr, orig_prev, pp, params.toneCurve, params.raw);
denoiseInfoStore.valid = false;
//ColorTemp::CAT02 (orig_prev, ¶ms) ;
// printf("orig_prevW=%d\n scale=%d",orig_prev->width, scale);
@@ -376,9 +406,9 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
}
*/
- imgsrc->convertColorSpace (orig_prev, params.icm, currWB);
+ imgsrc->convertColorSpace(orig_prev, params.icm, currWB);
- ipf.firstAnalysis (orig_prev, params, vhist16);
+ ipf.firstAnalysis(orig_prev, params, vhist16);
}
readyphase++;
@@ -388,41 +418,44 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
delete fattal_11_dcrop_cache;
fattal_11_dcrop_cache = nullptr;
}
+
ipf.ToneMapFattal02(orig_prev);
+
if (oprevi != orig_prev) {
delete oprevi;
}
}
+
oprevi = orig_prev;
- progress ("Rotate / Distortion...", 100 * readyphase / numofphases);
+ progress("Rotate / Distortion...", 100 * readyphase / numofphases);
// Remove transformation if unneeded
bool needstransform = ipf.needsTransform();
-
- if ((needstransform || ((todo & (M_TRANSFORM | M_RGBCURVE)) && params.dirpyrequalizer.cbdlMethod == "bef" && params.dirpyrequalizer.enabled && !params.colorappearance.enabled)) ) {
+
+ if ((needstransform || ((todo & (M_TRANSFORM | M_RGBCURVE)) && params.dirpyrequalizer.cbdlMethod == "bef" && params.dirpyrequalizer.enabled && !params.colorappearance.enabled))) {
assert(oprevi);
Imagefloat *op = oprevi;
- oprevi = new Imagefloat (pW, pH);
+ oprevi = new Imagefloat(pW, pH);
if (needstransform)
- ipf.transform (op, oprevi, 0, 0, 0, 0, pW, pH, fw, fh,
- imgsrc->getMetaData(), imgsrc->getRotateDegree(), false);
+ ipf.transform(op, oprevi, 0, 0, 0, 0, pW, pH, fw, fh,
+ imgsrc->getMetaData(), imgsrc->getRotateDegree(), false);
else {
- op->copyData (oprevi);
+ op->copyData(oprevi);
}
}
if ((todo & (M_TRANSFORM | M_RGBCURVE)) && params.dirpyrequalizer.cbdlMethod == "bef" && params.dirpyrequalizer.enabled && !params.colorappearance.enabled) {
const int W = oprevi->getWidth();
const int H = oprevi->getHeight();
- LabImage labcbdl (W, H);
- ipf.rgb2lab (*oprevi, labcbdl, params.icm.working);
- ipf.dirpyrequalizer (&labcbdl, scale);
- ipf.lab2rgb (labcbdl, *oprevi, params.icm.working);
+ LabImage labcbdl(W, H);
+ ipf.rgb2lab(*oprevi, labcbdl, params.icm.workingProfile);
+ ipf.dirpyrequalizer(&labcbdl, scale);
+ ipf.lab2rgb(labcbdl, *oprevi, params.icm.workingProfile);
}
readyphase++;
- progress ("Preparing shadow/highlight map...", 100 * readyphase / numofphases);
+ progress("Preparing shadow/highlight map...", 100 * readyphase / numofphases);
readyphase++;
@@ -430,14 +463,15 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
if (params.toneCurve.autoexp) {
LUTu aehist;
int aehistcompr;
- imgsrc->getAutoExpHistogram (aehist, aehistcompr);
- ipf.getAutoExp (aehist, aehistcompr, params.toneCurve.clip, params.toneCurve.expcomp,
- params.toneCurve.brightness, params.toneCurve.contrast, params.toneCurve.black, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh);
+ imgsrc->getAutoExpHistogram(aehist, aehistcompr);
+ ipf.getAutoExp(aehist, aehistcompr, params.toneCurve.clip, params.toneCurve.expcomp,
+ params.toneCurve.brightness, params.toneCurve.contrast, params.toneCurve.black, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh);
if (aeListener)
- aeListener->autoExpChanged (params.toneCurve.expcomp, params.toneCurve.brightness, params.toneCurve.contrast,
- params.toneCurve.black, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh, params.toneCurve.hrenabled);
+ aeListener->autoExpChanged(params.toneCurve.expcomp, params.toneCurve.brightness, params.toneCurve.contrast,
+ params.toneCurve.black, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh, params.toneCurve.hrenabled);
}
+
if (params.toneCurve.histmatching) {
if (!params.toneCurve.fromHistMatching) {
imgsrc->getAutoMatchedToneCurve(params.icm, params.toneCurve.curve);
@@ -461,39 +495,81 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
}
- progress ("Exposure curve & CIELAB conversion...", 100 * readyphase / numofphases);
+ progress("Exposure curve & CIELAB conversion...", 100 * readyphase / numofphases);
+
+ if (todo & M_INIT) {
+ if (params.icm.workingTRC == "Custom") { //exec TRC IN free
+ Glib::ustring profile;
+ profile = params.icm.workingProfile;
+
+ if (profile == "sRGB" || profile == "Adobe RGB" || profile == "ProPhoto" || profile == "WideGamut" || profile == "BruceRGB" || profile == "Beta RGB" || profile == "BestRGB" || profile == "Rec2020" || profile == "ACESp0" || profile == "ACESp1") {
+ int cw = oprevi->getWidth();
+ int ch = oprevi->getHeight();
+ // put gamma TRC to 1
+ Imagefloat* readyImg0 = NULL;
+ readyImg0 = ipf.workingtrc(oprevi, cw, ch, -5, params.icm.workingProfile, 2.4, 12.92310);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ oprevi->r(row, col) = (float)readyImg0->r(row, col);
+ oprevi->g(row, col) = (float)readyImg0->g(row, col);
+ oprevi->b(row, col) = (float)readyImg0->b(row, col);
+ }
+ }
+
+ delete readyImg0;
+ //adjust TRC
+ Imagefloat* readyImg = NULL;
+ readyImg = ipf.workingtrc(oprevi, cw, ch, 5, params.icm.workingProfile, params.icm.workingTRCGamma, params.icm.workingTRCSlope);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ oprevi->r(row, col) = (float)readyImg->r(row, col);
+ oprevi->g(row, col) = (float)readyImg->g(row, col);
+ oprevi->b(row, col) = (float)readyImg->b(row, col);
+ }
+ }
+
+ delete readyImg;
+
+ }
+ }
+ }
+
if ((todo & M_RGBCURVE) || (todo & M_CROP)) {
// if (hListener) oprevi->calcCroppedHistogram(params, scale, histCropped);
//complexCurve also calculated pre-curves histogram depending on crop
- CurveFactory::complexCurve (params.toneCurve.expcomp, params.toneCurve.black / 65535.0,
- params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh,
- params.toneCurve.shcompr, params.toneCurve.brightness, params.toneCurve.contrast,
- params.toneCurve.curve, params.toneCurve.curve2,
- vhist16, hltonecurve, shtonecurve, tonecurve, histToneCurve, customToneCurve1, customToneCurve2, 1);
+ CurveFactory::complexCurve(params.toneCurve.expcomp, params.toneCurve.black / 65535.0,
+ params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh,
+ params.toneCurve.shcompr, params.toneCurve.brightness, params.toneCurve.contrast,
+ params.toneCurve.curve, params.toneCurve.curve2,
+ vhist16, hltonecurve, shtonecurve, tonecurve, histToneCurve, customToneCurve1, customToneCurve2, 1);
- CurveFactory::RGBCurve (params.rgbCurves.rcurve, rCurve, 1);
- CurveFactory::RGBCurve (params.rgbCurves.gcurve, gCurve, 1);
- CurveFactory::RGBCurve (params.rgbCurves.bcurve, bCurve, 1);
+ CurveFactory::RGBCurve(params.rgbCurves.rcurve, rCurve, 1);
+ CurveFactory::RGBCurve(params.rgbCurves.gcurve, gCurve, 1);
+ CurveFactory::RGBCurve(params.rgbCurves.bcurve, bCurve, 1);
opautili = false;
if (params.colorToning.enabled) {
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix(params.icm.workingProfile);
double wp[3][3] = {
{wprof[0][0], wprof[0][1], wprof[0][2]},
{wprof[1][0], wprof[1][1], wprof[1][2]},
{wprof[2][0], wprof[2][1], wprof[2][2]}
};
- params.colorToning.getCurves (ctColorCurve, ctOpacityCurve, wp, opautili);
- CurveFactory::curveToning (params.colorToning.clcurve, clToningcurve, scale == 1 ? 1 : 16);
- CurveFactory::curveToning (params.colorToning.cl2curve, cl2Toningcurve, scale == 1 ? 1 : 16);
+ params.colorToning.getCurves(ctColorCurve, ctOpacityCurve, wp, opautili);
+ CurveFactory::curveToning(params.colorToning.clcurve, clToningcurve, scale == 1 ? 1 : 16);
+ CurveFactory::curveToning(params.colorToning.cl2curve, cl2Toningcurve, scale == 1 ? 1 : 16);
}
if (params.blackwhite.enabled) {
- CurveFactory::curveBW (params.blackwhite.beforeCurve, params.blackwhite.afterCurve, vhist16bw, histToneCurveBW, beforeToneCurveBW, afterToneCurveBW, 1);
+ CurveFactory::curveBW(params.blackwhite.beforeCurve, params.blackwhite.afterCurve, vhist16bw, histToneCurveBW, beforeToneCurveBW, afterToneCurveBW, 1);
}
colourToningSatLimit = float (params.colorToning.satProtectionThreshold) / 100.f * 0.7f + 0.3f;
@@ -506,7 +582,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
if (params.colorToning.enabled && params.colorToning.autosat && params.colorToning.method != "LabGrid") { //for colortoning evaluation of saturation settings
float moyS = 0.f;
float eqty = 0.f;
- ipf.moyeqt (oprevi, moyS, eqty);//return image : mean saturation and standard dev of saturation
+ ipf.moyeqt(oprevi, moyS, eqty); //return image : mean saturation and standard dev of saturation
//printf("moy=%f ET=%f\n", moyS,eqty);
float satp = ((moyS + 1.5f * eqty) - 0.3f) / 0.7f; //1.5 sigma ==> 93% pixels with high saturation -0.3 / 0.7 convert to Hombre scale
@@ -530,11 +606,11 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
if (actListener) {
//if(params.blackwhite.enabled) {actListener->autoColorTonChanged(0, satTH, satPR);}
if (params.blackwhite.enabled && params.colorToning.autosat) {
- actListener->autoColorTonChanged (0, satTH, satPR); //hide sliders only if autosat
+ actListener->autoColorTonChanged(0, satTH, satPR); //hide sliders only if autosat
indi = 0;
} else {
if (params.colorToning.autosat) {
- if (params.colorToning.method == "Lab") {
+ if (params.colorToning.method == "Lab") {
indi = 1;
} else if (params.colorToning.method == "RGBCurves") {
indi = 1;
@@ -552,32 +628,32 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
// if it's just crop we just need the histogram, no image updates
- if ( todo & M_RGBCURVE ) {
+ if (todo & M_RGBCURVE) {
//initialize rrm bbm ggm different from zero to avoid black screen in some cases
double rrm = 33.;
double ggm = 33.;
double bbm = 33.;
DCPProfile::ApplyState as;
- DCPProfile *dcpProf = imgsrc->getDCP (params.icm, as);
+ DCPProfile *dcpProf = imgsrc->getDCP(params.icm, as);
ipf.rgbProc (oprevi, oprevl, nullptr, hltonecurve, shtonecurve, tonecurve, params.toneCurve.saturation,
- rCurve, gCurve, bCurve, colourToningSatLimit, colourToningSatLimitOpacity, ctColorCurve, ctOpacityCurve, opautili, clToningcurve, cl2Toningcurve, customToneCurve1, customToneCurve2, beforeToneCurveBW, afterToneCurveBW, rrm, ggm, bbm, bwAutoR, bwAutoG, bwAutoB, params.toneCurve.expcomp, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh, dcpProf, as, histToneCurve);
+ rCurve, gCurve, bCurve, colourToningSatLimit, colourToningSatLimitOpacity, ctColorCurve, ctOpacityCurve, opautili, clToningcurve, cl2Toningcurve, customToneCurve1, customToneCurve2, beforeToneCurveBW, afterToneCurveBW, rrm, ggm, bbm, bwAutoR, bwAutoG, bwAutoB, params.toneCurve.expcomp, params.toneCurve.hlcompr, params.toneCurve.hlcomprthresh, dcpProf, as, histToneCurve);
if (params.blackwhite.enabled && params.blackwhite.autoc && abwListener) {
if (settings->verbose) {
- printf ("ImProcCoordinator / Auto B&W coefs: R=%.2f G=%.2f B=%.2f\n", bwAutoR, bwAutoG, bwAutoB);
+ printf("ImProcCoordinator / Auto B&W coefs: R=%.2f G=%.2f B=%.2f\n", bwAutoR, bwAutoG, bwAutoB);
}
- abwListener->BWChanged ((float) rrm, (float) ggm, (float) bbm);
+ abwListener->BWChanged((float) rrm, (float) ggm, (float) bbm);
}
if (params.colorToning.autosat && actListener) {
if (settings->verbose) {
- printf ("ImProcCoordinator / Auto CT: indi=%d satH=%d satPR=%d\n", indi, (int)colourToningSatLimit, (int) colourToningSatLimitOpacity);
+ printf("ImProcCoordinator / Auto CT: indi=%d satH=%d satPR=%d\n", indi, (int)colourToningSatLimit, (int) colourToningSatLimitOpacity);
}
- actListener->autoColorTonChanged (indi, (int) colourToningSatLimit, (int)colourToningSatLimitOpacity); //change sliders autosat
+ actListener->autoColorTonChanged(indi, (int) colourToningSatLimit, (int)colourToningSatLimitOpacity); //change sliders autosat
}
// correct GUI black and white with value
@@ -585,20 +661,20 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
// compute L channel histogram
int x1, y1, x2, y2;
- params.crop.mapToResized (pW, pH, scale, x1, x2, y1, y2);
+ params.crop.mapToResized(pW, pH, scale, x1, x2, y1, y2);
}
readyphase++;
if (todo & (M_LUMACURVE | M_CROP)) {
- LUTu lhist16 (32768);
+ LUTu lhist16(32768);
lhist16.clear();
#ifdef _OPENMP
- const int numThreads = min (max (pW * pH / (int)lhist16.getSize(), 1), omp_get_max_threads());
+ const int numThreads = min(max(pW * pH / (int)lhist16.getSize(), 1), omp_get_max_threads());
#pragma omp parallel num_threads(numThreads) if(numThreads>1)
#endif
{
- LUTu lhist16thr (lhist16.getSize());
+ LUTu lhist16thr(lhist16.getSize());
lhist16thr.clear();
#ifdef _OPENMP
#pragma omp for nowait
@@ -606,7 +682,7 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
for (int x = 0; x < pH; x++)
for (int y = 0; y < pW; y++) {
- int pos = (int) (oprevl->L[x][y]);
+ int pos = (int)(oprevl->L[x][y]);
lhist16thr[pos]++;
}
@@ -616,31 +692,31 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
lhist16 += lhist16thr;
}
#ifdef _OPENMP
- static_cast (numThreads); // to silence cppcheck warning
+ static_cast(numThreads); // to silence cppcheck warning
#endif
- CurveFactory::complexLCurve (params.labCurve.brightness, params.labCurve.contrast, params.labCurve.lcurve, lhist16, lumacurve, histLCurve, scale == 1 ? 1 : 16, utili);
+ CurveFactory::complexLCurve(params.labCurve.brightness, params.labCurve.contrast, params.labCurve.lcurve, lhist16, lumacurve, histLCurve, scale == 1 ? 1 : 16, utili);
}
if (todo & M_LUMACURVE) {
- CurveFactory::curveCL (clcutili, params.labCurve.clcurve, clcurve, scale == 1 ? 1 : 16);
+ CurveFactory::curveCL(clcutili, params.labCurve.clcurve, clcurve, scale == 1 ? 1 : 16);
- CurveFactory::complexsgnCurve (autili, butili, ccutili, cclutili, params.labCurve.acurve, params.labCurve.bcurve, params.labCurve.cccurve,
- params.labCurve.lccurve, chroma_acurve, chroma_bcurve, satcurve, lhskcurve, scale == 1 ? 1 : 16);
+ CurveFactory::complexsgnCurve(autili, butili, ccutili, cclutili, params.labCurve.acurve, params.labCurve.bcurve, params.labCurve.cccurve,
+ params.labCurve.lccurve, chroma_acurve, chroma_bcurve, satcurve, lhskcurve, scale == 1 ? 1 : 16);
}
- if (todo & (M_LUMINANCE + M_COLOR) ) {
- nprevl->CopyFrom (oprevl);
+ if (todo & (M_LUMINANCE + M_COLOR)) {
+ nprevl->CopyFrom(oprevl);
- progress ("Applying Color Boost...", 100 * readyphase / numofphases);
+ progress("Applying Color Boost...", 100 * readyphase / numofphases);
// ipf.MSR(nprevl, nprevl->W, nprevl->H, 1);
histCCurve.clear();
histLCurve.clear();
- ipf.chromiLuminanceCurve (nullptr, pW, nprevl, nprevl, chroma_acurve, chroma_bcurve, satcurve, lhskcurve, clcurve, lumacurve, utili, autili, butili, ccutili, cclutili, clcutili, histCCurve, histLCurve);
- ipf.vibrance (nprevl);
+ ipf.chromiLuminanceCurve(nullptr, pW, nprevl, nprevl, chroma_acurve, chroma_bcurve, satcurve, lhskcurve, clcurve, lumacurve, utili, autili, butili, ccutili, cclutili, clcutili, histCCurve, histLCurve);
+ ipf.vibrance(nprevl);
- if ((params.colorappearance.enabled && !params.colorappearance.tonecie) || (!params.colorappearance.enabled)) {
- ipf.EPDToneMap (nprevl, 5, scale);
+ if ((params.colorappearance.enabled && !params.colorappearance.tonecie) || (!params.colorappearance.enabled)) {
+ ipf.EPDToneMap(nprevl, 5, scale);
}
// for all treatments Defringe, Sharpening, Contrast detail , Microcontrast they are activated if "CIECAM" function are disabled
@@ -687,9 +763,9 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
*/
if (params.dirpyrequalizer.cbdlMethod == "aft") {
- if (((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled)) ) {
- progress ("Pyramid wavelet...", 100 * readyphase / numofphases);
- ipf.dirpyrequalizer (nprevl, scale);
+ if (((params.colorappearance.enabled && !settings->autocielab) || (!params.colorappearance.enabled))) {
+ progress("Pyramid wavelet...", 100 * readyphase / numofphases);
+ ipf.dirpyrequalizer(nprevl, scale);
//ipf.Lanczoslab (ip_wavelet(LabImage * lab, LabImage * dst, const procparams::EqualizerParams & eqparams), nprevl, 1.f/scale);
readyphase++;
}
@@ -698,18 +774,18 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
wavcontlutili = false;
//CurveFactory::curveWavContL ( wavcontlutili,params.wavelet.lcurve, wavclCurve, LUTu & histogramwavcl, LUTu & outBeforeWavCLurveHistogram,int skip);
- CurveFactory::curveWavContL (wavcontlutili, params.wavelet.wavclCurve, wavclCurve, scale == 1 ? 1 : 16);
+ CurveFactory::curveWavContL(wavcontlutili, params.wavelet.wavclCurve, wavclCurve, scale == 1 ? 1 : 16);
if ((params.wavelet.enabled)) {
WaveletParams WaveParams = params.wavelet;
// WaveParams.getCurves(wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY);
- WaveParams.getCurves (wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL);
+ WaveParams.getCurves(wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL);
int kall = 0;
- progress ("Wavelet...", 100 * readyphase / numofphases);
+ progress("Wavelet...", 100 * readyphase / numofphases);
// ipf.ip_wavelet(nprevl, nprevl, kall, WaveParams, wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, scale);
- ipf.ip_wavelet (nprevl, nprevl, kall, WaveParams, wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL, wavclCurve, scale);
+ ipf.ip_wavelet(nprevl, nprevl, kall, WaveParams, wavCLVCurve, waOpacityCurveRG, waOpacityCurveBY, waOpacityCurveW, waOpacityCurveWL, wavclCurve, scale);
}
@@ -718,26 +794,27 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
//L histo and Chroma histo for ciecam
// histogram well be for Lab (Lch) values, because very difficult to do with J,Q, M, s, C
int x1, y1, x2, y2;
- params.crop.mapToResized (pW, pH, scale, x1, x2, y1, y2);
+ params.crop.mapToResized(pW, pH, scale, x1, x2, y1, y2);
lhist16CAM.clear();
lhist16CCAM.clear();
if (!params.colorappearance.datacie) {
for (int x = 0; x < pH; x++)
for (int y = 0; y < pW; y++) {
- int pos = CLIP ((int) (nprevl->L[x][y]));
- int posc = CLIP ((int)sqrt (nprevl->a[x][y] * nprevl->a[x][y] + nprevl->b[x][y] * nprevl->b[x][y]));
+ int pos = CLIP((int)(nprevl->L[x][y]));
+ int posc = CLIP((int)sqrt(nprevl->a[x][y] * nprevl->a[x][y] + nprevl->b[x][y] * nprevl->b[x][y]));
lhist16CAM[pos]++;
lhist16CCAM[posc]++;
}
}
- CurveFactory::curveLightBrightColor (params.colorappearance.curve, params.colorappearance.curve2, params.colorappearance.curve3,
- lhist16CAM, histLCAM, lhist16CCAM, histCCAM,
- customColCurve1, customColCurve2, customColCurve3, 1);
+ CurveFactory::curveLightBrightColor(params.colorappearance.curve, params.colorappearance.curve2, params.colorappearance.curve3,
+ lhist16CAM, histLCAM, lhist16CCAM, histCCAM,
+ customColCurve1, customColCurve2, customColCurve3, 1);
const FramesMetaData* metaData = imgsrc->getMetaData();
int imgNum = 0;
+
if (imgsrc->isRAW()) {
if (imgsrc->getSensorType() == ST_BAYER) {
imgNum = rtengine::LIM(params.raw.bayersensor.imageNum, 0, metaData->getFrameCount() - 1);
@@ -746,19 +823,19 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
}
- float fnum = metaData->getFNumber (imgNum); // F number
- float fiso = metaData->getISOSpeed (imgNum) ; // ISO
- float fspeed = metaData->getShutterSpeed (imgNum) ; // Speed
- double fcomp = metaData->getExpComp (imgNum); // Compensation +/-
+ float fnum = metaData->getFNumber(imgNum); // F number
+ float fiso = metaData->getISOSpeed(imgNum) ; // ISO
+ float fspeed = metaData->getShutterSpeed(imgNum) ; // Speed
+ double fcomp = metaData->getExpComp(imgNum); // Compensation +/-
double adap;
if (fnum < 0.3f || fiso < 5.f || fspeed < 0.00001f) { //if no exif data or wrong
adap = 2000.;
} else {
- double E_V = fcomp + log2 (double ((fnum * fnum) / fspeed / (fiso / 100.f)));
+ double E_V = fcomp + log2(double ((fnum * fnum) / fspeed / (fiso / 100.f)));
E_V += params.toneCurve.expcomp;// exposure compensation in tonecurve ==> direct EV
- E_V += log2 (params.raw.expos); // exposure raw white point ; log2 ==> linear to EV
- adap = powf (2.f, E_V - 3.f); // cd / m2
+ E_V += log2(params.raw.expos); // exposure raw white point ; log2 ==> linear to EV
+ adap = powf(2.f, E_V - 3.f); // cd / m2
// end calculation adaptation scene luminosity
}
@@ -766,15 +843,15 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
bool execsharp = false;
if (!ncie) {
- ncie = new CieImage (pW, pH);
+ ncie = new CieImage(pW, pH);
}
if (!CAMBrightCurveJ && (params.colorappearance.algo == "JC" || params.colorappearance.algo == "JS" || params.colorappearance.algo == "ALL")) {
- CAMBrightCurveJ (32768, 0);
+ CAMBrightCurveJ(32768, 0);
}
if (!CAMBrightCurveQ && (params.colorappearance.algo == "QM" || params.colorappearance.algo == "ALL")) {
- CAMBrightCurveQ (32768, 0);
+ CAMBrightCurveQ(32768, 0);
}
// Issue 2785, only float version of ciecam02 for navigator and pan background
@@ -782,18 +859,18 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
CAMBrightCurveJ.dirty = true;
CAMBrightCurveQ.dirty = true;
- ipf.ciecam_02float (ncie, float (adap), pW, 2, nprevl, ¶ms, customColCurve1, customColCurve2, customColCurve3, histLCAM, histCCAM, CAMBrightCurveJ, CAMBrightCurveQ, CAMMean, 5, scale, execsharp, d, dj, yb, 1);
+ ipf.ciecam_02float(ncie, float (adap), pW, 2, nprevl, ¶ms, customColCurve1, customColCurve2, customColCurve3, histLCAM, histCCAM, CAMBrightCurveJ, CAMBrightCurveQ, CAMMean, 5, scale, execsharp, d, dj, yb, 1);
if ((params.colorappearance.autodegree || params.colorappearance.autodegreeout) && acListener && params.colorappearance.enabled) {
- acListener->autoCamChanged (100.* (double)d, 100.* (double)dj);
+ acListener->autoCamChanged(100.* (double)d, 100.* (double)dj);
}
if (params.colorappearance.autoadapscen && acListener && params.colorappearance.enabled) {
- acListener->adapCamChanged (adap); //real value of adapt scene
+ acListener->adapCamChanged(adap); //real value of adapt scene
}
if (params.colorappearance.autoybscen && acListener && params.colorappearance.enabled) {
- acListener->ybCamChanged ((int) yb); //real value Yb scene
+ acListener->ybCamChanged((int) yb); //real value Yb scene
}
readyphase++;
@@ -816,33 +893,33 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
}
// Update the monitor color transform if necessary
- if ((todo & M_MONITOR) || (lastOutputProfile != params.icm.output) || lastOutputIntent != params.icm.outputIntent || lastOutputBPC != params.icm.outputBPC) {
- lastOutputProfile = params.icm.output;
+ if ((todo & M_MONITOR) || (lastOutputProfile != params.icm.outputProfile) || lastOutputIntent != params.icm.outputIntent || lastOutputBPC != params.icm.outputBPC) {
+ lastOutputProfile = params.icm.outputProfile;
lastOutputIntent = params.icm.outputIntent;
lastOutputBPC = params.icm.outputBPC;
- ipf.updateColorProfiles (monitorProfile, monitorIntent, softProof, gamutCheck);
+ ipf.updateColorProfiles(monitorProfile, monitorIntent, softProof, gamutCheck);
}
// process crop, if needed
for (size_t i = 0; i < crops.size(); i++)
- if (crops[i]->hasListener () && cropCall != crops[i] ) {
- crops[i]->update (todo); // may call ourselves
+ if (crops[i]->hasListener() && cropCall != crops[i]) {
+ crops[i]->update(todo); // may call ourselves
}
- progress ("Conversion to RGB...", 100 * readyphase / numofphases);
+ progress("Conversion to RGB...", 100 * readyphase / numofphases);
if ((todo != CROP && todo != MINUPDATE) || (todo & M_MONITOR)) {
- MyMutex::MyLock prevImgLock (previmg->getMutex());
+ MyMutex::MyLock prevImgLock(previmg->getMutex());
try {
// Computing the preview image, i.e. converting from WCS->Monitor color space (soft-proofing disabled) or WCS->Printer profile->Monitor color space (soft-proofing enabled)
- ipf.lab2monitorRgb (nprevl, previmg);
+ ipf.lab2monitorRgb(nprevl, previmg);
// Computing the internal image for analysis, i.e. conversion from WCS->Output profile
delete workimg;
- workimg = ipf.lab2rgb (nprevl, 0, 0, pW, pH, params.icm);
+ workimg = ipf.lab2rgb(nprevl, 0, 0, pW, pH, params.icm);
} catch (char * str) {
- progress ("Error converting file...", 0);
+ progress("Error converting file...", 0);
return;
}
}
@@ -851,31 +928,31 @@ void ImProcCoordinator::updatePreviewImage (int todo, Crop* cropCall)
resultValid = true;
if (imageListener) {
- imageListener->setImage (previmg, scale, params.crop);
+ imageListener->setImage(previmg, scale, params.crop);
}
}
if (imageListener)
// TODO: The WB tool should be advertised too in order to get the AutoWB's temp and green values
{
- imageListener->imageReady (params.crop);
+ imageListener->imageReady(params.crop);
}
readyphase++;
if (hListener) {
- updateLRGBHistograms ();
- hListener->histogramChanged (histRed, histGreen, histBlue, histLuma, histToneCurve, histLCurve, histCCurve, /*histCLurve, histLLCurve,*/ histLCAM, histCCAM, histRedRaw, histGreenRaw, histBlueRaw, histChroma, histLRETI);
+ updateLRGBHistograms();
+ hListener->histogramChanged(histRed, histGreen, histBlue, histLuma, histToneCurve, histLCurve, histCCurve, /*histCLurve, histLLCurve,*/ histLCAM, histCCAM, histRedRaw, histGreenRaw, histBlueRaw, histChroma, histLRETI);
}
}
-void ImProcCoordinator::freeAll ()
+void ImProcCoordinator::freeAll()
{
if (settings->verbose) {
- printf ("freeall starts %d\n", (int)allocated);
+ printf("freeall starts %d\n", (int)allocated);
}
if (allocated) {
@@ -898,7 +975,7 @@ void ImProcCoordinator::freeAll ()
ncie = nullptr;
if (imageListener) {
- imageListener->delImage (previmg);
+ imageListener->delImage(previmg);
} else {
delete previmg;
}
@@ -916,44 +993,44 @@ void ImProcCoordinator::freeAll ()
*
* @param prevscale New Preview's scale.
*/
-void ImProcCoordinator::setScale (int prevscale)
+void ImProcCoordinator::setScale(int prevscale)
{
if (settings->verbose) {
- printf ("setscale before lock\n");
+ printf("setscale before lock\n");
}
- tr = getCoarseBitMask (params.coarse);
+ tr = getCoarseBitMask(params.coarse);
int nW, nH;
- imgsrc->getFullSize (fw, fh, tr);
+ imgsrc->getFullSize(fw, fh, tr);
prevscale++;
do {
prevscale--;
- PreviewProps pp (0, 0, fw, fh, prevscale);
- imgsrc->getSize (pp, nW, nH);
- } while (nH < 400 && prevscale > 1 && (nW * nH < 1000000) ); // sctually hardcoded values, perhaps a better choice is possible
+ PreviewProps pp(0, 0, fw, fh, prevscale);
+ imgsrc->getSize(pp, nW, nH);
+ } while (nH < 400 && prevscale > 1 && (nW * nH < 1000000)); // sctually hardcoded values, perhaps a better choice is possible
if (settings->verbose) {
- printf ("setscale starts (%d, %d)\n", nW, nH);
+ printf("setscale starts (%d, %d)\n", nW, nH);
}
if (nW != pW || nH != pH) {
- freeAll ();
+ freeAll();
pW = nW;
pH = nH;
- orig_prev = new Imagefloat (pW, pH);
+ orig_prev = new Imagefloat(pW, pH);
oprevi = orig_prev;
- oprevl = new LabImage (pW, pH);
- nprevl = new LabImage (pW, pH);
+ oprevl = new LabImage(pW, pH);
+ nprevl = new LabImage(pW, pH);
//ncie is only used in ImProcCoordinator::updatePreviewImage, it will be allocated on first use and deleted if not used anymore
- previmg = new Image8 (pW, pH);
- workimg = new Image8 (pW, pH);
+ previmg = new Image8(pW, pH);
+ workimg = new Image8(pW, pH);
allocated = true;
}
@@ -964,26 +1041,26 @@ void ImProcCoordinator::setScale (int prevscale)
fullh = fh;
if (settings->verbose) {
- printf ("setscale ends\n");
+ printf("setscale ends\n");
}
if (!sizeListeners.empty())
for (size_t i = 0; i < sizeListeners.size(); i++) {
- sizeListeners[i]->sizeChanged (fullw, fullh, fw, fh);
+ sizeListeners[i]->sizeChanged(fullw, fullh, fw, fh);
}
if (settings->verbose) {
- printf ("setscale ends2\n");
+ printf("setscale ends2\n");
}
}
-void ImProcCoordinator::updateLRGBHistograms ()
+void ImProcCoordinator::updateLRGBHistograms()
{
int x1, y1, x2, y2;
- params.crop.mapToResized (pW, pH, scale, x1, x2, y1, y2);
+ params.crop.mapToResized(pW, pH, scale, x1, x2, y1, y2);
#pragma omp parallel sections
{
@@ -994,7 +1071,7 @@ void ImProcCoordinator::updateLRGBHistograms ()
for (int i = y1; i < y2; i++)
for (int j = x1; j < x2; j++)
{
- histChroma[ (int) (sqrtf (SQR (nprevl->a[i][j]) + SQR (nprevl->b[i][j])) / 188.f)]++; //188 = 48000/256
+ histChroma[(int)(sqrtf(SQR(nprevl->a[i][j]) + SQR(nprevl->b[i][j])) / 188.f)]++; //188 = 48000/256
}
}
#pragma omp section
@@ -1004,7 +1081,7 @@ void ImProcCoordinator::updateLRGBHistograms ()
for (int i = y1; i < y2; i++)
for (int j = x1; j < x2; j++)
{
- histLuma[ (int) (nprevl->L[i][j] / 128.f)]++;
+ histLuma[(int)(nprevl->L[i][j] / 128.f)]++;
}
}
#pragma omp section
@@ -1032,7 +1109,7 @@ void ImProcCoordinator::updateLRGBHistograms ()
}
-void ImProcCoordinator::progress (Glib::ustring str, int pr)
+void ImProcCoordinator::progress(Glib::ustring str, int pr)
{
/* if (plistener) {
@@ -1041,28 +1118,28 @@ void ImProcCoordinator::progress (Glib::ustring str, int pr)
}*/
}
-bool ImProcCoordinator::getAutoWB (double& temp, double& green, double equal, double tempBias)
+bool ImProcCoordinator::getAutoWB(double& temp, double& green, double equal, double tempBias)
{
if (imgsrc) {
if (lastAwbEqual != equal || lastAwbTempBias != tempBias) {
// Issue 2500 MyMutex::MyLock lock(minit); // Also used in crop window
double rm, gm, bm;
- imgsrc->getAutoWBMultipliers (rm, gm, bm);
+ imgsrc->getAutoWBMultipliers(rm, gm, bm);
if (rm != -1) {
- autoWB.update (rm, gm, bm, equal, tempBias);
+ autoWB.update(rm, gm, bm, equal, tempBias);
lastAwbEqual = equal;
lastAwbTempBias = tempBias;
} else {
lastAwbEqual = -1.;
- autoWB.useDefaults (equal);
+ autoWB.useDefaults(equal);
lastAwbTempBias = 0.0;
}
}
- temp = autoWB.getTemp ();
- green = autoWB.getGreen ();
+ temp = autoWB.getTemp();
+ green = autoWB.getGreen();
return true;
} else {
//temp = autoWB.getTemp();
@@ -1072,64 +1149,64 @@ bool ImProcCoordinator::getAutoWB (double& temp, double& green, double equal, do
}
}
-void ImProcCoordinator::getCamWB (double& temp, double& green)
+void ImProcCoordinator::getCamWB(double& temp, double& green)
{
if (imgsrc) {
- temp = imgsrc->getWB().getTemp ();
- green = imgsrc->getWB().getGreen ();
+ temp = imgsrc->getWB().getTemp();
+ green = imgsrc->getWB().getGreen();
}
}
-void ImProcCoordinator::getSpotWB (int x, int y, int rect, double& temp, double& tgreen)
+void ImProcCoordinator::getSpotWB(int x, int y, int rect, double& temp, double& tgreen)
{
ColorTemp ret;
{
- MyMutex::MyLock lock (mProcessing);
+ MyMutex::MyLock lock(mProcessing);
std::vector points, red, green, blue;
for (int i = y - rect; i <= y + rect; i++)
for (int j = x - rect; j <= x + rect; j++) {
- points.push_back (Coord2D (j, i));
+ points.push_back(Coord2D(j, i));
}
- ipf.transCoord (fw, fh, points, red, green, blue);
+ ipf.transCoord(fw, fh, points, red, green, blue);
- int tr = getCoarseBitMask (params.coarse);
+ int tr = getCoarseBitMask(params.coarse);
- ret = imgsrc->getSpotWB (red, green, blue, tr, params.wb.equal);
- currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
+ ret = imgsrc->getSpotWB(red, green, blue, tr, params.wb.equal);
+ currWB = ColorTemp(params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
//double rr,gg,bb;
//currWB.getMultipliers(rr,gg,bb);
} // end of mutex lockong
if (ret.getTemp() > 0) {
- temp = ret.getTemp ();
- tgreen = ret.getGreen ();
+ temp = ret.getTemp();
+ tgreen = ret.getGreen();
} else {
- temp = currWB.getTemp ();
- tgreen = currWB.getGreen ();
+ temp = currWB.getTemp();
+ tgreen = currWB.getGreen();
}
}
-void ImProcCoordinator::getAutoCrop (double ratio, int &x, int &y, int &w, int &h)
+void ImProcCoordinator::getAutoCrop(double ratio, int &x, int &y, int &w, int &h)
{
- MyMutex::MyLock lock (mProcessing);
+ MyMutex::MyLock lock(mProcessing);
LensCorrection *pLCPMap = nullptr;
if (params.lensProf.useLcp() && imgsrc->getMetaData()->getFocalLen() > 0) {
- const std::shared_ptr pLCPProf = LCPStore::getInstance()->getProfile (params.lensProf.lcpFile);
+ const std::shared_ptr pLCPProf = LCPStore::getInstance()->getProfile(params.lensProf.lcpFile);
- if (pLCPProf) pLCPMap = new LCPMapper (pLCPProf, imgsrc->getMetaData()->getFocalLen(), imgsrc->getMetaData()->getFocalLen35mm(), imgsrc->getMetaData()->getFocusDist(),
- 0, false, params.lensProf.useDist, fullw, fullh, params.coarse, imgsrc->getRotateDegree());
+ if (pLCPProf) pLCPMap = new LCPMapper(pLCPProf, imgsrc->getMetaData()->getFocalLen(), imgsrc->getMetaData()->getFocalLen35mm(), imgsrc->getMetaData()->getFocusDist(),
+ 0, false, params.lensProf.useDist, fullw, fullh, params.coarse, imgsrc->getRotateDegree());
}
- double fillscale = ipf.getTransformAutoFill (fullw, fullh, pLCPMap);
+ double fillscale = ipf.getTransformAutoFill(fullw, fullh, pLCPMap);
if (ratio > 0) {
w = fullw * fillscale;
@@ -1148,25 +1225,25 @@ void ImProcCoordinator::getAutoCrop (double ratio, int &x, int &y, int &w, int &
y = (fullh - h) / 2;
}
-void ImProcCoordinator::setMonitorProfile (const Glib::ustring& profile, RenderingIntent intent)
+void ImProcCoordinator::setMonitorProfile(const Glib::ustring& profile, RenderingIntent intent)
{
monitorProfile = profile;
monitorIntent = intent;
}
-void ImProcCoordinator::getMonitorProfile (Glib::ustring& profile, RenderingIntent& intent) const
+void ImProcCoordinator::getMonitorProfile(Glib::ustring& profile, RenderingIntent& intent) const
{
profile = monitorProfile;
intent = monitorIntent;
}
-void ImProcCoordinator::setSoftProofing (bool softProof, bool gamutCheck)
+void ImProcCoordinator::setSoftProofing(bool softProof, bool gamutCheck)
{
this->softProof = softProof;
this->gamutCheck = gamutCheck;
}
-void ImProcCoordinator::getSoftProofing (bool &softProof, bool &gamutCheck)
+void ImProcCoordinator::getSoftProofing(bool &softProof, bool &gamutCheck)
{
softProof = this->softProof;
gamutCheck = this->gamutCheck;
@@ -1177,41 +1254,41 @@ void ImProcCoordinator::setSharpMask (bool sharpMask)
this->sharpMask = sharpMask;
}
-void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname, bool apply_wb)
+void ImProcCoordinator::saveInputICCReference(const Glib::ustring& fname, bool apply_wb)
{
- MyMutex::MyLock lock (mProcessing);
+ MyMutex::MyLock lock(mProcessing);
int fW, fH;
- int tr = getCoarseBitMask (params.coarse);
+ int tr = getCoarseBitMask(params.coarse);
- imgsrc->getFullSize (fW, fH, tr);
- PreviewProps pp (0, 0, fW, fH, 1);
+ imgsrc->getFullSize(fW, fH, tr);
+ PreviewProps pp(0, 0, fW, fH, 1);
ProcParams ppar = params;
ppar.toneCurve.hrenabled = false;
- ppar.icm.input = "(none)";
- Imagefloat* im = new Imagefloat (fW, fH);
- imgsrc->preprocess ( ppar.raw, ppar.lensProf, ppar.coarse );
+ ppar.icm.inputProfile = "(none)";
+ Imagefloat* im = new Imagefloat(fW, fH);
+ imgsrc->preprocess(ppar.raw, ppar.lensProf, ppar.coarse);
double dummy = 0.0;
- imgsrc->demosaic (ppar.raw, false, dummy);
- ColorTemp currWB = ColorTemp (params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
+ imgsrc->demosaic(ppar.raw, false, dummy);
+ ColorTemp currWB = ColorTemp(params.wb.temperature, params.wb.green, params.wb.equal, params.wb.method);
if (params.wb.method == "Camera") {
- currWB = imgsrc->getWB ();
+ currWB = imgsrc->getWB();
} else if (params.wb.method == "Auto") {
if (lastAwbEqual != params.wb.equal || lastAwbTempBias != params.wb.tempBias) {
double rm, gm, bm;
- imgsrc->getAutoWBMultipliers (rm, gm, bm);
+ imgsrc->getAutoWBMultipliers(rm, gm, bm);
if (rm != -1.) {
- autoWB.update (rm, gm, bm, params.wb.equal, params.wb.tempBias);
+ autoWB.update(rm, gm, bm, params.wb.equal, params.wb.tempBias);
lastAwbEqual = params.wb.equal;
lastAwbTempBias = params.wb.tempBias;
} else {
lastAwbEqual = -1.;
lastAwbTempBias = 0.0;
- autoWB.useDefaults (params.wb.equal);
+ autoWB.useDefaults(params.wb.equal);
}
}
@@ -1222,19 +1299,19 @@ void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname, bool
currWB = ColorTemp(); // = no white balance
}
- imgsrc->getImage (currWB, tr, im, pp, ppar.toneCurve, ppar.raw);
- ImProcFunctions ipf (&ppar, true);
+ imgsrc->getImage(currWB, tr, im, pp, ppar.toneCurve, ppar.raw);
+ ImProcFunctions ipf(&ppar, true);
if (ipf.needsTransform()) {
- Imagefloat* trImg = new Imagefloat (fW, fH);
- ipf.transform (im, trImg, 0, 0, 0, 0, fW, fH, fW, fH,
- imgsrc->getMetaData(), imgsrc->getRotateDegree(), true);
+ Imagefloat* trImg = new Imagefloat(fW, fH);
+ ipf.transform(im, trImg, 0, 0, 0, 0, fW, fH, fW, fH,
+ imgsrc->getMetaData(), imgsrc->getRotateDegree(), true);
delete im;
im = trImg;
}
if (params.crop.enabled) {
- Imagefloat *tmpim = new Imagefloat (params.crop.w, params.crop.h);
+ Imagefloat *tmpim = new Imagefloat(params.crop.w, params.crop.h);
int cx = params.crop.x;
int cy = params.crop.y;
int cw = params.crop.w;
@@ -1243,9 +1320,9 @@ void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname, bool
for (int i = cy; i < cy + ch; i++) {
for (int j = cx; j < cx + cw; j++) {
- tmpim->r (i - cy, j - cx) = im->r (i, j);
- tmpim->g (i - cy, j - cx) = im->g (i, j);
- tmpim->b (i - cy, j - cx) = im->b (i, j);
+ tmpim->r(i - cy, j - cx) = im->r(i, j);
+ tmpim->g(i - cy, j - cx) = im->g(i, j);
+ tmpim->b(i - cy, j - cx) = im->b(i, j);
}
}
@@ -1258,146 +1335,149 @@ void ImProcCoordinator::saveInputICCReference (const Glib::ustring& fname, bool
for (int i = 0; i < im->getHeight(); i++) {
for (int j = 0; j < im->getWidth(); j++) {
- im->r (i, j) = CLIP (im->r (i, j));
- im->g (i, j) = CLIP (im->g (i, j));
- im->b (i, j) = CLIP (im->b (i, j));
+ im->r(i, j) = CLIP(im->r(i, j));
+ im->g(i, j) = CLIP(im->g(i, j));
+ im->b(i, j) = CLIP(im->b(i, j));
}
}
int imw, imh;
- double tmpScale = ipf.resizeScale (¶ms, fW, fH, imw, imh);
+ double tmpScale = ipf.resizeScale(¶ms, fW, fH, imw, imh);
if (tmpScale != 1.0) {
- Imagefloat* tempImage = new Imagefloat (imw, imh);
- ipf.resize (im, tempImage, tmpScale);
+ Imagefloat* tempImage = new Imagefloat(imw, imh);
+ ipf.resize(im, tempImage, tmpScale);
delete im;
im = tempImage;
}
- im->setMetadata (imgsrc->getMetaData()->getRootExifData ());
+ im->setMetadata(imgsrc->getMetaData()->getRootExifData());
- im->saveTIFF (fname, 16, true);
+ im->saveTIFF(fname, 16, true);
delete im;
if (plistener) {
- plistener->setProgressState (false);
+ plistener->setProgressState(false);
}
//im->saveJPEG (fname, 85);
}
-void ImProcCoordinator::stopProcessing ()
+void ImProcCoordinator::stopProcessing()
{
- updaterThreadStart.lock ();
+ updaterThreadStart.lock();
if (updaterRunning && thread) {
changeSinceLast = 0;
- thread->join ();
+ thread->join();
}
- updaterThreadStart.unlock ();
+ updaterThreadStart.unlock();
}
-void ImProcCoordinator::startProcessing ()
+void ImProcCoordinator::startProcessing()
{
#undef THREAD_PRIORITY_NORMAL
if (!destroying) {
if (!updaterRunning) {
- updaterThreadStart.lock ();
+ updaterThreadStart.lock();
thread = nullptr;
updaterRunning = true;
- updaterThreadStart.unlock ();
+ updaterThreadStart.unlock();
//batchThread->yield(); //the running batch should wait other threads to avoid conflict
- thread = Glib::Thread::create (sigc::mem_fun (*this, &ImProcCoordinator::process), 0, true, true, Glib::THREAD_PRIORITY_NORMAL);
+ thread = Glib::Thread::create(sigc::mem_fun(*this, &ImProcCoordinator::process), 0, true, true, Glib::THREAD_PRIORITY_NORMAL);
}
}
}
-void ImProcCoordinator::startProcessing (int changeCode)
+void ImProcCoordinator::startProcessing(int changeCode)
{
paramsUpdateMutex.lock();
changeSinceLast |= changeCode;
paramsUpdateMutex.unlock();
- startProcessing ();
+ startProcessing();
}
-void ImProcCoordinator::process ()
+void ImProcCoordinator::process()
{
if (plistener) {
- plistener->setProgressState (true);
+ plistener->setProgressState(true);
}
- paramsUpdateMutex.lock ();
+ paramsUpdateMutex.lock();
while (changeSinceLast) {
params = nextParams;
int change = changeSinceLast;
changeSinceLast = 0;
- paramsUpdateMutex.unlock ();
+ paramsUpdateMutex.unlock();
// M_VOID means no update, and is a bit higher that the rest
if (change & (M_VOID - 1)) {
- updatePreviewImage (change);
+ updatePreviewImage(change);
}
- paramsUpdateMutex.lock ();
+ paramsUpdateMutex.lock();
}
- paramsUpdateMutex.unlock ();
+ paramsUpdateMutex.unlock();
updaterRunning = false;
if (plistener) {
- plistener->setProgressState (false);
+ plistener->setProgressState(false);
}
}
-ProcParams* ImProcCoordinator::beginUpdateParams ()
+ProcParams* ImProcCoordinator::beginUpdateParams()
{
- paramsUpdateMutex.lock ();
+ paramsUpdateMutex.lock();
return &nextParams;
}
-void ImProcCoordinator::endUpdateParams (ProcEvent change)
+void ImProcCoordinator::endUpdateParams(ProcEvent change)
{
int action = RefreshMapper::getInstance()->getAction(change);
endUpdateParams(action);
}
-void ImProcCoordinator::endUpdateParams (int changeFlags)
+void ImProcCoordinator::endUpdateParams(int changeFlags)
{
changeSinceLast |= changeFlags;
- paramsUpdateMutex.unlock ();
- startProcessing ();
+ paramsUpdateMutex.unlock();
+ startProcessing();
}
-bool ImProcCoordinator::getHighQualComputed() {
+bool ImProcCoordinator::getHighQualComputed()
+{
// this function may only be called from detail windows
- if(!highQualityComputed) {
- if(options.prevdemo == PD_Sidecar) {
+ if (!highQualityComputed) {
+ if (options.prevdemo == PD_Sidecar) {
// we already have high quality preview
setHighQualComputed();
} else {
for (size_t i = 0; i < crops.size() - 1; ++i) { // -1, because last entry is the freshly created detail window
- if (crops[i]->get_skip() == 1 ) { // there is at least one crop with skip == 1 => we already have high quality preview
+ if (crops[i]->get_skip() == 1) { // there is at least one crop with skip == 1 => we already have high quality preview
setHighQualComputed();
break;
}
}
}
}
+
return highQualityComputed;
}
-void ImProcCoordinator::setHighQualComputed() {
+void ImProcCoordinator::setHighQualComputed()
+{
highQualityComputed = true;
}
diff --git a/rtengine/improcfun.cc b/rtengine/improcfun.cc
index 670a6c825..ed806e71a 100644
--- a/rtengine/improcfun.cc
+++ b/rtengine/improcfun.cc
@@ -296,7 +296,7 @@ void ImProcFunctions::updateColorProfiles (const Glib::ustring& monitorProfile,
#if !defined(__APPLE__) // No support for monitor profiles on OS X, all data is sRGB
monitor = ICCStore::getInstance()->getProfile (monitorProfile);
#else
- monitor = ICCStore::getInstance()->getProfile ("RT_sRGB");
+ monitor = ICCStore::getInstance()->getProfile (options.rtSettings.srgb);
#endif
}
@@ -324,7 +324,7 @@ void ImProcFunctions::updateColorProfiles (const Glib::ustring& monitorProfile,
}
outIntent = settings->printerIntent;
} else {
- oprof = ICCStore::getInstance()->getProfile(params->icm.output);
+ oprof = ICCStore::getInstance()->getProfile(params->icm.outputProfile);
if (params->icm.outputBPC) {
flags |= cmsFLAGS_BLACKPOINTCOMPENSATION;
}
@@ -397,7 +397,7 @@ void ImProcFunctions::updateColorProfiles (const Glib::ustring& monitorProfile,
void ImProcFunctions::firstAnalysis (const Imagefloat* const original, const ProcParams ¶ms, LUTu & histogram)
{
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.workingProfile);
lumimul[0] = wprof[1][0];
lumimul[1] = wprof[1][1];
@@ -959,7 +959,7 @@ void ImProcFunctions::ciecam_02float (CieImage* ncie, float adap, int pW, int pw
//matrix for current working space
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.workingProfile);
const float wip[3][3] = {
{ (float)wiprof[0][0], (float)wiprof[0][1], (float)wiprof[0][2]},
{ (float)wiprof[1][0], (float)wiprof[1][1], (float)wiprof[1][2]},
@@ -2041,8 +2041,8 @@ void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer
}
}
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params->icm.working);
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params->icm.workingProfile);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.workingProfile);
float toxyz[3][3] = {
{
@@ -2151,7 +2151,7 @@ void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer
hald_clut = CLUTStore::getInstance().getClut ( params->filmSimulation.clutFilename );
if ( hald_clut ) {
- clutAndWorkingProfilesAreSame = hald_clut->getProfile() == params->icm.working;
+ clutAndWorkingProfilesAreSame = hald_clut->getProfile() == params->icm.workingProfile;
if ( !clutAndWorkingProfilesAreSame ) {
xyz2clut = ICCStore::getInstance()->workingSpaceInverseMatrix ( hald_clut->getProfile() );
@@ -2180,7 +2180,7 @@ void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer
const float comp = (max (0.0, expcomp) + 1.0) * hlcompr / 100.0;
const float shoulder = ((65536.0 / max (1.0f, exp_scale)) * (hlcomprthresh / 200.0)) + 0.1;
const float hlrange = 65536.0 - shoulder;
- const bool isProPhoto = (params->icm.working == "ProPhoto");
+ const bool isProPhoto = (params->icm.workingProfile == "ProPhoto");
// extracting datas from 'params' to avoid cache flush (to be confirmed)
ToneCurveParams::TcMode curveMode = params->toneCurve.curveMode;
ToneCurveParams::TcMode curveMode2 = params->toneCurve.curveMode2;
@@ -2197,12 +2197,12 @@ void ImProcFunctions::rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer
if (hasToneCurve1 && curveMode == ToneCurveParams::TcMode::PERCEPTUAL) {
const PerceptualToneCurve& userToneCurve = static_cast (customToneCurve1);
- userToneCurve.initApplyState (ptc1ApplyState, params->icm.working);
+ userToneCurve.initApplyState (ptc1ApplyState, params->icm.workingProfile);
}
if (hasToneCurve2 && curveMode2 == ToneCurveParams::TcMode::PERCEPTUAL) {
const PerceptualToneCurve& userToneCurve = static_cast (customToneCurve2);
- userToneCurve.initApplyState (ptc2ApplyState, params->icm.working);
+ userToneCurve.initApplyState (ptc2ApplyState, params->icm.workingProfile);
}
bool hasColorToning = params->colorToning.enabled && bool (ctOpacityCurve) && bool (ctColorCurve) && params->colorToning.method != "LabGrid";
@@ -4241,19 +4241,19 @@ void ImProcFunctions::chromiLuminanceCurve (PipetteBuffer *pipetteBuffer, int pW
// if(params->labCurve.avoidclip ){
// parameter to adapt curve C=f(C) to gamut
- if (params->icm.working == "ProPhoto") {
+ if (params->icm.workingProfile == "ProPhoto") {
adjustr = 1.2f; // 1.2 instead 1.0 because it's very rare to have C>170..
- } else if (params->icm.working == "Adobe RGB") {
+ } else if (params->icm.workingProfile == "Adobe RGB") {
adjustr = 1.8f;
- } else if (params->icm.working == "sRGB") {
+ } else if (params->icm.workingProfile == "sRGB") {
adjustr = 2.0f;
- } else if (params->icm.working == "WideGamut") {
+ } else if (params->icm.workingProfile == "WideGamut") {
adjustr = 1.2f;
- } else if (params->icm.working == "Beta RGB") {
+ } else if (params->icm.workingProfile == "Beta RGB") {
adjustr = 1.4f;
- } else if (params->icm.working == "BestRGB") {
+ } else if (params->icm.workingProfile == "BestRGB") {
adjustr = 1.4f;
- } else if (params->icm.working == "BruceRGB") {
+ } else if (params->icm.workingProfile == "BruceRGB") {
adjustr = 1.8f;
}
@@ -4320,14 +4320,14 @@ void ImProcFunctions::chromiLuminanceCurve (PipetteBuffer *pipetteBuffer, int pW
const bool gamutLch = settings->gamutLch;
const float amountchroma = (float) settings->amchroma;
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.workingProfile);
const double wip[3][3] = {
{wiprof[0][0], wiprof[0][1], wiprof[0][2]},
{wiprof[1][0], wiprof[1][1], wiprof[1][2]},
{wiprof[2][0], wiprof[2][1], wiprof[2][2]}
};
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params->icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params->icm.workingProfile);
const double wp[3][3] = {
{wprof[0][0], wprof[0][1], wprof[0][2]},
{wprof[1][0], wprof[1][1], wprof[1][2]},
diff --git a/rtengine/improcfun.h b/rtengine/improcfun.h
index 92dbcba24..c857d3d05 100644
--- a/rtengine/improcfun.h
+++ b/rtengine/improcfun.h
@@ -52,23 +52,23 @@ class ImProcFunctions
double scale;
bool multiThread;
- void calcVignettingParams (int oW, int oH, const VignettingParams& vignetting, double &w2, double &h2, double& maxRadius, double &v, double &b, double &mul);
+ void calcVignettingParams(int oW, int oH, const VignettingParams& vignetting, double &w2, double &h2, double& maxRadius, double &v, double &b, double &mul);
- void transformLuminanceOnly (Imagefloat* original, Imagefloat* transformed, int cx, int cy, int oW, int oH, int fW, int fH);
+ void transformLuminanceOnly(Imagefloat* original, Imagefloat* transformed, int cx, int cy, int oW, int oH, int fW, int fH);
void transformGeneral(bool highQuality, Imagefloat *original, Imagefloat *transformed, int cx, int cy, int sx, int sy, int oW, int oH, int fW, int fH, const LensCorrection *pLCPMap);
void transformLCPCAOnly(Imagefloat *original, Imagefloat *transformed, int cx, int cy, const LensCorrection *pLCPMap);
- bool needsCA ();
- bool needsDistortion ();
- bool needsRotation ();
- bool needsPerspective ();
- bool needsGradient ();
- bool needsVignetting ();
- bool needsLCP ();
+ bool needsCA();
+ bool needsDistortion();
+ bool needsRotation();
+ bool needsPerspective();
+ bool needsGradient();
+ bool needsVignetting();
+ bool needsLCP();
bool needsLensfun();
// static cmsUInt8Number* Mempro = NULL;
- inline void interpolateTransformCubic (Imagefloat* src, int xs, int ys, double Dx, double Dy, float *r, float *g, float *b, double mul)
+ inline void interpolateTransformCubic(Imagefloat* src, int xs, int ys, double Dx, double Dy, float *r, float *g, float *b, double mul)
{
const double A = -0.85;
@@ -91,9 +91,9 @@ class ImProcFunctions
rd = gd = bd = 0.0;
for (int i = xs, ix = 0; i < xs + 4; i++, ix++) {
- rd += src->r (k, i) * w[ix];
- gd += src->g (k, i) * w[ix];
- bd += src->b (k, i) * w[ix];
+ rd += src->r(k, i) * w[ix];
+ gd += src->g(k, i) * w[ix];
+ bd += src->b(k, i) * w[ix];
}
yr[kx] = rd;
@@ -129,7 +129,7 @@ class ImProcFunctions
// printf ("r=%g, g=%g\n", *r, *g);
}
- inline void interpolateTransformChannelsCubic (float** src, int xs, int ys, double Dx, double Dy, float *r, double mul)
+ inline void interpolateTransformChannelsCubic(float** src, int xs, int ys, double Dx, double Dy, float *r, double mul)
{
const double A = -0.85;
@@ -191,169 +191,173 @@ public:
double lumimul[3];
- ImProcFunctions (const ProcParams* iparams, bool imultiThread = true)
- : monitorTransform (nullptr), params (iparams), scale (1), multiThread (imultiThread), lumimul{} {}
- ~ImProcFunctions ();
- bool needsLuminanceOnly() { return !(needsCA() || needsDistortion() || needsRotation() || needsPerspective() || needsLCP() || needsLensfun()) && (needsVignetting() || needsPCVignetting() || needsGradient());}
- void setScale (double iscale);
+ ImProcFunctions(const ProcParams* iparams, bool imultiThread = true)
+ : monitorTransform(nullptr), params(iparams), scale(1), multiThread(imultiThread), lumimul{} {}
+ ~ImProcFunctions();
+ bool needsLuminanceOnly()
+ {
+ return !(needsCA() || needsDistortion() || needsRotation() || needsPerspective() || needsLCP() || needsLensfun()) && (needsVignetting() || needsPCVignetting() || needsGradient());
+ }
+ void setScale(double iscale);
- bool needsTransform ();
- bool needsPCVignetting ();
+ bool needsTransform();
+ bool needsPCVignetting();
- void firstAnalysis (const Imagefloat* const working, const ProcParams ¶ms, LUTu & vhist16);
- void updateColorProfiles (const Glib::ustring& monitorProfile, RenderingIntent monitorIntent, bool softProof, bool gamutCheck);
- void rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer *pipetteBuffer, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
+ void firstAnalysis(const Imagefloat* const working, const ProcParams ¶ms, LUTu & vhist16);
+ void updateColorProfiles(const Glib::ustring& monitorProfile, RenderingIntent monitorIntent, bool softProof, bool gamutCheck);
+ void rgbProc(Imagefloat* working, LabImage* lab, PipetteBuffer *pipetteBuffer, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve, float satLimit, float satLimitOpacity, const ColorGradientCurve & ctColorCurve, const OpacityCurve & ctOpacityCurve, bool opautili, LUTf & clcurve, LUTf & cl2curve, const ToneCurve & customToneCurve1, const ToneCurve & customToneCurve2,
- const ToneCurve & customToneCurvebw1, const ToneCurve & customToneCurvebw2, double &rrm, double &ggm, double &bbm, float &autor, float &autog, float &autob, DCPProfile *dcpProf, const DCPProfile::ApplyState &asIn, LUTu &histToneCurve );
- void rgbProc (Imagefloat* working, LabImage* lab, PipetteBuffer *pipetteBuffer, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
+ const ToneCurve & customToneCurvebw1, const ToneCurve & customToneCurvebw2, double &rrm, double &ggm, double &bbm, float &autor, float &autog, float &autob, DCPProfile *dcpProf, const DCPProfile::ApplyState &asIn, LUTu &histToneCurve);
+ void rgbProc(Imagefloat* working, LabImage* lab, PipetteBuffer *pipetteBuffer, LUTf & hltonecurve, LUTf & shtonecurve, LUTf & tonecurve,
int sat, LUTf & rCurve, LUTf & gCurve, LUTf & bCurve, float satLimit, float satLimitOpacity, const ColorGradientCurve & ctColorCurve, const OpacityCurve & ctOpacityCurve, bool opautili, LUTf & clcurve, LUTf & cl2curve, const ToneCurve & customToneCurve1, const ToneCurve & customToneCurve2,
- const ToneCurve & customToneCurvebw1, const ToneCurve & customToneCurvebw2, double &rrm, double &ggm, double &bbm, float &autor, float &autog, float &autob,
- double expcomp, int hlcompr, int hlcomprthresh, DCPProfile *dcpProf, const DCPProfile::ApplyState &asIn, LUTu &histToneCurve);
- void labtoning (float r, float g, float b, float &ro, float &go, float &bo, int algm, int metchrom, int twoc, float satLimit, float satLimitOpacity, const ColorGradientCurve & ctColorCurve, const OpacityCurve & ctOpacityCurve, LUTf & clToningcurve, LUTf & cl2Toningcurve, float iplow, float iphigh, double wp[3][3], double wip[3][3] );
- void toning2col (float r, float g, float b, float &ro, float &go, float &bo, float iplow, float iphigh, float rl, float gl, float bl, float rh, float gh, float bh, float SatLow, float SatHigh, float balanS, float balanH, float reducac, int mode, int preser, float strProtect);
- void toningsmh (float r, float g, float b, float &ro, float &go, float &bo, float RedLow, float GreenLow, float BlueLow, float RedMed, float GreenMed, float BlueMed, float RedHigh, float GreenHigh, float BlueHigh, float reducac, int mode, float strProtect);
- void toningsmh2 (float r, float g, float b, float &ro, float &go, float &bo, float low[3], float satLow, float med[3], float satMed, float high[3], float satHigh, float reducac, int mode, int preser);
- void secondeg_begin (float reducac, float vend, float &aam, float &bbm);
- void secondeg_end (float reducac, float vinf, float &aa, float &bb, float &cc);
+ const ToneCurve & customToneCurvebw1, const ToneCurve & customToneCurvebw2, double &rrm, double &ggm, double &bbm, float &autor, float &autog, float &autob,
+ double expcomp, int hlcompr, int hlcomprthresh, DCPProfile *dcpProf, const DCPProfile::ApplyState &asIn, LUTu &histToneCurve);
+ void labtoning(float r, float g, float b, float &ro, float &go, float &bo, int algm, int metchrom, int twoc, float satLimit, float satLimitOpacity, const ColorGradientCurve & ctColorCurve, const OpacityCurve & ctOpacityCurve, LUTf & clToningcurve, LUTf & cl2Toningcurve, float iplow, float iphigh, double wp[3][3], double wip[3][3]);
+ void toning2col(float r, float g, float b, float &ro, float &go, float &bo, float iplow, float iphigh, float rl, float gl, float bl, float rh, float gh, float bh, float SatLow, float SatHigh, float balanS, float balanH, float reducac, int mode, int preser, float strProtect);
+ void toningsmh(float r, float g, float b, float &ro, float &go, float &bo, float RedLow, float GreenLow, float BlueLow, float RedMed, float GreenMed, float BlueMed, float RedHigh, float GreenHigh, float BlueHigh, float reducac, int mode, float strProtect);
+ void toningsmh2(float r, float g, float b, float &ro, float &go, float &bo, float low[3], float satLow, float med[3], float satMed, float high[3], float satHigh, float reducac, int mode, int preser);
+ void secondeg_begin(float reducac, float vend, float &aam, float &bbm);
+ void secondeg_end(float reducac, float vinf, float &aa, float &bb, float &cc);
- void retreavergb (float &r, float &g, float &b);
- void moyeqt (Imagefloat* working, float &moyS, float &eqty);
+ void retreavergb(float &r, float &g, float &b);
+ void moyeqt(Imagefloat* working, float &moyS, float &eqty);
- void luminanceCurve (LabImage* lold, LabImage* lnew, LUTf &curve);
- void ciecam_02float (CieImage* ncie, float adap, int pW, int pwb, LabImage* lab, const ProcParams* params,
- const ColorAppearance & customColCurve1, const ColorAppearance & customColCurve, const ColorAppearance & customColCurve3,
- LUTu &histLCAM, LUTu &histCCAM, LUTf & CAMBrightCurveJ, LUTf & CAMBrightCurveQ, float &mean, int Iterates, int scale, bool execsharp, float &d, float &dj, float &yb, int rtt,
- bool showSharpMask = false);
- void chromiLuminanceCurve (PipetteBuffer *pipetteBuffer, int pW, LabImage* lold, LabImage* lnew, LUTf &acurve, LUTf &bcurve, LUTf & satcurve, LUTf & satclcurve, LUTf &clcurve, LUTf &curve, bool utili, bool autili, bool butili, bool ccutili, bool cclutili, bool clcutili, LUTu &histCCurve, LUTu &histLurve);
- void vibrance (LabImage* lab);//Jacques' vibrance
+ void luminanceCurve(LabImage* lold, LabImage* lnew, LUTf &curve);
+ void ciecam_02float(CieImage* ncie, float adap, int pW, int pwb, LabImage* lab, const ProcParams* params,
+ const ColorAppearance & customColCurve1, const ColorAppearance & customColCurve, const ColorAppearance & customColCurve3,
+ LUTu &histLCAM, LUTu &histCCAM, LUTf & CAMBrightCurveJ, LUTf & CAMBrightCurveQ, float &mean, int Iterates, int scale, bool execsharp, float &d, float &dj, float &yb, int rtt,
+ bool showSharpMask = false);
+ void chromiLuminanceCurve(PipetteBuffer *pipetteBuffer, int pW, LabImage* lold, LabImage* lnew, LUTf &acurve, LUTf &bcurve, LUTf & satcurve, LUTf & satclcurve, LUTf &clcurve, LUTf &curve, bool utili, bool autili, bool butili, bool ccutili, bool cclutili, bool clcutili, LUTu &histCCurve, LUTu &histLurve);
+ void vibrance(LabImage* lab); //Jacques' vibrance
// void colorCurve (LabImage* lold, LabImage* lnew);
- void sharpening (LabImage* lab, const SharpeningParams &sharpenParam, bool showMask = false);
- void sharpeningcam (CieImage* ncie, float** buffer, bool showMask = false);
- void transform (Imagefloat* original, Imagefloat* transformed, int cx, int cy, int sx, int sy, int oW, int oH, int fW, int fH, const FramesMetaData *metadata, int rawRotationDeg, bool fullImage);
- float resizeScale (const ProcParams* params, int fw, int fh, int &imw, int &imh);
- void lab2monitorRgb (LabImage* lab, Image8* image);
- void resize (Imagefloat* src, Imagefloat* dst, float dScale);
- void Lanczos (const LabImage* src, LabImage* dst, float scale);
- void Lanczos (const Imagefloat* src, Imagefloat* dst, float scale);
+ void sharpening(LabImage* lab, const SharpeningParams &sharpenParam, bool showMask = false);
+ void sharpeningcam(CieImage* ncie, float** buffer, bool showMask = false);
+ void transform(Imagefloat* original, Imagefloat* transformed, int cx, int cy, int sx, int sy, int oW, int oH, int fW, int fH, const FramesMetaData *metadata, int rawRotationDeg, bool fullImage);
+ float resizeScale(const ProcParams* params, int fw, int fh, int &imw, int &imh);
+ void lab2monitorRgb(LabImage* lab, Image8* image);
+ void resize(Imagefloat* src, Imagefloat* dst, float dScale);
+ void Lanczos(const LabImage* src, LabImage* dst, float scale);
+ void Lanczos(const Imagefloat* src, Imagefloat* dst, float scale);
- void deconvsharpening (float** luminance, float** buffer, int W, int H, const SharpeningParams &sharpenParam);
- void MLsharpen (LabImage* lab);// Manuel's clarity / sharpening
- void MLmicrocontrast (float** luminance, int W, int H ); //Manuel's microcontrast
- void MLmicrocontrast (LabImage* lab ); //Manuel's microcontrast
- void MLmicrocontrastcam (CieImage* ncie ); //Manuel's microcontrast
+ void deconvsharpening(float** luminance, float** buffer, int W, int H, const SharpeningParams &sharpenParam);
+ void MLsharpen(LabImage* lab); // Manuel's clarity / sharpening
+ void MLmicrocontrast(float** luminance, int W, int H); //Manuel's microcontrast
+ void MLmicrocontrast(LabImage* lab); //Manuel's microcontrast
+ void MLmicrocontrastcam(CieImage* ncie); //Manuel's microcontrast
- void impulsedenoise (LabImage* lab);//Emil's impulse denoise
- void impulsedenoisecam (CieImage* ncie, float **buffers[3]);
- void impulse_nr (LabImage* lab, double thresh);
- void impulse_nrcam (CieImage* ncie, double thresh, float **buffers[3]);
+ void impulsedenoise(LabImage* lab); //Emil's impulse denoise
+ void impulsedenoisecam(CieImage* ncie, float **buffers[3]);
+ void impulse_nr(LabImage* lab, double thresh);
+ void impulse_nrcam(CieImage* ncie, double thresh, float **buffers[3]);
- void dirpyrdenoise (LabImage* src);//Emil's pyramid denoise
- void dirpyrequalizer (LabImage* lab, int scale);//Emil's wavelet
+ void dirpyrdenoise(LabImage* src); //Emil's pyramid denoise
+ void dirpyrequalizer(LabImage* lab, int scale); //Emil's wavelet
- void EPDToneMapResid (float * WavCoeffs_L0, unsigned int Iterates, int skip, struct cont_params& cp, int W_L, int H_L, float max0, float min0);
- float *CompressDR (float *Source, int W_L, int H_L, float Compression, float DetailBoost, float *Compressed);
- void ContrastResid (float * WavCoeffs_L0, struct cont_params &cp, int W_L, int H_L, float max0, float min0);
- float *ContrastDR (float *Source, int W_L, int H_L, float *Contrast = nullptr);
+ void EPDToneMapResid(float * WavCoeffs_L0, unsigned int Iterates, int skip, struct cont_params& cp, int W_L, int H_L, float max0, float min0);
+ float *CompressDR(float *Source, int W_L, int H_L, float Compression, float DetailBoost, float *Compressed);
+ void ContrastResid(float * WavCoeffs_L0, struct cont_params &cp, int W_L, int H_L, float max0, float min0);
+ float *ContrastDR(float *Source, int W_L, int H_L, float *Contrast = nullptr);
- void EPDToneMap (LabImage *lab, unsigned int Iterates = 0, int skip = 1);
- void EPDToneMapCIE (CieImage *ncie, float a_w, float c_, int Wid, int Hei, float minQ, float maxQ, unsigned int Iterates = 0, int skip = 1);
+ void EPDToneMap(LabImage *lab, unsigned int Iterates = 0, int skip = 1);
+ void EPDToneMapCIE(CieImage *ncie, float a_w, float c_, int Wid, int Hei, float minQ, float maxQ, unsigned int Iterates = 0, int skip = 1);
// pyramid denoise
procparams::DirPyrDenoiseParams dnparams;
- void dirpyr (LabImage* data_fine, LabImage* data_coarse, int level, LUTf &rangefn_L, LUTf &rangefn_ab,
- int pitch, int scale, const int luma, int chroma );
- void idirpyr (LabImage* data_coarse, LabImage* data_fine, int level, LUTf &rangefn_L, LUTf & nrwt_l, LUTf & nrwt_ab,
- int pitch, int scale, const int luma, const int chroma/*, LUTf & Lcurve, LUTf & abcurve*/ );
+ void dirpyr(LabImage* data_fine, LabImage* data_coarse, int level, LUTf &rangefn_L, LUTf &rangefn_ab,
+ int pitch, int scale, const int luma, int chroma);
+ void idirpyr(LabImage* data_coarse, LabImage* data_fine, int level, LUTf &rangefn_L, LUTf & nrwt_l, LUTf & nrwt_ab,
+ int pitch, int scale, const int luma, const int chroma/*, LUTf & Lcurve, LUTf & abcurve*/);
- void Tile_calc (int tilesize, int overlap, int kall, int imwidth, int imheight, int &numtiles_W, int &numtiles_H, int &tilewidth, int &tileheight, int &tileWskip, int &tileHskip);
- void ip_wavelet (LabImage * lab, LabImage * dst, int kall, const procparams::WaveletParams & waparams, const WavCurve & wavCLVCcurve, const WavOpacityCurveRG & waOpacityCurveRG, const WavOpacityCurveBY & waOpacityCurveBY, const WavOpacityCurveW & waOpacityCurveW, const WavOpacityCurveWL & waOpacityCurveWL, LUTf &wavclCurve, int skip);
+ void Tile_calc(int tilesize, int overlap, int kall, int imwidth, int imheight, int &numtiles_W, int &numtiles_H, int &tilewidth, int &tileheight, int &tileWskip, int &tileHskip);
+ void ip_wavelet(LabImage * lab, LabImage * dst, int kall, const procparams::WaveletParams & waparams, const WavCurve & wavCLVCcurve, const WavOpacityCurveRG & waOpacityCurveRG, const WavOpacityCurveBY & waOpacityCurveBY, const WavOpacityCurveW & waOpacityCurveW, const WavOpacityCurveWL & waOpacityCurveWL, LUTf &wavclCurve, int skip);
- void WaveletcontAllL (LabImage * lab, float **varhue, float **varchrom, wavelet_decomposition &WaveletCoeffs_L,
- struct cont_params &cp, int skip, float *mean, float *sigma, float *MaxP, float *MaxN, const WavCurve & wavCLVCcurve, const WavOpacityCurveW & waOpacityCurveW, FlatCurve* ChCurve, bool Chutili);
- void WaveletcontAllLfinal (wavelet_decomposition &WaveletCoeffs_L, struct cont_params &cp, float *mean, float *sigma, float *MaxP, const WavOpacityCurveWL & waOpacityCurveWL);
- void WaveletcontAllAB (LabImage * lab, float **varhue, float **varchrom, wavelet_decomposition &WaveletCoeffs_a, const WavOpacityCurveW & waOpacityCurveW,
- struct cont_params &cp, const bool useChannelA);
- void WaveletAandBAllAB (wavelet_decomposition &WaveletCoeffs_a, wavelet_decomposition &WaveletCoeffs_b,
- struct cont_params &cp, FlatCurve* hhcurve, bool hhutili);
- void ContAllL (float **koeLi, float *maxkoeLi, bool lipschitz, int maxlvl, LabImage * lab, float **varhue, float **varchrom, float ** WavCoeffs_L, float * WavCoeffs_L0, int level, int dir, struct cont_params &cp,
- int W_L, int H_L, int skip, float *mean, float *sigma, float *MaxP, float *MaxN, const WavCurve & wavCLVCcurve, const WavOpacityCurveW & waOpacityCurveW, FlatCurve* ChCurve, bool Chutili);
- void finalContAllL (float ** WavCoeffs_L, float * WavCoeffs_L0, int level, int dir, struct cont_params &cp,
- int W_L, int H_L, float *mean, float *sigma, float *MaxP, const WavOpacityCurveWL & waOpacityCurveWL);
- void ContAllAB (LabImage * lab, int maxlvl, float **varhue, float **varchrom, float ** WavCoeffs_a, float * WavCoeffs_a0, int level, int dir, const WavOpacityCurveW & waOpacityCurveW, struct cont_params &cp,
- int W_ab, int H_ab, const bool useChannelA);
- void Evaluate2 (wavelet_decomposition &WaveletCoeffs_L,
- float *mean, float *meanN, float *sigma, float *sigmaN, float *MaxP, float *MaxN);
- void Eval2 (float ** WavCoeffs_L, int level,
- int W_L, int H_L, float *mean, float *meanN, float *sigma, float *sigmaN, float *MaxP, float *MaxN);
+ void WaveletcontAllL(LabImage * lab, float **varhue, float **varchrom, wavelet_decomposition &WaveletCoeffs_L,
+ struct cont_params &cp, int skip, float *mean, float *sigma, float *MaxP, float *MaxN, const WavCurve & wavCLVCcurve, const WavOpacityCurveW & waOpacityCurveW, FlatCurve* ChCurve, bool Chutili);
+ void WaveletcontAllLfinal(wavelet_decomposition &WaveletCoeffs_L, struct cont_params &cp, float *mean, float *sigma, float *MaxP, const WavOpacityCurveWL & waOpacityCurveWL);
+ void WaveletcontAllAB(LabImage * lab, float **varhue, float **varchrom, wavelet_decomposition &WaveletCoeffs_a, const WavOpacityCurveW & waOpacityCurveW,
+ struct cont_params &cp, const bool useChannelA);
+ void WaveletAandBAllAB(wavelet_decomposition &WaveletCoeffs_a, wavelet_decomposition &WaveletCoeffs_b,
+ struct cont_params &cp, FlatCurve* hhcurve, bool hhutili);
+ void ContAllL(float **koeLi, float *maxkoeLi, bool lipschitz, int maxlvl, LabImage * lab, float **varhue, float **varchrom, float ** WavCoeffs_L, float * WavCoeffs_L0, int level, int dir, struct cont_params &cp,
+ int W_L, int H_L, int skip, float *mean, float *sigma, float *MaxP, float *MaxN, const WavCurve & wavCLVCcurve, const WavOpacityCurveW & waOpacityCurveW, FlatCurve* ChCurve, bool Chutili);
+ void finalContAllL(float ** WavCoeffs_L, float * WavCoeffs_L0, int level, int dir, struct cont_params &cp,
+ int W_L, int H_L, float *mean, float *sigma, float *MaxP, const WavOpacityCurveWL & waOpacityCurveWL);
+ void ContAllAB(LabImage * lab, int maxlvl, float **varhue, float **varchrom, float ** WavCoeffs_a, float * WavCoeffs_a0, int level, int dir, const WavOpacityCurveW & waOpacityCurveW, struct cont_params &cp,
+ int W_ab, int H_ab, const bool useChannelA);
+ void Evaluate2(wavelet_decomposition &WaveletCoeffs_L,
+ float *mean, float *meanN, float *sigma, float *sigmaN, float *MaxP, float *MaxN);
+ void Eval2(float ** WavCoeffs_L, int level,
+ int W_L, int H_L, float *mean, float *meanN, float *sigma, float *sigmaN, float *MaxP, float *MaxN);
- void Aver (float * HH_Coeffs, int datalen, float &averagePlus, float &averageNeg, float &max, float &min);
- void Sigma (float * HH_Coeffs, int datalen, float averagePlus, float averageNeg, float &sigmaPlus, float &sigmaNeg);
- void calckoe (float ** WavCoeffs_LL, const struct cont_params& cp, float ** koeLi, int level, int dir, int W_L, int H_L, float edd, float *maxkoeLi, float **tmC = nullptr);
+ void Aver(float * HH_Coeffs, int datalen, float &averagePlus, float &averageNeg, float &max, float &min);
+ void Sigma(float * HH_Coeffs, int datalen, float averagePlus, float averageNeg, float &sigmaPlus, float &sigmaNeg);
+ void calckoe(float ** WavCoeffs_LL, const struct cont_params& cp, float ** koeLi, int level, int dir, int W_L, int H_L, float edd, float *maxkoeLi, float **tmC = nullptr);
- void Median_Denoise ( float **src, float **dst, int width, int height, Median medianType, int iterations, int numThreads, float **buffer = nullptr);
- void Median_Denoise ( float **src, float **dst, float upperBound, int width, int height, Median medianType, int iterations, int numThreads, float **buffer = nullptr);
- void RGB_denoise (int kall, Imagefloat * src, Imagefloat * dst, Imagefloat * calclum, float * ch_M, float *max_r, float *max_b, bool isRAW, const procparams::DirPyrDenoiseParams & dnparams, const double expcomp, const NoiseCurve & noiseLCurve, const NoiseCurve & noiseCCurve, float &nresi, float &highresi);
- void RGB_denoise_infoGamCurve (const procparams::DirPyrDenoiseParams & dnparams, const bool isRAW, LUTf &gamcurve, float &gam, float &gamthresh, float &gamslope);
- void RGB_denoise_info (Imagefloat * src, Imagefloat * provicalc, bool isRAW, LUTf &gamcurve, float gam, float gamthresh, float gamslope, const procparams::DirPyrDenoiseParams & dnparams, const double expcomp, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float & maxblueaut, float &minredaut, float & minblueaut, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc, bool multiThread = false);
- void RGBtile_denoise (float * fLblox, int hblproc, float noisevar_Ldetail, float * nbrwt, float * blurbuffer ); //for DCT
- void RGBoutput_tile_row (float *bloxrow_L, float ** Ldetail, float ** tilemask_out, int height, int width, int top );
- bool WaveletDenoiseAllL (wavelet_decomposition &WaveletCoeffs_L, float *noisevarlum, float madL[8][3], float * vari, int edge);
- bool WaveletDenoiseAllAB (wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float *noisevarchrom, float madL[8][3], float noisevar_ab, const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb);
- void WaveletDenoiseAll_info (int levwav, wavelet_decomposition &WaveletCoeffs_a,
- wavelet_decomposition &WaveletCoeffs_b, float **noisevarlum, float **noisevarchrom, float **noisevarhue, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float &maxblueaut, float &minredaut, float & minblueaut, int schoice, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc,
- float &maxchred, float &maxchblue, float &minchred, float &minchblue, int &nb, float &chau, float &chred, float &chblue, bool denoiseMethodRgb);
+ void Median_Denoise(float **src, float **dst, int width, int height, Median medianType, int iterations, int numThreads, float **buffer = nullptr);
+ void Median_Denoise(float **src, float **dst, float upperBound, int width, int height, Median medianType, int iterations, int numThreads, float **buffer = nullptr);
+ void RGB_denoise(int kall, Imagefloat * src, Imagefloat * dst, Imagefloat * calclum, float * ch_M, float *max_r, float *max_b, bool isRAW, const procparams::DirPyrDenoiseParams & dnparams, const double expcomp, const NoiseCurve & noiseLCurve, const NoiseCurve & noiseCCurve, float &nresi, float &highresi);
+ void RGB_denoise_infoGamCurve(const procparams::DirPyrDenoiseParams & dnparams, const bool isRAW, LUTf &gamcurve, float &gam, float &gamthresh, float &gamslope);
+ void RGB_denoise_info(Imagefloat * src, Imagefloat * provicalc, bool isRAW, LUTf &gamcurve, float gam, float gamthresh, float gamslope, const procparams::DirPyrDenoiseParams & dnparams, const double expcomp, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float & maxblueaut, float &minredaut, float & minblueaut, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc, bool multiThread = false);
+ void RGBtile_denoise(float * fLblox, int hblproc, float noisevar_Ldetail, float * nbrwt, float * blurbuffer); //for DCT
+ void RGBoutput_tile_row(float *bloxrow_L, float ** Ldetail, float ** tilemask_out, int height, int width, int top);
+ bool WaveletDenoiseAllL(wavelet_decomposition &WaveletCoeffs_L, float *noisevarlum, float madL[8][3], float * vari, int edge);
+ bool WaveletDenoiseAllAB(wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float *noisevarchrom, float madL[8][3], float noisevar_ab, const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb);
+ void WaveletDenoiseAll_info(int levwav, wavelet_decomposition &WaveletCoeffs_a,
+ wavelet_decomposition &WaveletCoeffs_b, float **noisevarlum, float **noisevarchrom, float **noisevarhue, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float &maxblueaut, float &minredaut, float & minblueaut, int schoice, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc,
+ float &maxchred, float &maxchblue, float &minchred, float &minchblue, int &nb, float &chau, float &chred, float &chblue, bool denoiseMethodRgb);
- bool WaveletDenoiseAll_BiShrinkL (wavelet_decomposition &WaveletCoeffs_L, float *noisevarlum, float madL[8][3]);
- bool WaveletDenoiseAll_BiShrinkAB (wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float *noisevarchrom, float madL[8][3], float noisevar_ab,
- const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb);
- void ShrinkAllL (wavelet_decomposition &WaveletCoeffs_L, float **buffer, int level, int dir, float *noisevarlum, float * madL, float * vari, int edge);
- void ShrinkAllAB (wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float **buffer, int level, int dir,
- float *noisevarchrom, float noisevar_ab, const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb, float * madL, float * madaab = nullptr, bool madCalculated = false);
- void ShrinkAll_info (float ** WavCoeffs_a, float ** WavCoeffs_b,
- int W_ab, int H_ab, float **noisevarlum, float **noisevarchrom, float **noisevarhue, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float &maxblueaut, float &minredaut, float &minblueaut, int schoice, int lvl, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc,
- float &maxchred, float &maxchblue, float &minchred, float &minchblue, int &nb, float &chau, float &chred, float &chblue, bool denoiseMethodRgb);
- void Noise_residualAB (wavelet_decomposition &WaveletCoeffs_ab, float &chresid, float &chmaxresid, bool denoiseMethodRgb);
- void calcautodn_info (float &chaut, float &delta, int Nb, int levaut, float maxmax, float lumema, float chromina, int mode, int lissage, float redyel, float skinc, float nsknc);
- float MadMax (float * DataList, int &max, int datalen);
- float Mad (float * DataList, const int datalen);
- float MadRgb (float * DataList, const int datalen);
+ bool WaveletDenoiseAll_BiShrinkL(wavelet_decomposition &WaveletCoeffs_L, float *noisevarlum, float madL[8][3]);
+ bool WaveletDenoiseAll_BiShrinkAB(wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float *noisevarchrom, float madL[8][3], float noisevar_ab,
+ const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb);
+ void ShrinkAllL(wavelet_decomposition &WaveletCoeffs_L, float **buffer, int level, int dir, float *noisevarlum, float * madL, float * vari, int edge);
+ void ShrinkAllAB(wavelet_decomposition &WaveletCoeffs_L, wavelet_decomposition &WaveletCoeffs_ab, float **buffer, int level, int dir,
+ float *noisevarchrom, float noisevar_ab, const bool useNoiseCCurve, bool autoch, bool denoiseMethodRgb, float * madL, float * madaab = nullptr, bool madCalculated = false);
+ void ShrinkAll_info(float ** WavCoeffs_a, float ** WavCoeffs_b,
+ int W_ab, int H_ab, float **noisevarlum, float **noisevarchrom, float **noisevarhue, float &chaut, int &Nb, float &redaut, float &blueaut, float &maxredaut, float &maxblueaut, float &minredaut, float &minblueaut, int schoice, int lvl, float &chromina, float &sigma, float &lumema, float &sigma_L, float &redyel, float &skinc, float &nsknc,
+ float &maxchred, float &maxchblue, float &minchred, float &minchblue, int &nb, float &chau, float &chred, float &chblue, bool denoiseMethodRgb);
+ void Noise_residualAB(wavelet_decomposition &WaveletCoeffs_ab, float &chresid, float &chmaxresid, bool denoiseMethodRgb);
+ void calcautodn_info(float &chaut, float &delta, int Nb, int levaut, float maxmax, float lumema, float chromina, int mode, int lissage, float redyel, float skinc, float nsknc);
+ float MadMax(float * DataList, int &max, int datalen);
+ float Mad(float * DataList, const int datalen);
+ float MadRgb(float * DataList, const int datalen);
// pyramid wavelet
- void dirpyr_equalizer (float ** src, float ** dst, int srcwidth, int srcheight, float ** l_a, float ** l_b, const double * mult, const double dirpyrThreshold, const double skinprot, float b_l, float t_l, float t_r, int scale);//Emil's directional pyramid wavelet
- void dirpyr_equalizercam (CieImage* ncie, float ** src, float ** dst, int srcwidth, int srcheight, float ** h_p, float ** C_p, const double * mult, const double dirpyrThreshold, const double skinprot, bool execdir, float b_l, float t_l, float t_r, int scale);//Emil's directional pyramid wavelet
- void dirpyr_channel (float ** data_fine, float ** data_coarse, int width, int height, int level, int scale);
- void idirpyr_eq_channel (float ** data_coarse, float ** data_fine, float ** buffer, int width, int height, int level, float multi[6], const double dirpyrThreshold, float ** l_a_h, float ** l_b_c, const double skinprot, float b_l, float t_l, float t_r);
- void idirpyr_eq_channelcam (float ** data_coarse, float ** data_fine, float ** buffer, int width, int height, int level, float multi[6], const double dirpyrThreshold, float ** l_a_h, float ** l_b_c, const double skinprot, float b_l, float t_l, float t_r);
- void defringe (LabImage* lab);
- void defringecam (CieImage* ncie);
- void badpixcam (CieImage* ncie, double rad, int thr, int mode, float chrom, bool hotbad);
- void badpixlab (LabImage* lab, double rad, int thr, float chrom);
+ void dirpyr_equalizer(float ** src, float ** dst, int srcwidth, int srcheight, float ** l_a, float ** l_b, const double * mult, const double dirpyrThreshold, const double skinprot, float b_l, float t_l, float t_r, int scale); //Emil's directional pyramid wavelet
+ void dirpyr_equalizercam(CieImage* ncie, float ** src, float ** dst, int srcwidth, int srcheight, float ** h_p, float ** C_p, const double * mult, const double dirpyrThreshold, const double skinprot, bool execdir, float b_l, float t_l, float t_r, int scale); //Emil's directional pyramid wavelet
+ void dirpyr_channel(float ** data_fine, float ** data_coarse, int width, int height, int level, int scale);
+ void idirpyr_eq_channel(float ** data_coarse, float ** data_fine, float ** buffer, int width, int height, int level, float multi[6], const double dirpyrThreshold, float ** l_a_h, float ** l_b_c, const double skinprot, float b_l, float t_l, float t_r);
+ void idirpyr_eq_channelcam(float ** data_coarse, float ** data_fine, float ** buffer, int width, int height, int level, float multi[6], const double dirpyrThreshold, float ** l_a_h, float ** l_b_c, const double skinprot, float b_l, float t_l, float t_r);
+ void defringe(LabImage* lab);
+ void defringecam(CieImage* ncie);
+ void badpixcam(CieImage* ncie, double rad, int thr, int mode, float chrom, bool hotbad);
+ void badpixlab(LabImage* lab, double rad, int thr, float chrom);
- void PF_correct_RT (LabImage * lab, double radius, int thresh);
- void PF_correct_RTcam (CieImage * ncie, double radius, int thresh);
- void Badpixelscam (CieImage * ncie, double radius, int thresh, int mode, float chrom, bool hotbad);
- void BadpixelsLab (LabImage * lab, double radius, int thresh, float chrom);
+ void PF_correct_RT(LabImage * lab, double radius, int thresh);
+ void PF_correct_RTcam(CieImage * ncie, double radius, int thresh);
+ void Badpixelscam(CieImage * ncie, double radius, int thresh, int mode, float chrom, bool hotbad);
+ void BadpixelsLab(LabImage * lab, double radius, int thresh, float chrom);
void ToneMapFattal02(Imagefloat *rgb);
void localContrast(LabImage *lab);
void colorToningLabGrid(LabImage *lab, int xstart, int xend, int ystart, int yend, bool MultiThread);
void shadowsHighlights(LabImage *lab);
void softLight(float *red, float *green, float *blue, int istart, int jstart, int tW, int tH, int TS);
-
- Image8* lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, bool consider_histogram_settings=true);
- Imagefloat* lab2rgbOut (LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, GammaValues *ga = nullptr);
- // CieImage *ciec;
- bool transCoord (int W, int H, int x, int y, int w, int h, int& xv, int& yv, int& wv, int& hv, double ascaleDef = -1, const LensCorrection *pLCPMap = nullptr);
- bool transCoord (int W, int H, const std::vector &src, std::vector &red, std::vector &green, std::vector &blue, double ascaleDef = -1, const LensCorrection *pLCPMap = nullptr);
- static void getAutoExp (const LUTu & histogram, int histcompr, double clip, double& expcomp, int& bright, int& contr, int& black, int& hlcompr, int& hlcomprthresh);
- static double getAutoDistor (const Glib::ustring& fname, int thumb_size);
- double getTransformAutoFill (int oW, int oH, const LensCorrection *pLCPMap = nullptr);
- void rgb2lab (const Imagefloat &src, LabImage &dst, const Glib::ustring &workingSpace);
- void lab2rgb (const LabImage &src, Imagefloat &dst, const Glib::ustring &workingSpace);
+ Image8* lab2rgb(LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, bool consider_histogram_settings = true);
+ Imagefloat* lab2rgbOut(LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm);
+ // CieImage *ciec;
+ Imagefloat* workingtrc(Imagefloat* working, int cw, int ch, int mul, Glib::ustring profile, double gampos, double slpos);
+
+ bool transCoord(int W, int H, int x, int y, int w, int h, int& xv, int& yv, int& wv, int& hv, double ascaleDef = -1, const LensCorrection *pLCPMap = nullptr);
+ bool transCoord(int W, int H, const std::vector &src, std::vector &red, std::vector &green, std::vector &blue, double ascaleDef = -1, const LensCorrection *pLCPMap = nullptr);
+ static void getAutoExp(const LUTu & histogram, int histcompr, double clip, double& expcomp, int& bright, int& contr, int& black, int& hlcompr, int& hlcomprthresh);
+ static double getAutoDistor(const Glib::ustring& fname, int thumb_size);
+ double getTransformAutoFill(int oW, int oH, const LensCorrection *pLCPMap = nullptr);
+ void rgb2lab(const Imagefloat &src, LabImage &dst, const Glib::ustring &workingSpace);
+ void lab2rgb(const LabImage &src, Imagefloat &dst, const Glib::ustring &workingSpace);
};
}
#endif
diff --git a/rtengine/iplab2rgb.cc b/rtengine/iplab2rgb.cc
index 4838ea1f7..cab77c8ab 100644
--- a/rtengine/iplab2rgb.cc
+++ b/rtengine/iplab2rgb.cc
@@ -26,7 +26,6 @@
#include "curves.h"
#include "alignedbuffer.h"
#include "color.h"
-
namespace rtengine
{
@@ -93,7 +92,7 @@ inline void copyAndClamp(const LabImage *src, unsigned char *dst, const double r
//
// If monitorTransform, divide by 327.68 then apply monitorTransform (which can integrate soft-proofing)
// otherwise divide by 327.68, convert to xyz and apply the sRGB transform, before converting with gamma2curve
-void ImProcFunctions::lab2monitorRgb (LabImage* lab, Image8* image)
+void ImProcFunctions::lab2monitorRgb(LabImage* lab, Image8* image)
{
if (monitorTransform) {
@@ -111,11 +110,12 @@ void ImProcFunctions::lab2monitorRgb (LabImage* lab, Image8* image)
AlignedBuffer gwBuf1;
AlignedBuffer gwBuf2;
+
if (gamutWarning) {
gwBuf1.resize(3 * lab->W);
gwBuf2.resize(3 * lab->W);
}
-
+
float *buffer = pBuf.data;
float *outbuffer = mBuf.data;
@@ -160,7 +160,7 @@ void ImProcFunctions::lab2monitorRgb (LabImage* lab, Image8* image)
//
// If output profile used, divide by 327.68 then apply the "profile" profile (eventually with a standard gamma)
// otherwise divide by 327.68, convert to xyz and apply the RGB transform, before converting with gamma2curve
-Image8* ImProcFunctions::lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, bool consider_histogram_settings)
+Image8* ImProcFunctions::lab2rgb(LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, bool consider_histogram_settings)
{
//gamutmap(lab);
@@ -180,23 +180,25 @@ Image8* ImProcFunctions::lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch,
ch = lab->H - cy;
}
- Image8* image = new Image8 (cw, ch);
+ Image8* image = new Image8(cw, ch);
Glib::ustring profile;
bool standard_gamma;
- if(settings->HistogramWorking && consider_histogram_settings) {
- profile = icm.working;
+ if (settings->HistogramWorking && consider_histogram_settings) {
+ profile = icm.workingProfile;
standard_gamma = true;
} else {
- profile = icm.output;
- if (icm.output.empty() || icm.output == ColorManagementParams::NoICMString) {
+ profile = icm.outputProfile;
+
+ if (icm.outputProfile.empty() || icm.outputProfile == ColorManagementParams::NoICMString) {
profile = "sRGB";
}
+
standard_gamma = false;
}
- cmsHPROFILE oprof = ICCStore::getInstance()->getProfile (profile);
+ cmsHPROFILE oprof = ICCStore::getInstance()->getProfile(profile);
if (oprof) {
cmsHPROFILE oprofG = oprof;
@@ -206,14 +208,16 @@ Image8* ImProcFunctions::lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch,
}
cmsUInt32Number flags = cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE;
+
if (icm.outputBPC) {
flags |= cmsFLAGS_BLACKPOINTCOMPENSATION;
}
- lcmsMutex->lock ();
+
+ lcmsMutex->lock();
cmsHPROFILE LabIProf = cmsCreateLab4Profile(nullptr);
cmsHTRANSFORM hTransform = cmsCreateTransform (LabIProf, TYPE_Lab_DBL, oprofG, TYPE_RGB_FLT, icm.outputIntent, flags); // NOCACHE is important for thread safety
cmsCloseProfile(LabIProf);
- lcmsMutex->unlock ();
+ lcmsMutex->unlock();
unsigned char *data = image->data;
@@ -256,7 +260,7 @@ Image8* ImProcFunctions::lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch,
cmsCloseProfile(oprofG);
}
} else {
- const auto xyz_rgb = ICCStore::getInstance()->workingSpaceInverseMatrix (profile);
+ const auto xyz_rgb = ICCStore::getInstance()->workingSpaceInverseMatrix(profile);
copyAndClamp(lab, image->data, xyz_rgb, multiThread);
}
@@ -279,7 +283,7 @@ Image8* ImProcFunctions::lab2rgb (LabImage* lab, int cx, int cy, int cw, int ch,
* If a custom gamma profile can be created, divide by 327.68, convert to xyz and apply the custom gamma transform
* otherwise divide by 327.68, convert to xyz and apply the sRGB transform, before converting with gamma2curve
*/
-Imagefloat* ImProcFunctions::lab2rgbOut (LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm, GammaValues *ga)
+Imagefloat* ImProcFunctions::lab2rgbOut(LabImage* lab, int cx, int cy, int cw, int ch, const procparams::ColorManagementParams &icm)
{
if (cx < 0) {
@@ -298,27 +302,92 @@ Imagefloat* ImProcFunctions::lab2rgbOut (LabImage* lab, int cx, int cy, int cw,
ch = lab->H - cy;
}
- Imagefloat* image = new Imagefloat (cw, ch);
+ Imagefloat* image = new Imagefloat(cw, ch);
cmsHPROFILE oprof = nullptr;
- if (ga) {
- lcmsMutex->lock ();
- ICCStore::getInstance()->getGammaArray(icm, *ga);
- oprof = ICCStore::getInstance()->createGammaProfile(icm, *ga);
- lcmsMutex->unlock ();
- } else {
- oprof = ICCStore::getInstance()->getProfile (icm.output);
+
+ oprof = ICCStore::getInstance()->getProfile(icm.outputProfile);
+ Glib::ustring outtest = icm.outputProfile;
+ std::string fileis_RTv2 = outtest.substr(0, 4);
+ //printf("IsRTv2=%s\n", fileis_RTv2.c_str());
+ if(fileis_RTv2 == "RTv2") {//Only fot ICC v2 : read tag from desc to retrieve gamma and slope save before in generate ICC v2
+ //due to bug in LCMS in CmsToneCurve
+ //printf("icmout=%s \n",icm.output.c_str());
+ GammaValues g_b; //gamma parameters
+ const double eps = 0.000000001; // not divide by zero
+ double gammatag = 2.4;
+ double slopetag = 12.92310;
+ cmsMLU *modelDescMLU = (cmsMLU*) (cmsReadTag(oprof, cmsSigDeviceModelDescTag));
+ if (modelDescMLU) {
+ cmsUInt32Number count = cmsMLUgetWide(modelDescMLU, "en", "US", nullptr, 0); // get buffer length first
+ if (count) {
+ wchar_t *buffer = new wchar_t[count];
+ count = cmsMLUgetWide(modelDescMLU, "en", "US", buffer, count); // now put the string in the buffer
+ Glib::ustring modelDesc;
+#if __SIZEOF_WCHAR_T__ == 2
+ char* cModelDesc = g_utf16_to_utf8((unsigned short int*)buffer, -1, nullptr, nullptr, nullptr); // convert to utf-8 in a buffer allocated by glib
+ if (cModelDesc) {
+ modelDesc.assign(cModelDesc);
+ g_free(cModelDesc);
+ }
+#else
+ modelDesc = utf32_to_utf8(buffer, count);
+#endif
+ delete [] buffer;
+ if (!modelDesc.empty()) {
+ printf("dmdd=%s\n", modelDesc.c_str());
+
+ std::size_t pos = modelDesc.find("g");
+ std::size_t posmid = modelDesc.find("s");
+ std::size_t posend = modelDesc.find("!");
+ std::string strgamma = modelDesc.substr(pos + 1, (posmid - pos));
+ gammatag = std::stod(strgamma.c_str());
+ std::string strslope = modelDesc.substr(posmid + 1, (posend - posmid));
+ slopetag = std::stod(strslope.c_str());
+ // printf("gam=%f slo=%f\n", gammatag, slopetag);
+ }
+ } else {
+ printf("Error: lab2rgbOut / String length is null!\n");
+ }
+ } else {
+ printf("Error: lab2rgbOut / cmsReadTag/cmsSigDeviceModelDescTag failed!\n");
+ }
+
+ double pwr = 1.0 / gammatag;
+ double ts = slopetag;
+ double slope = slopetag == 0 ? eps : slopetag;
+
+ int mode = 0;
+ Color::calcGamma(pwr, ts, mode, g_b); // call to calcGamma with selected gamma and slope : return parameters for LCMS2
+ cmsFloat64Number gammaParams[7]; //gamma parameters
+ gammaParams[4] = g_b[3] * ts;
+ gammaParams[0] = gammatag;
+ gammaParams[1] = 1. / (1.0 + g_b[4]);
+ gammaParams[2] = g_b[4] / (1.0 + g_b[4]);
+ gammaParams[3] = 1. / slope;
+ gammaParams[5] = 0.0;
+ gammaParams[6] = 0.0;
+
+ cmsToneCurve* GammaTRC[3];
+
+ GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(nullptr, 5, gammaParams); //5 = smoother than 4
+ cmsWriteTag(oprof, cmsSigRedTRCTag, GammaTRC[0]);
+ cmsWriteTag(oprof, cmsSigGreenTRCTag, GammaTRC[1]);
+ cmsWriteTag(oprof, cmsSigBlueTRCTag, GammaTRC[2]);
+ cmsFreeToneCurve(GammaTRC[0]);
}
if (oprof) {
cmsUInt32Number flags = cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE;
+
if (icm.outputBPC) {
flags |= cmsFLAGS_BLACKPOINTCOMPENSATION;
}
- lcmsMutex->lock ();
+
+ lcmsMutex->lock();
cmsHPROFILE iprof = cmsCreateLab4Profile(nullptr);
- cmsHTRANSFORM hTransform = cmsCreateTransform (iprof, TYPE_Lab_FLT, oprof, TYPE_RGB_FLT, icm.outputIntent, flags);
- lcmsMutex->unlock ();
+ cmsHTRANSFORM hTransform = cmsCreateTransform(iprof, TYPE_Lab_FLT, oprof, TYPE_RGB_FLT, icm.outputIntent, flags);
+ lcmsMutex->unlock();
image->ExecCMSTransform(hTransform, *lab, cx, cy);
cmsDeleteTransform(hTransform);
@@ -328,6 +397,7 @@ Imagefloat* ImProcFunctions::lab2rgbOut (LabImage* lab, int cx, int cy, int cw,
#ifdef _OPENMP
#pragma omp parallel for schedule(dynamic,16) if (multiThread)
#endif
+
for (int i = cy; i < cy + ch; i++) {
float R, G, B;
float* rL = lab->L[i];
@@ -358,4 +428,233 @@ Imagefloat* ImProcFunctions::lab2rgbOut (LabImage* lab, int cx, int cy, int cw,
return image;
}
+
+Imagefloat* ImProcFunctions::workingtrc(Imagefloat* working, int cw, int ch, int mul, Glib::ustring profile, double gampos, double slpos)
+{
+ TMatrix wprof;
+
+ wprof = ICCStore::getInstance()->workingSpaceMatrix(params->icm.workingProfile);
+
+ double dx = Color::D50x;
+ double dz = Color::D50z;
+ {
+ dx = dz = 1.0;
+ }
+ double toxyz[3][3] = {
+ {
+ (wprof[0][0] / dx), //I have suppressed / Color::D50x
+ (wprof[0][1] / dx),
+ (wprof[0][2] / dx)
+ }, {
+ (wprof[1][0]),
+ (wprof[1][1]),
+ (wprof[1][2])
+ }, {
+ (wprof[2][0] / dz), //I have suppressed / Color::D50z
+ (wprof[2][1] / dz),
+ (wprof[2][2] / dz)
+ }
+ };
+
+ Imagefloat* image = new Imagefloat(cw, ch);
+
+ double pwr;
+ double ts;
+ ts = slpos;
+
+ int five = mul;
+
+ pwr = 1.0 / gampos;
+
+ if (gampos < 1.0) {
+ pwr = gampos;
+ gampos = 1. / gampos;
+ five = -mul;
+ }
+
+ // int select_temp = 1; //5003K
+ const double eps = 0.000000001; // not divide by zero
+
+ enum class ColorTemp {
+ D50 = 5003, // for Widegamut, ProPhoto Best, Beta -> D50
+ D65 = 6504, // for sRGB, AdobeRGB, Bruce Rec2020 -> D65
+ D60 = 6005 // for ACES AP0 and AP1
+
+ };
+ ColorTemp temp = ColorTemp::D50;
+
+ cmsHPROFILE oprofdef;
+ float p[6]; //primaries
+
+ if (true) {
+ //primaries for 10 working profiles ==> output profiles
+ if (profile == "WideGamut") {
+ p[0] = 0.7350; //Widegamut primaries
+ p[1] = 0.2650;
+ p[2] = 0.1150;
+ p[3] = 0.8260;
+ p[4] = 0.1570;
+ p[5] = 0.0180;
+ } else if (profile == "Adobe RGB") {
+ p[0] = 0.6400; //Adobe primaries
+ p[1] = 0.3300;
+ p[2] = 0.2100;
+ p[3] = 0.7100;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (profile == "sRGB") {
+ p[0] = 0.6400; // sRGB primaries
+ p[1] = 0.3300;
+ p[2] = 0.3000;
+ p[3] = 0.6000;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (profile == "BruceRGB") {
+ p[0] = 0.6400; // Bruce primaries
+ p[1] = 0.3300;
+ p[2] = 0.2800;
+ p[3] = 0.6500;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (profile == "Beta RGB") {
+ p[0] = 0.6888; // Beta primaries
+ p[1] = 0.3112;
+ p[2] = 0.1986;
+ p[3] = 0.7551;
+ p[4] = 0.1265;
+ p[5] = 0.0352;
+ } else if (profile == "BestRGB") {
+ p[0] = 0.7347; // Best primaries
+ p[1] = 0.2653;
+ p[2] = 0.2150;
+ p[3] = 0.7750;
+ p[4] = 0.1300;
+ p[5] = 0.0350;
+ } else if (profile == "Rec2020") {
+ p[0] = 0.7080; // Rec2020 primaries
+ p[1] = 0.2920;
+ p[2] = 0.1700;
+ p[3] = 0.7970;
+ p[4] = 0.1310;
+ p[5] = 0.0460;
+ temp = ColorTemp::D65;
+ } else if (profile == "ACESp0") {
+ p[0] = 0.7347; // ACES P0 primaries
+ p[1] = 0.2653;
+ p[2] = 0.0000;
+ p[3] = 1.0;
+ p[4] = 0.0001;
+ p[5] = -0.0770;
+ temp = ColorTemp::D60;
+ } else if (profile == "ACESp1") {
+ p[0] = 0.713; // ACES P1 primaries
+ p[1] = 0.293;
+ p[2] = 0.165;
+ p[3] = 0.830;
+ p[4] = 0.128;
+ p[5] = 0.044;
+ temp = ColorTemp::D60;
+ } else if (profile == "ProPhoto") {
+ p[0] = 0.7347; //ProPhoto and default primaries
+ p[1] = 0.2653;
+ p[2] = 0.1596;
+ p[3] = 0.8404;
+ p[4] = 0.0366;
+ p[5] = 0.0001;
+ } else {
+ p[0] = 0.7347; //default primaries always unused
+ p[1] = 0.2653;
+ p[2] = 0.1596;
+ p[3] = 0.8404;
+ p[4] = 0.0366;
+ p[5] = 0.0001;
+ }
+
+ if (slpos == 0) {
+ slpos = eps;
+ }
+
+ GammaValues g_a; //gamma parameters
+ int mode = 0;
+ Color::calcGamma(pwr, ts, mode, g_a); // call to calcGamma with selected gamma and slope : return parameters for LCMS2
+
+ cmsCIExyY xyD;
+
+ cmsCIExyYTRIPLE Primaries = {
+ {p[0], p[1], 1.0}, // red
+ {p[2], p[3], 1.0}, // green
+ {p[4], p[5], 1.0} // blue
+ };
+
+ cmsToneCurve* GammaTRC[3];
+ cmsFloat64Number gammaParams[7];
+ gammaParams[4] = g_a[3] * ts;
+ gammaParams[0] = gampos;
+ gammaParams[1] = 1. / (1.0 + g_a[4]);
+ gammaParams[2] = g_a[4] / (1.0 + g_a[4]);
+ gammaParams[3] = 1. / slpos;
+ gammaParams[5] = 0.0;
+ gammaParams[6] = 0.0;
+ // printf("ga0=%f ga1=%f ga2=%f ga3=%f ga4=%f\n", ga0, ga1, ga2, ga3, ga4);
+
+ // 7 parameters for smoother curves
+ cmsWhitePointFromTemp(&xyD, (double)temp);
+ GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(NULL, five, gammaParams);//5 = more smoother than 4
+ oprofdef = cmsCreateRGBProfile(&xyD, &Primaries, GammaTRC);
+ cmsFreeToneCurve(GammaTRC[0]);
+ }
+
+ if (oprofdef) {
+ #pragma omp parallel for if (multiThread)
+
+ for (int i = 0; i < ch; i++) {
+ float* rr = working->r(i);
+ float* rg = working->g(i);
+ float* rb = working->b(i);
+
+ float* xa = (float*)image->r(i);
+ float* ya = (float*)image->g(i);
+ float* za = (float*)image->b(i);
+
+ for (int j = 0; j < cw; j++) {
+ float r1 = rr[j];
+ float g1 = rg[j];
+ float b1 = rb[j];
+
+ float x_ = toxyz[0][0] * r1 + toxyz[0][1] * g1 + toxyz[0][2] * b1;
+ float y_ = toxyz[1][0] * r1 + toxyz[1][1] * g1 + toxyz[1][2] * b1;
+ float z_ = toxyz[2][0] * r1 + toxyz[2][1] * g1 + toxyz[2][2] * b1;
+
+ xa[j] = ( x_) ;
+ ya[j] = ( y_);
+ za[j] = ( z_);
+
+ }
+ }
+
+ cmsUInt32Number flags = cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE;
+
+
+ lcmsMutex->lock();
+ cmsHPROFILE iprof = ICCStore::getInstance()->getXYZProfile();
+ // cmsHTRANSFORM hTransform = cmsCreateTransform(iprof, TYPE_RGB_16, oprofdef, TYPE_RGB_16, params->icm.outputIntent, cmsFLAGS_NOOPTIMIZE | cmsFLAGS_NOCACHE);
+ cmsHTRANSFORM hTransform = cmsCreateTransform(iprof, TYPE_RGB_FLT, oprofdef, TYPE_RGB_FLT, params->icm.outputIntent, flags);
+ lcmsMutex->unlock();
+
+ image->ExecCMSTransform2(hTransform);
+
+ cmsDeleteTransform(hTransform);
+ image->normalizeFloatTo65535();
+
+ }
+
+
+ return image;
+
+}
+
+
}
diff --git a/rtengine/ipvibrance.cc b/rtengine/ipvibrance.cc
index 26141423c..f7a938c33 100644
--- a/rtengine/ipvibrance.cc
+++ b/rtengine/ipvibrance.cc
@@ -162,7 +162,7 @@ void ImProcFunctions::vibrance (LabImage* lab)
const bool protectskins = params->vibrance.protectskins;
const bool avoidcolorshift = params->vibrance.avoidcolorshift;
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.workingProfile);
//inverse matrix user select
const float wip[3][3] = {
{static_cast(wiprof[0][0]), static_cast(wiprof[0][1]), static_cast(wiprof[0][2])},
diff --git a/rtengine/ipwavelet.cc b/rtengine/ipwavelet.cc
index cd1bbc5f5..def469b70 100644
--- a/rtengine/ipwavelet.cc
+++ b/rtengine/ipwavelet.cc
@@ -148,7 +148,7 @@ void ImProcFunctions::ip_wavelet(LabImage * lab, LabImage * dst, int kall, const
// init variables to display Munsell corrections
MunsellDebugInfo* MunsDebugInfo = new MunsellDebugInfo();
#endif
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (params->icm.workingProfile);
const double wip[3][3] = {
{wiprof[0][0], wiprof[0][1], wiprof[0][2]},
{wiprof[1][0], wiprof[1][1], wiprof[1][2]},
diff --git a/rtengine/previewimage.cc b/rtengine/previewimage.cc
index 6c548f92a..f180469ad 100644
--- a/rtengine/previewimage.cc
+++ b/rtengine/previewimage.cc
@@ -107,7 +107,7 @@ PreviewImage::PreviewImage (const Glib::ustring &fname, const Glib::ustring &ext
ColorTemp wb = rawImage.getWB ();
rawImage.getFullSize (fw, fh, TR_NONE);
PreviewProps pp (0, 0, fw, fh, 1);
- params.icm.input = Glib::ustring("(embedded)");
+ params.icm.inputProfile = Glib::ustring("(embedded)");
params.raw.bayersensor.method = RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::FAST);
params.raw.deadPixelFilter = false;
params.raw.ca_autocorrect = false;
diff --git a/rtengine/procparams.cc b/rtengine/procparams.cc
index 4c3e47701..e7225e993 100644
--- a/rtengine/procparams.cc
+++ b/rtengine/procparams.cc
@@ -37,60 +37,60 @@ using namespace std;
namespace
{
-Glib::ustring expandRelativePath (const Glib::ustring &procparams_fname, const Glib::ustring &prefix, Glib::ustring embedded_fname)
+Glib::ustring expandRelativePath(const Glib::ustring &procparams_fname, const Glib::ustring &prefix, Glib::ustring embedded_fname)
{
- if (embedded_fname == "" || !Glib::path_is_absolute (procparams_fname)) {
+ if (embedded_fname == "" || !Glib::path_is_absolute(procparams_fname)) {
return embedded_fname;
}
if (prefix != "") {
- if (embedded_fname.length() < prefix.length() || embedded_fname.substr (0, prefix.length()) != prefix) {
+ if (embedded_fname.length() < prefix.length() || embedded_fname.substr(0, prefix.length()) != prefix) {
return embedded_fname;
}
- embedded_fname = embedded_fname.substr (prefix.length());
+ embedded_fname = embedded_fname.substr(prefix.length());
}
- if (Glib::path_is_absolute (embedded_fname)) {
+ if (Glib::path_is_absolute(embedded_fname)) {
return prefix + embedded_fname;
}
- Glib::ustring absPath = prefix + Glib::path_get_dirname (procparams_fname) + G_DIR_SEPARATOR_S + embedded_fname;
+ Glib::ustring absPath = prefix + Glib::path_get_dirname(procparams_fname) + G_DIR_SEPARATOR_S + embedded_fname;
return absPath;
}
-Glib::ustring relativePathIfInside (const Glib::ustring &procparams_fname, bool fnameAbsolute, Glib::ustring embedded_fname)
+Glib::ustring relativePathIfInside(const Glib::ustring &procparams_fname, bool fnameAbsolute, Glib::ustring embedded_fname)
{
- if (fnameAbsolute || embedded_fname == "" || !Glib::path_is_absolute (procparams_fname)) {
+ if (fnameAbsolute || embedded_fname == "" || !Glib::path_is_absolute(procparams_fname)) {
return embedded_fname;
}
Glib::ustring prefix = "";
- if (embedded_fname.length() > 5 && embedded_fname.substr (0, 5) == "file:") {
- embedded_fname = embedded_fname.substr (5);
+ if (embedded_fname.length() > 5 && embedded_fname.substr(0, 5) == "file:") {
+ embedded_fname = embedded_fname.substr(5);
prefix = "file:";
}
- if (!Glib::path_is_absolute (embedded_fname)) {
+ if (!Glib::path_is_absolute(embedded_fname)) {
return prefix + embedded_fname;
}
- Glib::ustring dir1 = Glib::path_get_dirname (procparams_fname) + G_DIR_SEPARATOR_S;
- Glib::ustring dir2 = Glib::path_get_dirname (embedded_fname) + G_DIR_SEPARATOR_S;
+ Glib::ustring dir1 = Glib::path_get_dirname(procparams_fname) + G_DIR_SEPARATOR_S;
+ Glib::ustring dir2 = Glib::path_get_dirname(embedded_fname) + G_DIR_SEPARATOR_S;
- if (dir2.substr (0, dir1.length()) != dir1) {
+ if (dir2.substr(0, dir1.length()) != dir1) {
// it's in a different directory, ie not inside
return prefix + embedded_fname;
}
- return prefix + embedded_fname.substr (dir1.length());
+ return prefix + embedded_fname.substr(dir1.length());
}
-void avoidEmptyCurve (std::vector &curve)
+void avoidEmptyCurve(std::vector &curve)
{
if (curve.empty()) {
- curve.push_back (FCT_Linear);
+ curve.push_back(FCT_Linear);
}
}
@@ -164,6 +164,7 @@ bool assignFromKeyfile(
return true;
}
+
return false;
}
@@ -196,6 +197,7 @@ bool assignFromKeyfile(
return true;
}
+
return false;
}
@@ -274,6 +276,7 @@ bool saveToKeyfile(
putToKeyfile(group_name, key, value, keyfile);
return true;
}
+
return false;
}
@@ -295,6 +298,7 @@ bool saveToKeyfile(
return true;
}
}
+
return false;
}
@@ -732,10 +736,10 @@ void ColorToningParams::mixerToCurve(std::vector& colorCurve, std::vecto
{
// check if non null first
if (!redlow && !greenlow && !bluelow && !redmed && !greenmed && !bluemed && !redhigh && !greenhigh && !bluehigh) {
- colorCurve.resize (1);
- colorCurve.at (0) = FCT_Linear;
- opacityCurve.resize (1);
- opacityCurve.at (0) = FCT_Linear;
+ colorCurve.resize(1);
+ colorCurve.at(0) = FCT_Linear;
+ opacityCurve.resize(1);
+ opacityCurve.at(0) = FCT_Linear;
return;
}
@@ -748,9 +752,9 @@ void ColorToningParams::mixerToCurve(std::vector& colorCurve, std::vecto
float minTmp, maxTmp;
// Fill the shadow mixer values of the Color TOning tool
- low[0] = float (redlow ) / 100.f; // [-1. ; +1.]
+ low[0] = float (redlow) / 100.f; // [-1. ; +1.]
low[1] = float (greenlow) / 100.f; // [-1. ; +1.]
- low[2] = float (bluelow ) / 100.f; // [-1. ; +1.]
+ low[2] = float (bluelow) / 100.f; // [-1. ; +1.]
minTmp = min (low[0], low[1], low[2]);
maxTmp = max (low[0], low[1], low[2]);
@@ -790,9 +794,9 @@ void ColorToningParams::mixerToCurve(std::vector& colorCurve, std::vecto
}
// Fill the mid-tones mixer values of the Color TOning tool
- med[0] = float (redmed ) / 100.f; // [-1. ; +1.]
+ med[0] = float (redmed) / 100.f; // [-1. ; +1.]
med[1] = float (greenmed) / 100.f; // [-1. ; +1.]
- med[2] = float (bluemed ) / 100.f; // [-1. ; +1.]
+ med[2] = float (bluemed) / 100.f; // [-1. ; +1.]
minTmp = min (med[0], med[1], med[2]);
maxTmp = max (med[0], med[1], med[2]);
@@ -832,9 +836,9 @@ void ColorToningParams::mixerToCurve(std::vector& colorCurve, std::vecto
}
// Fill the highlight mixer values of the Color TOning tool
- high[0] = float (redhigh ) / 100.f; // [-1. ; +1.]
+ high[0] = float (redhigh) / 100.f; // [-1. ; +1.]
high[1] = float (greenhigh) / 100.f; // [-1. ; +1.]
- high[2] = float (bluehigh ) / 100.f; // [-1. ; +1.]
+ high[2] = float (bluehigh) / 100.f; // [-1. ; +1.]
minTmp = min (high[0], high[1], high[2]);
maxTmp = max (high[0], high[1], high[2]);
@@ -877,97 +881,97 @@ void ColorToningParams::mixerToCurve(std::vector& colorCurve, std::vecto
const double xPosMed = 0.4;
const double xPosHigh = 0.7;
- colorCurve.resize ( medSat != 0.f ? 13 : 9 );
- colorCurve.at (0) = FCT_MinMaxCPoints;
- opacityCurve.resize (13);
- opacityCurve.at (0) = FCT_MinMaxCPoints;
+ colorCurve.resize(medSat != 0.f ? 13 : 9);
+ colorCurve.at(0) = FCT_MinMaxCPoints;
+ opacityCurve.resize(13);
+ opacityCurve.at(0) = FCT_MinMaxCPoints;
float h, s, l;
int idx = 1;
if (lowSat == 0.f) {
if (medSat != 0.f) {
- Color::rgb2hsl (med[0], med[1], med[2], h, s, l);
+ Color::rgb2hsl(med[0], med[1], med[2], h, s, l);
} else { // highSat can't be null if the 2 other ones are!
- Color::rgb2hsl (high[0], high[1], high[2], h, s, l);
+ Color::rgb2hsl(high[0], high[1], high[2], h, s, l);
}
} else {
- Color::rgb2hsl (low[0], low[1], low[2], h, s, l);
+ Color::rgb2hsl(low[0], low[1], low[2], h, s, l);
}
- colorCurve.at (idx++) = xPosLow;
- colorCurve.at (idx++) = h;
- colorCurve.at (idx++) = 0.35;
- colorCurve.at (idx++) = 0.35;
+ colorCurve.at(idx++) = xPosLow;
+ colorCurve.at(idx++) = h;
+ colorCurve.at(idx++) = 0.35;
+ colorCurve.at(idx++) = 0.35;
if (medSat != 0.f) {
- Color::rgb2hsl (med[0], med[1], med[2], h, s, l);
- colorCurve.at (idx++) = xPosMed;
- colorCurve.at (idx++) = h;
- colorCurve.at (idx++) = 0.35;
- colorCurve.at (idx++) = 0.35;
+ Color::rgb2hsl(med[0], med[1], med[2], h, s, l);
+ colorCurve.at(idx++) = xPosMed;
+ colorCurve.at(idx++) = h;
+ colorCurve.at(idx++) = 0.35;
+ colorCurve.at(idx++) = 0.35;
}
if (highSat == 0.f) {
if (medSat != 0.f) {
- Color::rgb2hsl (med[0], med[1], med[2], h, s, l);
+ Color::rgb2hsl(med[0], med[1], med[2], h, s, l);
} else { // lowSat can't be null if the 2 other ones are!
- Color::rgb2hsl (low[0], low[1], low[2], h, s, l);
+ Color::rgb2hsl(low[0], low[1], low[2], h, s, l);
}
} else {
- Color::rgb2hsl (high[0], high[1], high[2], h, s, l);
+ Color::rgb2hsl(high[0], high[1], high[2], h, s, l);
}
- colorCurve.at (idx++) = xPosHigh;
- colorCurve.at (idx++) = h;
- colorCurve.at (idx++) = 0.35;
- colorCurve.at (idx) = 0.35;
+ colorCurve.at(idx++) = xPosHigh;
+ colorCurve.at(idx++) = h;
+ colorCurve.at(idx++) = 0.35;
+ colorCurve.at(idx) = 0.35;
- opacityCurve.at (1) = xPosLow;
- opacityCurve.at (2) = double (lowSat);
- opacityCurve.at (3) = 0.35;
- opacityCurve.at (4) = 0.35;
- opacityCurve.at (5) = xPosMed;
- opacityCurve.at (6) = double (medSat);
- opacityCurve.at (7) = 0.35;
- opacityCurve.at (8) = 0.35;
- opacityCurve.at (9) = xPosHigh;
- opacityCurve.at (10) = double (highSat);
- opacityCurve.at (11) = 0.35;
- opacityCurve.at (12) = 0.35;
+ opacityCurve.at(1) = xPosLow;
+ opacityCurve.at(2) = double (lowSat);
+ opacityCurve.at(3) = 0.35;
+ opacityCurve.at(4) = 0.35;
+ opacityCurve.at(5) = xPosMed;
+ opacityCurve.at(6) = double (medSat);
+ opacityCurve.at(7) = 0.35;
+ opacityCurve.at(8) = 0.35;
+ opacityCurve.at(9) = xPosHigh;
+ opacityCurve.at(10) = double (highSat);
+ opacityCurve.at(11) = 0.35;
+ opacityCurve.at(12) = 0.35;
}
void ColorToningParams::slidersToCurve(std::vector& colorCurve, std::vector& opacityCurve) const
{
if (hlColSat.getBottom() == 0 && shadowsColSat.getBottom() == 0) { // if both opacity are null, set both curves to Linear
- colorCurve.resize (1);
- colorCurve.at (0) = FCT_Linear;
- opacityCurve.resize (1);
- opacityCurve.at (0) = FCT_Linear;
+ colorCurve.resize(1);
+ colorCurve.at(0) = FCT_Linear;
+ opacityCurve.resize(1);
+ opacityCurve.at(0) = FCT_Linear;
return;
}
- colorCurve.resize (9);
- colorCurve.at (0) = FCT_MinMaxCPoints;
- colorCurve.at (1) = 0.26 + 0.12 * double (balance) / 100.;
- colorCurve.at (2) = double (shadowsColSat.getTop()) / 360.;
- colorCurve.at (3) = 0.35;
- colorCurve.at (4) = 0.35;
- colorCurve.at (5) = 0.64 + 0.12 * double (balance) / 100.;
- colorCurve.at (6) = double (hlColSat.getTop()) / 360.;
- colorCurve.at (7) = 0.35;
- colorCurve.at (8) = 0.35;
+ colorCurve.resize(9);
+ colorCurve.at(0) = FCT_MinMaxCPoints;
+ colorCurve.at(1) = 0.26 + 0.12 * double (balance) / 100.;
+ colorCurve.at(2) = double (shadowsColSat.getTop()) / 360.;
+ colorCurve.at(3) = 0.35;
+ colorCurve.at(4) = 0.35;
+ colorCurve.at(5) = 0.64 + 0.12 * double (balance) / 100.;
+ colorCurve.at(6) = double (hlColSat.getTop()) / 360.;
+ colorCurve.at(7) = 0.35;
+ colorCurve.at(8) = 0.35;
- opacityCurve.resize (9);
- opacityCurve.at (0) = FCT_MinMaxCPoints;
- opacityCurve.at (1) = colorCurve.at (1);
- opacityCurve.at (2) = double (shadowsColSat.getBottom()) / 100.;
- opacityCurve.at (3) = 0.35;
- opacityCurve.at (4) = 0.35;
- opacityCurve.at (5) = colorCurve.at (5);
- opacityCurve.at (6) = double (hlColSat.getBottom()) / 100.;
- opacityCurve.at (7) = 0.35;
- opacityCurve.at (8) = 0.35;
+ opacityCurve.resize(9);
+ opacityCurve.at(0) = FCT_MinMaxCPoints;
+ opacityCurve.at(1) = colorCurve.at(1);
+ opacityCurve.at(2) = double (shadowsColSat.getBottom()) / 100.;
+ opacityCurve.at(3) = 0.35;
+ opacityCurve.at(4) = 0.35;
+ opacityCurve.at(5) = colorCurve.at(5);
+ opacityCurve.at(6) = double (hlColSat.getBottom()) / 100.;
+ opacityCurve.at(7) = 0.35;
+ opacityCurve.at(8) = 0.35;
}
void ColorToningParams::getCurves(ColorGradientCurve& colorCurveLUT, OpacityCurve& opacityCurveLUT, const double xyz_rgb[3][3], bool& opautili) const
@@ -979,9 +983,9 @@ void ColorToningParams::getCurves(ColorGradientCurve& colorCurveLUT, OpacityCurv
std::vector cCurve, oCurve;
if (method == "RGBSliders" || method == "Splitlr") {
- slidersToCurve (cCurve, oCurve);
+ slidersToCurve(cCurve, oCurve);
} else if (method == "Splitco") {
- mixerToCurve (cCurve, oCurve);
+ mixerToCurve(cCurve, oCurve);
} else {
cCurve = this->colorCurve;
oCurve = this->opacityCurve;
@@ -996,14 +1000,14 @@ void ColorToningParams::getCurves(ColorGradientCurve& colorCurveLUT, OpacityCurv
satur = 0.9f;
}
- colorCurveLUT.SetXYZ (cCurve, xyz_rgb, satur, lumin);
- opacityCurveLUT.Set (oCurve, opautili);
+ colorCurveLUT.SetXYZ(cCurve, xyz_rgb, satur, lumin);
+ opacityCurveLUT.Set(oCurve, opautili);
} else if (method == "Splitlr" || method == "Splitco") {
- colorCurveLUT.SetXYZ (cCurve, xyz_rgb, satur, lumin);
- opacityCurveLUT.Set (oCurve, opautili);
- } else if (method.substr (0, 3) == "RGB") {
- colorCurveLUT.SetRGB (cCurve);
- opacityCurveLUT.Set (oCurve, opautili);
+ colorCurveLUT.SetXYZ(cCurve, xyz_rgb, satur, lumin);
+ opacityCurveLUT.Set(oCurve, opautili);
+ } else if (method.substr(0, 3) == "RGB") {
+ colorCurveLUT.SetRGB(cCurve);
+ opacityCurveLUT.Set(oCurve, opautili);
}
}
@@ -1191,7 +1195,7 @@ const std::vector& WBParams::getWbEntries()
{"Flash 6000K", WBEntry::Type::FLASH, M("TP_WBALANCE_FLASH60"), 6000, 1.f, 1.f, 0.f},
{"Flash 6500K", WBEntry::Type::FLASH, M("TP_WBALANCE_FLASH65"), 6500, 1.f, 1.f, 0.f},
// Should remain the last one
- {"Custom", WBEntry::Type::CUSTOM, M ("TP_WBALANCE_CUSTOM"), 0, 1.f, 1.f, 0.f}
+ {"Custom", WBEntry::Type::CUSTOM, M("TP_WBALANCE_CUSTOM"), 0, 1.f, 1.f, 0.f}
};
return wb_entries;
@@ -1437,7 +1441,7 @@ bool DirPyrDenoiseParams::operator !=(const DirPyrDenoiseParams& other) const
return !(*this == other);
}
-void DirPyrDenoiseParams::getCurves (NoiseCurve &lCurve, NoiseCurve &cCurve) const
+void DirPyrDenoiseParams::getCurves(NoiseCurve &lCurve, NoiseCurve &cCurve) const
{
lCurve.Set(this->lcurve);
cCurve.Set(this->cccurve);
@@ -1554,10 +1558,10 @@ void CropParams::mapToResized(int resizedWidth, int resizedHeight, int scale, in
x1 = 0, x2 = resizedWidth, y1 = 0, y2 = resizedHeight;
if (enabled) {
- x1 = min(resizedWidth - 1, max (0, x / scale));
- y1 = min(resizedHeight - 1, max (0, y / scale));
- x2 = min(resizedWidth, max (0, (x + w) / scale));
- y2 = min(resizedHeight, max (0, (y + h) / scale));
+ x1 = min(resizedWidth - 1, max(0, x / scale));
+ y1 = min(resizedHeight - 1, max(0, y / scale));
+ x2 = min(resizedWidth, max(0, (x + w) / scale));
+ y2 = min(resizedHeight, max(0, (y + h) / scale));
}
}
@@ -1693,6 +1697,7 @@ LensProfParams::LcMode LensProfParams::getMethodNumber(const Glib::ustring& mode
return static_cast(i);
}
}
+
return LcMode::NONE;
}
@@ -1811,6 +1816,7 @@ bool ChannelMixerParams::operator ==(const ChannelMixerParams& other) const
if (enabled != other.enabled) {
return false;
}
+
for (unsigned int i = 0; i < 3; ++i) {
if (
red[i] != other.red[i]
@@ -1820,6 +1826,7 @@ bool ChannelMixerParams::operator ==(const ChannelMixerParams& other) const
return false;
}
}
+
return true;
}
@@ -1942,43 +1949,41 @@ bool ResizeParams::operator !=(const ResizeParams& other) const
return !(*this == other);
}
-const Glib::ustring ColorManagementParams::NoICMString = Glib::ustring ("No ICM: sRGB output");
+const Glib::ustring ColorManagementParams::NoICMString = Glib::ustring("No ICM: sRGB output");
ColorManagementParams::ColorManagementParams() :
- input("(cameraICC)"),
+ inputProfile("(cameraICC)"),
toneCurve(false),
applyLookTable(false),
applyBaselineExposureOffset(true),
applyHueSatMap(true),
dcpIlluminant(0),
- working("ProPhoto"),
- output("RT_sRGB"),
+ workingProfile("ProPhoto"),
+ workingTRC("none"),
+ workingTRCGamma(2.4),
+ workingTRCSlope(12.92310),
+ outputProfile(options.rtSettings.srgb),
outputIntent(RI_RELATIVE),
- outputBPC(true),
- gamma("default"),
- gampos(2.22),
- slpos(4.5),
- freegamma(false)
+ outputBPC(true)
{
}
bool ColorManagementParams::operator ==(const ColorManagementParams& other) const
{
return
- input == other.input
+ inputProfile == other.inputProfile
&& toneCurve == other.toneCurve
&& applyLookTable == other.applyLookTable
&& applyBaselineExposureOffset == other.applyBaselineExposureOffset
&& applyHueSatMap == other.applyHueSatMap
&& dcpIlluminant == other.dcpIlluminant
- && working == other.working
- && output == other.output
+ && workingProfile == other.workingProfile
+ && workingTRC == other.workingTRC
+ && workingTRCGamma == other.workingTRCGamma
+ && workingTRCSlope == other.workingTRCSlope
+ && outputProfile == other.outputProfile
&& outputIntent == other.outputIntent
- && outputBPC == other.outputBPC
- && gamma == other.gamma
- && gampos == other.gampos
- && slpos == other.slpos
- && freegamma == other.freegamma;
+ && outputBPC == other.outputBPC;
}
bool ColorManagementParams::operator !=(const ColorManagementParams& other) const
@@ -2249,11 +2254,11 @@ void WaveletParams::getCurves(
WavOpacityCurveWL& opacityCurveLUTWL
) const
{
- cCurve.Set (this->ccwcurve);
- opacityCurveLUTRG.Set (this->opacityCurveRG);
- opacityCurveLUTBY.Set (this->opacityCurveBY);
- opacityCurveLUTW.Set (this->opacityCurveW);
- opacityCurveLUTWL.Set (this->opacityCurveWL);
+ cCurve.Set(this->ccwcurve);
+ opacityCurveLUTRG.Set(this->opacityCurveRG);
+ opacityCurveLUTBY.Set(this->opacityCurveBY);
+ opacityCurveLUTW.Set(this->opacityCurveW);
+ opacityCurveLUTWL.Set(this->opacityCurveWL);
}
@@ -2627,12 +2632,12 @@ bool MetaDataParams::operator!=(const MetaDataParams &other) const
}
-ProcParams::ProcParams ()
+ProcParams::ProcParams()
{
- setDefaults ();
+ setDefaults();
}
-void ProcParams::setDefaults ()
+void ProcParams::setDefaults()
{
toneCurve = ToneCurveParams();
@@ -2719,8 +2724,8 @@ void ProcParams::setDefaults ()
raw = RAWParams();
metadata = MetaDataParams();
- exif.clear ();
- iptc.clear ();
+ exif.clear();
+ iptc.clear();
rank = 0;
colorlabel = 0;
@@ -2731,7 +2736,7 @@ void ProcParams::setDefaults ()
int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bool fnameAbsolute, ParamsEdited* pedited)
{
- if (fname.empty () && fname2.empty ()) {
+ if (fname.empty() && fname2.empty()) {
return 0;
}
@@ -2741,8 +2746,8 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
Glib::KeyFile keyFile;
// Version
- keyFile.set_string ("Version", "AppVersion", RTVERSION);
- keyFile.set_integer ("Version", "Version", PPVERSION);
+ keyFile.set_string("Version", "AppVersion", RTVERSION);
+ keyFile.set_integer("Version", "Version", PPVERSION);
saveToKeyfile(!pedited || pedited->general.rank, "General", "Rank", rank, keyFile);
saveToKeyfile(!pedited || pedited->general.colorlabel, "General", "ColorLabel", colorlabel, keyFile);
@@ -2771,7 +2776,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
{ToneCurveParams::TcMode::STD, "Standard"},
{ToneCurveParams::TcMode::FILMLIKE, "FilmLike"},
{ToneCurveParams::TcMode::SATANDVALBLENDING, "SatAndValueBlending"},
- {ToneCurveParams::TcMode::WEIGHTEDSTD,"WeightedStd"},
+ {ToneCurveParams::TcMode::WEIGHTEDSTD, "WeightedStd"},
{ToneCurveParams::TcMode::LUMINANCE, "Luminance"},
{ToneCurveParams::TcMode::PERCEPTUAL, "Perceptual"}
};
@@ -2826,19 +2831,20 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
// Channel mixer
saveToKeyfile(!pedited || pedited->chmixer.enabled, "Channel Mixer", "Enabled", chmixer.enabled, keyFile);
+
if (!pedited || pedited->chmixer.red[0] || pedited->chmixer.red[1] || pedited->chmixer.red[2]) {
- Glib::ArrayHandle rmix (chmixer.red, 3, Glib::OWNERSHIP_NONE);
- keyFile.set_integer_list ("Channel Mixer", "Red", rmix);
+ Glib::ArrayHandle rmix(chmixer.red, 3, Glib::OWNERSHIP_NONE);
+ keyFile.set_integer_list("Channel Mixer", "Red", rmix);
}
if (!pedited || pedited->chmixer.green[0] || pedited->chmixer.green[1] || pedited->chmixer.green[2]) {
- Glib::ArrayHandle gmix (chmixer.green, 3, Glib::OWNERSHIP_NONE);
- keyFile.set_integer_list ("Channel Mixer", "Green", gmix);
+ Glib::ArrayHandle gmix(chmixer.green, 3, Glib::OWNERSHIP_NONE);
+ keyFile.set_integer_list("Channel Mixer", "Green", gmix);
}
if (!pedited || pedited->chmixer.blue[0] || pedited->chmixer.blue[1] || pedited->chmixer.blue[2]) {
- Glib::ArrayHandle bmix (chmixer.blue, 3, Glib::OWNERSHIP_NONE);
- keyFile.set_integer_list ("Channel Mixer", "Blue", bmix);
+ Glib::ArrayHandle bmix(chmixer.blue, 3, Glib::OWNERSHIP_NONE);
+ keyFile.set_integer_list("Channel Mixer", "Blue", bmix);
}
// Black & White
@@ -3034,13 +3040,17 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || pedited->dirpyrDenoise.chroma, "Directional Pyramid Denoising", "Chroma", dirpyrDenoise.chroma, keyFile);
saveToKeyfile(!pedited || pedited->dirpyrDenoise.dmethod, "Directional Pyramid Denoising", "Method", dirpyrDenoise.dmethod, keyFile);
saveToKeyfile(!pedited || pedited->dirpyrDenoise.Lmethod, "Directional Pyramid Denoising", "LMethod", dirpyrDenoise.Lmethod, keyFile);
+
if (dirpyrDenoise.Cmethod == "PRE") {
dirpyrDenoise.Cmethod = "MAN"; // Never save 'auto chroma preview mode' to pp3
}
+
saveToKeyfile(!pedited || pedited->dirpyrDenoise.Cmethod, "Directional Pyramid Denoising", "CMethod", dirpyrDenoise.Cmethod, keyFile);
+
if (dirpyrDenoise.C2method == "PREV") {
dirpyrDenoise.C2method = "MANU";
}
+
saveToKeyfile(!pedited || pedited->dirpyrDenoise.C2method, "Directional Pyramid Denoising", "C2Method", dirpyrDenoise.C2method, keyFile);
saveToKeyfile(!pedited || pedited->dirpyrDenoise.smethod, "Directional Pyramid Denoising", "SMethod", dirpyrDenoise.smethod, keyFile);
saveToKeyfile(!pedited || pedited->dirpyrDenoise.medmethod, "Directional Pyramid Denoising", "MedMethod", dirpyrDenoise.medmethod, keyFile);
@@ -3101,8 +3111,8 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || pedited->distortion.amount, "Distortion", "Amount", distortion.amount, keyFile);
// Lens profile
- saveToKeyfile(!pedited || pedited->lensProf.lcMode, "LensProfile", "LcMode", lensProf.getMethodString (lensProf.lcMode), keyFile);
- saveToKeyfile(!pedited || pedited->lensProf.lcpFile, "LensProfile", "LCPFile", relativePathIfInside (fname, fnameAbsolute, lensProf.lcpFile), keyFile);
+ saveToKeyfile(!pedited || pedited->lensProf.lcMode, "LensProfile", "LcMode", lensProf.getMethodString(lensProf.lcMode), keyFile);
+ saveToKeyfile(!pedited || pedited->lensProf.lcpFile, "LensProfile", "LCPFile", relativePathIfInside(fname, fnameAbsolute, lensProf.lcpFile), keyFile);
saveToKeyfile(!pedited || pedited->lensProf.useDist, "LensProfile", "UseDistortion", lensProf.useDist, keyFile);
saveToKeyfile(!pedited || pedited->lensProf.useVign, "LensProfile", "UseVignette", lensProf.useVign, keyFile);
saveToKeyfile(!pedited || pedited->lensProf.useCA, "LensProfile", "UseCA", lensProf.useCA, keyFile);
@@ -3167,14 +3177,17 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || pedited->prsharpening.deconviter, "PostResizeSharpening", "DeconvIterations", prsharpening.deconviter, keyFile);
// Color management
- saveToKeyfile(!pedited || pedited->icm.input, "Color Management", "InputProfile", relativePathIfInside (fname, fnameAbsolute, icm.input), keyFile);
+ saveToKeyfile(!pedited || pedited->icm.inputProfile, "Color Management", "InputProfile", relativePathIfInside(fname, fnameAbsolute, icm.inputProfile), keyFile);
saveToKeyfile(!pedited || pedited->icm.toneCurve, "Color Management", "ToneCurve", icm.toneCurve, keyFile);
saveToKeyfile(!pedited || pedited->icm.applyLookTable, "Color Management", "ApplyLookTable", icm.applyLookTable, keyFile);
saveToKeyfile(!pedited || pedited->icm.applyBaselineExposureOffset, "Color Management", "ApplyBaselineExposureOffset", icm.applyBaselineExposureOffset, keyFile);
saveToKeyfile(!pedited || pedited->icm.applyHueSatMap, "Color Management", "ApplyHueSatMap", icm.applyHueSatMap, keyFile);
saveToKeyfile(!pedited || pedited->icm.dcpIlluminant, "Color Management", "DCPIlluminant", icm.dcpIlluminant, keyFile);
- saveToKeyfile(!pedited || pedited->icm.working, "Color Management", "WorkingProfile", icm.working, keyFile);
- saveToKeyfile(!pedited || pedited->icm.output, "Color Management", "OutputProfile", icm.output, keyFile);
+ saveToKeyfile(!pedited || pedited->icm.workingProfile, "Color Management", "WorkingProfile", icm.workingProfile, keyFile);
+ saveToKeyfile(!pedited || pedited->icm.workingTRC, "Color Management", "WorkingTRC", icm.workingTRC, keyFile);
+ saveToKeyfile(!pedited || pedited->icm.workingTRCGamma, "Color Management", "WorkingTRCGamma", icm.workingTRCGamma, keyFile);
+ saveToKeyfile(!pedited || pedited->icm.workingTRCSlope, "Color Management", "WorkingTRCSlope", icm.workingTRCSlope, keyFile);
+ saveToKeyfile(!pedited || pedited->icm.outputProfile, "Color Management", "OutputProfile", icm.outputProfile, keyFile);
saveToKeyfile(
!pedited || pedited->icm.outputIntent,
"Color Management",
@@ -3190,10 +3203,6 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
keyFile
);
saveToKeyfile(!pedited || pedited->icm.outputBPC, "Color Management", "OutputBPC", icm.outputBPC, keyFile);
- saveToKeyfile(!pedited || pedited->icm.gamma, "Color Management", "Gammafree", icm.gamma, keyFile);
- saveToKeyfile(!pedited || pedited->icm.freegamma, "Color Management", "Freegamma", icm.freegamma, keyFile);
- saveToKeyfile(!pedited || pedited->icm.gampos, "Color Management", "GammaValue", icm.gampos, keyFile);
- saveToKeyfile(!pedited || pedited->icm.slpos, "Color Management", "GammaSlope", icm.slpos, keyFile);
// Wavelet
saveToKeyfile(!pedited || pedited->wavelet.enabled, "Wavelet", "Enabled", wavelet.enabled, keyFile);
@@ -3363,9 +3372,9 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
saveToKeyfile(!pedited || pedited->colorToning.labgridBHigh, "ColorToning", "LabGridBHigh", colorToning.labgridBHigh, keyFile);
// Raw
- saveToKeyfile(!pedited || pedited->raw.darkFrame, "RAW", "DarkFrame", relativePathIfInside (fname, fnameAbsolute, raw.dark_frame), keyFile);
+ saveToKeyfile(!pedited || pedited->raw.darkFrame, "RAW", "DarkFrame", relativePathIfInside(fname, fnameAbsolute, raw.dark_frame), keyFile);
saveToKeyfile(!pedited || pedited->raw.df_autoselect, "RAW", "DarkFrameAuto", raw.df_autoselect, keyFile);
- saveToKeyfile(!pedited || pedited->raw.ff_file, "RAW", "FlatFieldFile", relativePathIfInside (fname, fnameAbsolute, raw.ff_file), keyFile);
+ saveToKeyfile(!pedited || pedited->raw.ff_file, "RAW", "FlatFieldFile", relativePathIfInside(fname, fnameAbsolute, raw.ff_file), keyFile);
saveToKeyfile(!pedited || pedited->raw.ff_AutoSelect, "RAW", "FlatFieldAutoSelect", raw.ff_AutoSelect, keyFile);
saveToKeyfile(!pedited || pedited->raw.ff_BlurRadius, "RAW", "FlatFieldBlurRadius", raw.ff_BlurRadius, keyFile);
saveToKeyfile(!pedited || pedited->raw.ff_BlurType, "RAW", "FlatFieldBlurType", raw.ff_BlurType, keyFile);
@@ -3425,7 +3434,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
// EXIF change list
if (!pedited || pedited->exif) {
for (ExifPairs::const_iterator i = exif.begin(); i != exif.end(); ++i) {
- keyFile.set_string ("Exif", i->first, i->second);
+ keyFile.set_string("Exif", i->first, i->second);
}
}
@@ -3433,7 +3442,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
if (!pedited || pedited->iptc) {
for (IPTCPairs::const_iterator i = iptc.begin(); i != iptc.end(); ++i) {
Glib::ArrayHandle values = i->second;
- keyFile.set_string_list ("IPTC", i->first, values);
+ keyFile.set_string_list("IPTC", i->first, values);
}
}
@@ -3441,16 +3450,16 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
} catch (Glib::KeyFileError&) {}
- if (sPParams.empty ()) {
+ if (sPParams.empty()) {
return 1;
}
int error1, error2;
- error1 = write (fname, sPParams);
+ error1 = write(fname, sPParams);
- if (!fname2.empty ()) {
+ if (!fname2.empty()) {
- error2 = write (fname2, sPParams);
+ error2 = write(fname2, sPParams);
// If at least one file has been saved, it's a success
return error1 & error2;
} else {
@@ -3460,7 +3469,7 @@ int ProcParams::save(const Glib::ustring& fname, const Glib::ustring& fname2, bo
int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
{
- setlocale (LC_NUMERIC, "C"); // to set decimal point to "."
+ setlocale(LC_NUMERIC, "C"); // to set decimal point to "."
if (fname.empty()) {
return 1;
@@ -3470,39 +3479,40 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
try {
if (pedited) {
- pedited->set (false);
+ pedited->set(false);
}
if (!Glib::file_test(fname, Glib::FILE_TEST_EXISTS) ||
- !keyFile.load_from_file(fname)) {
+ !keyFile.load_from_file(fname)) {
return 1;
}
ppVersion = PPVERSION;
appVersion = RTVERSION;
- if (keyFile.has_group ("Version")) {
- if (keyFile.has_key ("Version", "AppVersion")) {
- appVersion = keyFile.get_string ("Version", "AppVersion");
+ if (keyFile.has_group("Version")) {
+ if (keyFile.has_key("Version", "AppVersion")) {
+ appVersion = keyFile.get_string("Version", "AppVersion");
}
- if (keyFile.has_key ("Version", "Version")) {
- ppVersion = keyFile.get_integer ("Version", "Version");
+ if (keyFile.has_key("Version", "Version")) {
+ ppVersion = keyFile.get_integer("Version", "Version");
}
}
- if (keyFile.has_group ("General")) {
+ if (keyFile.has_group("General")) {
assignFromKeyfile(keyFile, "General", "Rank", pedited, rank, pedited->general.rank);
assignFromKeyfile(keyFile, "General", "ColorLabel", pedited, colorlabel, pedited->general.colorlabel);
assignFromKeyfile(keyFile, "General", "InTrash", pedited, inTrash, pedited->general.intrash);
}
- if (keyFile.has_group ("Exposure")) {
+ if (keyFile.has_group("Exposure")) {
if (ppVersion < PPVERSION_AEXP) {
toneCurve.autoexp = false; // prevent execution of autoexp when opening file created with earlier versions of autoexp algorithm
} else {
assignFromKeyfile(keyFile, "Exposure", "Auto", pedited, toneCurve.autoexp, pedited->toneCurve.autoexp);
}
+
assignFromKeyfile(keyFile, "Exposure", "Clip", pedited, toneCurve.clip, pedited->toneCurve.clip);
assignFromKeyfile(keyFile, "Exposure", "Compensation", pedited, toneCurve.expcomp, pedited->toneCurve.expcomp);
assignFromKeyfile(keyFile, "Exposure", "Brightness", pedited, toneCurve.brightness, pedited->toneCurve.brightness);
@@ -3512,6 +3522,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Exposure", "HighlightCompr", pedited, toneCurve.hlcompr, pedited->toneCurve.hlcompr);
assignFromKeyfile(keyFile, "Exposure", "HighlightComprThreshold", pedited, toneCurve.hlcomprthresh, pedited->toneCurve.hlcomprthresh);
assignFromKeyfile(keyFile, "Exposure", "ShadowCompr", pedited, toneCurve.shcompr, pedited->toneCurve.shcompr);
+
if (toneCurve.shcompr > 100) {
toneCurve.shcompr = 100; // older pp3 files can have values above 100.
}
@@ -3532,6 +3543,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Exposure", "Curve", pedited, toneCurve.curve, pedited->toneCurve.curve);
assignFromKeyfile(keyFile, "Exposure", "Curve2", pedited, toneCurve.curve2, pedited->toneCurve.curve2);
}
+
assignFromKeyfile(keyFile, "Exposure", "HistogramMatching", pedited, toneCurve.histmatching, pedited->toneCurve.histmatching);
if (ppVersion < 340) {
toneCurve.fromHistMatching = false;
@@ -3544,29 +3556,31 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Exposure", "ClampOOG", pedited, toneCurve.clampOOG, pedited->toneCurve.clampOOG);
}
- if (keyFile.has_group ("HLRecovery")) {
+ if (keyFile.has_group("HLRecovery")) {
assignFromKeyfile(keyFile, "HLRecovery", "Enabled", pedited, toneCurve.hrenabled, pedited->toneCurve.hrenabled);
assignFromKeyfile(keyFile, "HLRecovery", "Method", pedited, toneCurve.method, pedited->toneCurve.method);
}
- if (keyFile.has_group ("Channel Mixer")) {
+ if (keyFile.has_group("Channel Mixer")) {
if (ppVersion >= 329) {
assignFromKeyfile(keyFile, "Channel Mixer", "Enabled", pedited, chmixer.enabled, pedited->chmixer.enabled);
} else {
chmixer.enabled = true;
+
if (pedited) {
pedited->chmixer.enabled = true;
}
}
- if (keyFile.has_key ("Channel Mixer", "Red") && keyFile.has_key ("Channel Mixer", "Green") && keyFile.has_key ("Channel Mixer", "Blue")) {
- const std::vector rmix = keyFile.get_integer_list ("Channel Mixer", "Red");
- const std::vector gmix = keyFile.get_integer_list ("Channel Mixer", "Green");
- const std::vector bmix = keyFile.get_integer_list ("Channel Mixer", "Blue");
+
+ if (keyFile.has_key("Channel Mixer", "Red") && keyFile.has_key("Channel Mixer", "Green") && keyFile.has_key("Channel Mixer", "Blue")) {
+ const std::vector rmix = keyFile.get_integer_list("Channel Mixer", "Red");
+ const std::vector gmix = keyFile.get_integer_list("Channel Mixer", "Green");
+ const std::vector bmix = keyFile.get_integer_list("Channel Mixer", "Blue");
if (rmix.size() == 3 && gmix.size() == 3 && bmix.size() == 3) {
- memcpy (chmixer.red, rmix.data(), 3 * sizeof (int));
- memcpy (chmixer.green, gmix.data(), 3 * sizeof (int));
- memcpy (chmixer.blue, bmix.data(), 3 * sizeof (int));
+ memcpy(chmixer.red, rmix.data(), 3 * sizeof(int));
+ memcpy(chmixer.green, gmix.data(), 3 * sizeof(int));
+ memcpy(chmixer.blue, bmix.data(), 3 * sizeof(int));
}
if (ppVersion < 338) {
for (int i = 0; i < 3; ++i) {
@@ -3584,7 +3598,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_group ("Black & White")) {
+ if (keyFile.has_group("Black & White")) {
assignFromKeyfile(keyFile, "Black & White", "Enabled", pedited, blackwhite.enabled, pedited->blackwhite.enabled);
assignFromKeyfile(keyFile, "Black & White", "Method", pedited, blackwhite.method, pedited->blackwhite.method);
assignFromKeyfile(keyFile, "Black & White", "Auto", pedited, blackwhite.autoc, pedited->blackwhite.autoc);
@@ -3637,7 +3651,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
);
}
- if (keyFile.has_group ("Retinex")) {
+ if (keyFile.has_group("Retinex")) {
assignFromKeyfile(keyFile, "Retinex", "Median", pedited, retinex.medianmap, pedited->retinex.medianmap);
assignFromKeyfile(keyFile, "Retinex", "RetinexMethod", pedited, retinex.retinexMethod, pedited->retinex.retinexMethod);
assignFromKeyfile(keyFile, "Retinex", "mapMethod", pedited, retinex.mapMethod, pedited->retinex.mapMethod);
@@ -3687,11 +3701,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Local Contrast", "Lightness", pedited, localContrast.lightness, pedited->localContrast.lightness);
}
- if (keyFile.has_group ("Luminance Curve")) {
+ if (keyFile.has_group("Luminance Curve")) {
if (ppVersion >= 329) {
assignFromKeyfile(keyFile, "Luminance Curve", "Enabled", pedited, labCurve.enabled, pedited->labCurve.enabled);
} else {
labCurve.enabled = true;
+
if (pedited) {
pedited->labCurve.enabled = true;
}
@@ -3707,8 +3722,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
// transform AvoidColorClipping into AvoidColorShift
assignFromKeyfile(keyFile, "Luminance Curve", "AvoidColorClipping", pedited, labCurve.avoidcolorshift, pedited->labCurve.avoidcolorshift);
} else {
- if (keyFile.has_key ("Luminance Curve", "Chromaticity")) {
- labCurve.chromaticity = keyFile.get_integer ("Luminance Curve", "Chromaticity");
+ if (keyFile.has_key("Luminance Curve", "Chromaticity")) {
+ labCurve.chromaticity = keyFile.get_integer("Luminance Curve", "Chromaticity");
if (ppVersion >= 303 && ppVersion < 314 && labCurve.chromaticity == -100) {
blackwhite.enabled = true;
@@ -3728,8 +3743,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
if (ppVersion < 314) {
// Backward compatibility: If BWtoning is true, Chromaticity has to be set to -100, which will produce the same effect
// and will enable the b&w toning mode ('a' & 'b' curves)
- if (keyFile.has_key ("Luminance Curve", "BWtoning")) {
- if ( keyFile.get_boolean ("Luminance Curve", "BWtoning")) {
+ if (keyFile.has_key("Luminance Curve", "BWtoning")) {
+ if (keyFile.get_boolean("Luminance Curve", "BWtoning")) {
labCurve.chromaticity = -100;
if (pedited) {
@@ -3750,7 +3765,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Luminance Curve", "ClCurve", pedited, labCurve.clcurve, pedited->labCurve.clcurve);
}
- if (keyFile.has_group ("Sharpening")) {
+ if (keyFile.has_group("Sharpening")) {
assignFromKeyfile(keyFile, "Sharpening", "Enabled", pedited, sharpening.enabled, pedited->sharpening.enabled);
if (ppVersion >= 334) {
assignFromKeyfile(keyFile, "Sharpening", "Contrast", pedited, sharpening.contrast, pedited->sharpening.contrast);
@@ -3763,15 +3778,15 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Sharpening", "Radius", pedited, sharpening.radius, pedited->sharpening.radius);
assignFromKeyfile(keyFile, "Sharpening", "Amount", pedited, sharpening.amount, pedited->sharpening.amount);
- if (keyFile.has_key ("Sharpening", "Threshold")) {
+ if (keyFile.has_key("Sharpening", "Threshold")) {
if (ppVersion < 302) {
- int thresh = min (keyFile.get_integer ("Sharpening", "Threshold"), 2000);
- sharpening.threshold.setValues (thresh, thresh, 2000, 2000); // TODO: 2000 is the maximum value and is taken of rtgui/sharpening.cc ; should be changed by the tool modularization
+ int thresh = min(keyFile.get_integer("Sharpening", "Threshold"), 2000);
+ sharpening.threshold.setValues(thresh, thresh, 2000, 2000); // TODO: 2000 is the maximum value and is taken of rtgui/sharpening.cc ; should be changed by the tool modularization
} else {
- const std::vector thresh = keyFile.get_integer_list ("Sharpening", "Threshold");
+ const std::vector thresh = keyFile.get_integer_list("Sharpening", "Threshold");
if (thresh.size() >= 4) {
- sharpening.threshold.setValues (thresh[0], thresh[1], min (thresh[2], 2000), min (thresh[3], 2000));
+ sharpening.threshold.setValues(thresh[0], thresh[1], min(thresh[2], 2000), min(thresh[3], 2000));
}
}
@@ -3792,14 +3807,14 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Sharpening", "DeconvIterations", pedited, sharpening.deconviter, pedited->sharpening.deconviter);
}
- if (keyFile.has_group ("SharpenEdge")) {
+ if (keyFile.has_group("SharpenEdge")) {
assignFromKeyfile(keyFile, "SharpenEdge", "Enabled", pedited, sharpenEdge.enabled, pedited->sharpenEdge.enabled);
assignFromKeyfile(keyFile, "SharpenEdge", "Passes", pedited, sharpenEdge.passes, pedited->sharpenEdge.passes);
assignFromKeyfile(keyFile, "SharpenEdge", "Strength", pedited, sharpenEdge.amount, pedited->sharpenEdge.amount);
assignFromKeyfile(keyFile, "SharpenEdge", "ThreeChannels", pedited, sharpenEdge.threechannels, pedited->sharpenEdge.threechannels);
}
- if (keyFile.has_group ("SharpenMicro")) {
+ if (keyFile.has_group("SharpenMicro")) {
assignFromKeyfile(keyFile, "SharpenMicro", "Enabled", pedited, sharpenMicro.enabled, pedited->sharpenMicro.enabled);
assignFromKeyfile(keyFile, "SharpenMicro", "Matrix", pedited, sharpenMicro.matrix, pedited->sharpenMicro.matrix);
assignFromKeyfile(keyFile, "SharpenMicro", "Strength", pedited, sharpenMicro.amount, pedited->sharpenMicro.amount);
@@ -3814,20 +3829,20 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "SharpenMicro", "Uniformity", pedited, sharpenMicro.uniformity, pedited->sharpenMicro.uniformity);
}
- if (keyFile.has_group ("Vibrance")) {
+ if (keyFile.has_group("Vibrance")) {
assignFromKeyfile(keyFile, "Vibrance", "Enabled", pedited, vibrance.enabled, pedited->vibrance.enabled);
assignFromKeyfile(keyFile, "Vibrance", "Pastels", pedited, vibrance.pastels, pedited->vibrance.pastels);
assignFromKeyfile(keyFile, "Vibrance", "Saturated", pedited, vibrance.saturated, pedited->vibrance.saturated);
- if (keyFile.has_key ("Vibrance", "PSThreshold")) {
+ if (keyFile.has_key("Vibrance", "PSThreshold")) {
if (ppVersion < 302) {
- int thresh = keyFile.get_integer ("Vibrance", "PSThreshold");
- vibrance.psthreshold.setValues (thresh, thresh);
+ int thresh = keyFile.get_integer("Vibrance", "PSThreshold");
+ vibrance.psthreshold.setValues(thresh, thresh);
} else {
- const std::vector thresh = keyFile.get_integer_list ("Vibrance", "PSThreshold");
+ const std::vector thresh = keyFile.get_integer_list("Vibrance", "PSThreshold");
- if (thresh.size() >= 2 ) {
- vibrance.psthreshold.setValues (thresh[0], thresh[1]);
+ if (thresh.size() >= 2) {
+ vibrance.psthreshold.setValues(thresh[0], thresh[1]);
}
}
@@ -3842,7 +3857,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Vibrance", "SkinTonesCurve", pedited, vibrance.skintonescurve, pedited->vibrance.skintonescurve);
}
- if (keyFile.has_group ("White Balance")) {
+ if (keyFile.has_group("White Balance")) {
assignFromKeyfile(keyFile, "White Balance", "Enabled", pedited, wb.enabled, pedited->wb.enabled);
assignFromKeyfile(keyFile, "White Balance", "Setting", pedited, wb.method, pedited->wb.method);
assignFromKeyfile(keyFile, "White Balance", "Temperature", pedited, wb.temperature, pedited->wb.temperature);
@@ -3851,12 +3866,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "White Balance", "TemperatureBias", pedited, wb.tempBias, pedited->wb.tempBias);
}
- if (keyFile.has_group ("Defringing")) {
+ if (keyFile.has_group("Defringing")) {
assignFromKeyfile(keyFile, "Defringing", "Enabled", pedited, defringe.enabled, pedited->defringe.enabled);
assignFromKeyfile(keyFile, "Defringing", "Radius", pedited, defringe.radius, pedited->defringe.radius);
- if (keyFile.has_key ("Defringing", "Threshold")) {
- defringe.threshold = (float)keyFile.get_integer ("Defringing", "Threshold");
+ if (keyFile.has_key("Defringing", "Threshold")) {
+ defringe.threshold = (float)keyFile.get_integer("Defringing", "Threshold");
if (pedited) {
pedited->defringe.threshold = true;
@@ -3864,13 +3879,13 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
if (ppVersion < 310) {
- defringe.threshold = sqrt (defringe.threshold * 33.f / 5.f);
+ defringe.threshold = sqrt(defringe.threshold * 33.f / 5.f);
}
assignFromKeyfile(keyFile, "Defringing", "HueCurve", pedited, defringe.huecurve, pedited->defringe.huecurve);
}
- if (keyFile.has_group ("Color appearance")) {
+ if (keyFile.has_group("Color appearance")) {
assignFromKeyfile(keyFile, "Color appearance", "Enabled", pedited, colorappearance.enabled, pedited->colorappearance.enabled);
assignFromKeyfile(keyFile, "Color appearance", "Degree", pedited, colorappearance.degree, pedited->colorappearance.degree);
assignFromKeyfile(keyFile, "Color appearance", "AutoDegree", pedited, colorappearance.autodegree, pedited->colorappearance.autodegree);
@@ -3936,12 +3951,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
- if (keyFile.has_group ("Impulse Denoising")) {
+ if (keyFile.has_group("Impulse Denoising")) {
assignFromKeyfile(keyFile, "Impulse Denoising", "Enabled", pedited, impulseDenoise.enabled, pedited->impulseDenoise.enabled);
assignFromKeyfile(keyFile, "Impulse Denoising", "Threshold", pedited, impulseDenoise.thresh, pedited->impulseDenoise.thresh);
}
- if (keyFile.has_group ("Directional Pyramid Denoising")) {//TODO: No longer an accurate description for FT denoise
+ if (keyFile.has_group("Directional Pyramid Denoising")) { //TODO: No longer an accurate description for FT denoise
assignFromKeyfile(keyFile, "Directional Pyramid Denoising", "Enabled", pedited, dirpyrDenoise.enabled, pedited->dirpyrDenoise.enabled);
assignFromKeyfile(keyFile, "Directional Pyramid Denoising", "Enhance", pedited, dirpyrDenoise.enhance, pedited->dirpyrDenoise.enhance);
assignFromKeyfile(keyFile, "Directional Pyramid Denoising", "Median", pedited, dirpyrDenoise.median, pedited->dirpyrDenoise.median);
@@ -3957,6 +3972,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
assignFromKeyfile(keyFile, "Directional Pyramid Denoising", "C2Method", pedited, dirpyrDenoise.C2method, pedited->dirpyrDenoise.C2method);
+
if (dirpyrDenoise.C2method == "PREV") {
dirpyrDenoise.C2method = "MANU";
}
@@ -3975,7 +3991,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Directional Pyramid Denoising", "Passes", pedited, dirpyrDenoise.passes, pedited->dirpyrDenoise.passes);
}
- if (keyFile.has_group ("EPD")) {
+ if (keyFile.has_group("EPD")) {
assignFromKeyfile(keyFile, "EPD", "Enabled", pedited, epd.enabled, pedited->epd.enabled);
assignFromKeyfile(keyFile, "EPD", "Strength", pedited, epd.strength, pedited->epd.strength);
assignFromKeyfile(keyFile, "EPD", "Gamma", pedited, epd.gamma, pedited->epd.gamma);
@@ -3984,7 +4000,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "EPD", "ReweightingIterates", pedited, epd.reweightingIterates, pedited->epd.reweightingIterates);
}
- if (keyFile.has_group ("FattalToneMapping")) {
+ if (keyFile.has_group("FattalToneMapping")) {
assignFromKeyfile(keyFile, "FattalToneMapping", "Enabled", pedited, fattal.enabled, pedited->fattal.enabled);
assignFromKeyfile(keyFile, "FattalToneMapping", "Threshold", pedited, fattal.threshold, pedited->fattal.threshold);
assignFromKeyfile(keyFile, "FattalToneMapping", "Amount", pedited, fattal.amount, pedited->fattal.amount);
@@ -3998,38 +4014,44 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Shadows & Highlights", "Shadows", pedited, sh.shadows, pedited->sh.shadows);
assignFromKeyfile(keyFile, "Shadows & Highlights", "ShadowTonalWidth", pedited, sh.stonalwidth, pedited->sh.stonalwidth);
assignFromKeyfile(keyFile, "Shadows & Highlights", "Radius", pedited, sh.radius, pedited->sh.radius);
+
if (keyFile.has_key("Shadows & Highlights", "LocalContrast") && ppVersion < 329) {
int lc = keyFile.get_integer("Shadows & Highlights", "LocalContrast");
localContrast.amount = float(lc) / 30.;
+
if (pedited) {
pedited->localContrast.amount = true;
}
+
localContrast.enabled = sh.enabled;
+
if (pedited) {
pedited->localContrast.enabled = true;
}
+
localContrast.radius = sh.radius;
+
if (pedited) {
pedited->localContrast.radius = true;
}
}
}
- if (keyFile.has_group ("Crop")) {
+ if (keyFile.has_group("Crop")) {
assignFromKeyfile(keyFile, "Crop", "Enabled", pedited, crop.enabled, pedited->crop.enabled);
assignFromKeyfile(keyFile, "Crop", "X", pedited, crop.x, pedited->crop.x);
assignFromKeyfile(keyFile, "Crop", "Y", pedited, crop.y, pedited->crop.y);
- if (keyFile.has_key ("Crop", "W")) {
- crop.w = std::max (keyFile.get_integer ("Crop", "W"), 1);
+ if (keyFile.has_key("Crop", "W")) {
+ crop.w = std::max(keyFile.get_integer("Crop", "W"), 1);
if (pedited) {
pedited->crop.w = true;
}
}
- if (keyFile.has_key ("Crop", "H")) {
- crop.h = std::max (keyFile.get_integer ("Crop", "H"), 1);
+ if (keyFile.has_key("Crop", "H")) {
+ crop.h = std::max(keyFile.get_integer("Crop", "H"), 1);
if (pedited) {
pedited->crop.h = true;
@@ -4052,39 +4074,40 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
crop.ratio = "11:17 - Tabloid";
}
}
+
assignFromKeyfile(keyFile, "Crop", "Orientation", pedited, crop.orientation, pedited->crop.orientation);
assignFromKeyfile(keyFile, "Crop", "Guide", pedited, crop.guide, pedited->crop.guide);
}
- if (keyFile.has_group ("Coarse Transformation")) {
+ if (keyFile.has_group("Coarse Transformation")) {
assignFromKeyfile(keyFile, "Coarse Transformation", "Rotate", pedited, coarse.rotate, pedited->coarse.rotate);
assignFromKeyfile(keyFile, "Coarse Transformation", "HorizontalFlip", pedited, coarse.hflip, pedited->coarse.hflip);
assignFromKeyfile(keyFile, "Coarse Transformation", "VerticalFlip", pedited, coarse.vflip, pedited->coarse.vflip);
}
- if (keyFile.has_group ("Rotation")) {
+ if (keyFile.has_group("Rotation")) {
assignFromKeyfile(keyFile, "Rotation", "Degree", pedited, rotate.degree, pedited->rotate.degree);
}
- if (keyFile.has_group ("Common Properties for Transformations")) {
+ if (keyFile.has_group("Common Properties for Transformations")) {
assignFromKeyfile(keyFile, "Common Properties for Transformations", "AutoFill", pedited, commonTrans.autofill, pedited->commonTrans.autofill);
}
- if (keyFile.has_group ("Distortion")) {
+ if (keyFile.has_group("Distortion")) {
assignFromKeyfile(keyFile, "Distortion", "Amount", pedited, distortion.amount, pedited->distortion.amount);
}
- if (keyFile.has_group ("LensProfile")) {
- if (keyFile.has_key ("LensProfile", "LcMode")) {
- lensProf.lcMode = lensProf.getMethodNumber (keyFile.get_string ("LensProfile", "LcMode"));
+ if (keyFile.has_group("LensProfile")) {
+ if (keyFile.has_key("LensProfile", "LcMode")) {
+ lensProf.lcMode = lensProf.getMethodNumber(keyFile.get_string("LensProfile", "LcMode"));
if (pedited) {
pedited->lensProf.lcMode = true;
}
}
- if (keyFile.has_key ("LensProfile", "LCPFile")) {
- lensProf.lcpFile = expandRelativePath (fname, "", keyFile.get_string ("LensProfile", "LCPFile"));
+ if (keyFile.has_key("LensProfile", "LCPFile")) {
+ lensProf.lcpFile = expandRelativePath(fname, "", keyFile.get_string("LensProfile", "LCPFile"));
if (pedited) {
pedited->lensProf.lcpFile = true;
@@ -4101,6 +4124,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
if (keyFile.has_key("LensProfile", "LFCameraMake")) {
lensProf.lfCameraMake = keyFile.get_string("LensProfile", "LFCameraMake");
+
if (pedited) {
pedited->lensProf.lfCameraMake = true;
}
@@ -4108,6 +4132,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
if (keyFile.has_key("LensProfile", "LFCameraModel")) {
lensProf.lfCameraModel = keyFile.get_string("LensProfile", "LFCameraModel");
+
if (pedited) {
pedited->lensProf.lfCameraModel = true;
}
@@ -4115,18 +4140,19 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
if (keyFile.has_key("LensProfile", "LFLens")) {
lensProf.lfLens = keyFile.get_string("LensProfile", "LFLens");
+
if (pedited) {
pedited->lensProf.lfLens = true;
}
}
}
- if (keyFile.has_group ("Perspective")) {
+ if (keyFile.has_group("Perspective")) {
assignFromKeyfile(keyFile, "Perspective", "Horizontal", pedited, perspective.horizontal, pedited->perspective.horizontal);
assignFromKeyfile(keyFile, "Perspective", "Vertical", pedited, perspective.vertical, pedited->perspective.vertical);
}
- if (keyFile.has_group ("Gradient")) {
+ if (keyFile.has_group("Gradient")) {
assignFromKeyfile(keyFile, "Gradient", "Enabled", pedited, gradient.enabled, pedited->gradient.enabled);
assignFromKeyfile(keyFile, "Gradient", "Degree", pedited, gradient.degree, pedited->gradient.degree);
assignFromKeyfile(keyFile, "Gradient", "Feather", pedited, gradient.feather, pedited->gradient.feather);
@@ -4135,19 +4161,19 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Gradient", "CenterY", pedited, gradient.centerY, pedited->gradient.centerY);
}
- if (keyFile.has_group ("PCVignette")) {
+ if (keyFile.has_group("PCVignette")) {
assignFromKeyfile(keyFile, "PCVignette", "Enabled", pedited, pcvignette.enabled, pedited->pcvignette.enabled);
assignFromKeyfile(keyFile, "PCVignette", "Strength", pedited, pcvignette.strength, pedited->pcvignette.strength);
assignFromKeyfile(keyFile, "PCVignette", "Feather", pedited, pcvignette.feather, pedited->pcvignette.feather);
assignFromKeyfile(keyFile, "PCVignette", "Roundness", pedited, pcvignette.roundness, pedited->pcvignette.roundness);
}
- if (keyFile.has_group ("CACorrection")) {
+ if (keyFile.has_group("CACorrection")) {
assignFromKeyfile(keyFile, "CACorrection", "Red", pedited, cacorrection.red, pedited->cacorrection.red);
assignFromKeyfile(keyFile, "CACorrection", "Blue", pedited, cacorrection.blue, pedited->cacorrection.blue);
}
- if (keyFile.has_group ("Vignetting Correction")) {
+ if (keyFile.has_group("Vignetting Correction")) {
assignFromKeyfile(keyFile, "Vignetting Correction", "Amount", pedited, vignetting.amount, pedited->vignetting.amount);
assignFromKeyfile(keyFile, "Vignetting Correction", "Radius", pedited, vignetting.radius, pedited->vignetting.radius);
assignFromKeyfile(keyFile, "Vignetting Correction", "Strength", pedited, vignetting.strength, pedited->vignetting.strength);
@@ -4155,7 +4181,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Vignetting Correction", "CenterY", pedited, vignetting.centerY, pedited->vignetting.centerY);
}
- if (keyFile.has_group ("Resize")) {
+ if (keyFile.has_group("Resize")) {
assignFromKeyfile(keyFile, "Resize", "Enabled", pedited, resize.enabled, pedited->resize.enabled);
assignFromKeyfile(keyFile, "Resize", "Scale", pedited, resize.scale, pedited->resize.scale);
assignFromKeyfile(keyFile, "Resize", "AppliesTo", pedited, resize.appliesTo, pedited->resize.appliesTo);
@@ -4173,21 +4199,21 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_group ("PostResizeSharpening")) {
+ if (keyFile.has_group("PostResizeSharpening")) {
assignFromKeyfile(keyFile, "PostResizeSharpening", "Enabled", pedited, prsharpening.enabled, pedited->prsharpening.enabled);
assignFromKeyfile(keyFile, "PostResizeSharpening", "Contrast", pedited, prsharpening.contrast, pedited->prsharpening.contrast);
assignFromKeyfile(keyFile, "PostResizeSharpening", "Radius", pedited, prsharpening.radius, pedited->prsharpening.radius);
assignFromKeyfile(keyFile, "PostResizeSharpening", "Amount", pedited, prsharpening.amount, pedited->prsharpening.amount);
- if (keyFile.has_key ("PostResizeSharpening", "Threshold")) {
+ if (keyFile.has_key("PostResizeSharpening", "Threshold")) {
if (ppVersion < 302) {
- int thresh = min (keyFile.get_integer ("PostResizeSharpening", "Threshold"), 2000);
- prsharpening.threshold.setValues (thresh, thresh, 2000, 2000); // TODO: 2000 is the maximum value and is taken of rtgui/sharpening.cc ; should be changed by the tool modularization
+ int thresh = min(keyFile.get_integer("PostResizeSharpening", "Threshold"), 2000);
+ prsharpening.threshold.setValues(thresh, thresh, 2000, 2000); // TODO: 2000 is the maximum value and is taken of rtgui/sharpening.cc ; should be changed by the tool modularization
} else {
- const std::vector thresh = keyFile.get_integer_list ("PostResizeSharpening", "Threshold");
+ const std::vector thresh = keyFile.get_integer_list("PostResizeSharpening", "Threshold");
if (thresh.size() >= 4) {
- prsharpening.threshold.setValues (thresh[0], thresh[1], min (thresh[2], 2000), min (thresh[3], 2000));
+ prsharpening.threshold.setValues(thresh[0], thresh[1], min(thresh[2], 2000), min(thresh[3], 2000));
}
}
@@ -4208,12 +4234,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "PostResizeSharpening", "DeconvIterations", pedited, prsharpening.deconviter, pedited->prsharpening.deconviter);
}
- if (keyFile.has_group ("Color Management")) {
- if (keyFile.has_key ("Color Management", "InputProfile")) {
- icm.input = expandRelativePath (fname, "file:", keyFile.get_string ("Color Management", "InputProfile"));
+ if (keyFile.has_group("Color Management")) {
+ if (keyFile.has_key("Color Management", "InputProfile")) {
+ icm.inputProfile = expandRelativePath(fname, "file:", keyFile.get_string("Color Management", "InputProfile"));
if (pedited) {
- pedited->icm.input = true;
+ pedited->icm.inputProfile = true;
}
}
@@ -4222,11 +4248,35 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Color Management", "ApplyBaselineExposureOffset", pedited, icm.applyBaselineExposureOffset, pedited->icm.applyBaselineExposureOffset);
assignFromKeyfile(keyFile, "Color Management", "ApplyHueSatMap", pedited, icm.applyHueSatMap, pedited->icm.applyHueSatMap);
assignFromKeyfile(keyFile, "Color Management", "DCPIlluminant", pedited, icm.dcpIlluminant, pedited->icm.dcpIlluminant);
- assignFromKeyfile(keyFile, "Color Management", "WorkingProfile", pedited, icm.working, pedited->icm.working);
- assignFromKeyfile(keyFile, "Color Management", "OutputProfile", pedited, icm.output, pedited->icm.output);
+ assignFromKeyfile(keyFile, "Color Management", "WorkingProfile", pedited, icm.workingProfile, pedited->icm.workingProfile);
+ assignFromKeyfile(keyFile, "Color Management", "WorkingTRC", pedited, icm.workingTRC, pedited->icm.workingTRC);
+ assignFromKeyfile(keyFile, "Color Management", "WorkingTRCGamma", pedited, icm.workingTRCGamma, pedited->icm.workingTRCGamma);
+ assignFromKeyfile(keyFile, "Color Management", "WorkingTRCSlope", pedited, icm.workingTRCSlope, pedited->icm.workingTRCSlope);
- if (keyFile.has_key ("Color Management", "OutputProfileIntent")) {
- Glib::ustring intent = keyFile.get_string ("Color Management", "OutputProfileIntent");
+ assignFromKeyfile(keyFile, "Color Management", "OutputProfile", pedited, icm.outputProfile, pedited->icm.outputProfile);
+ if (ppVersion < 341) {
+ if (icm.outputProfile == "RT_Medium_gsRGB") {
+ icm.outputProfile = "RTv4_Medium";
+ } else if (icm.outputProfile == "RT_Large_gBT709" || icm.outputProfile == "RT_Large_g10" || icm.outputProfile == "RT_Large_gsRGB") {
+ icm.outputProfile = "RTv4_Large";
+ } else if (icm.outputProfile == "WideGamutRGB") {
+ icm.outputProfile = "RTv4_Wide";
+ } else if (icm.outputProfile == "RT_sRGB_gBT709" || icm.outputProfile == "RT_sRGB_g10" || icm.outputProfile == "RT_sRGB") {
+ icm.outputProfile = "RTv4_sRGB";
+ } else if (icm.outputProfile == "BetaRGB") { // Have we ever provided this profile ? Should we convert this filename ?
+ icm.outputProfile = "RTv4_Beta";
+ } else if (icm.outputProfile == "BestRGB") { // Have we ever provided this profile ? Should we convert this filename ?
+ icm.outputProfile = "RTv4_Best";
+ } else if (icm.outputProfile == "Rec2020") {
+ icm.outputProfile = "RTv4_Rec2020";
+ } else if (icm.outputProfile == "Bruce") { // Have we ever provided this profile ? Should we convert this filename ?
+ icm.outputProfile = "RTv4_Bruce";
+ } else if (icm.outputProfile == "ACES") {
+ icm.outputProfile = "RTv4_ACES-AP0";
+ }
+ }
+ if (keyFile.has_key("Color Management", "OutputProfileIntent")) {
+ Glib::ustring intent = keyFile.get_string("Color Management", "OutputProfileIntent");
if (intent == "Perceptual") {
icm.outputIntent = RI_PERCEPTUAL;
@@ -4242,15 +4292,10 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
pedited->icm.outputIntent = true;
}
}
-
assignFromKeyfile(keyFile, "Color Management", "OutputBPC", pedited, icm.outputBPC, pedited->icm.outputBPC);
- assignFromKeyfile(keyFile, "Color Management", "Gammafree", pedited, icm.gamma, pedited->icm.gamma);
- assignFromKeyfile(keyFile, "Color Management", "Freegamma", pedited, icm.freegamma, pedited->icm.freegamma);
- assignFromKeyfile(keyFile, "Color Management", "GammaValue", pedited, icm.gampos, pedited->icm.gampos);
- assignFromKeyfile(keyFile, "Color Management", "GammaSlope", pedited, icm.slpos, pedited->icm.slpos);
}
- if (keyFile.has_group ("Wavelet")) {
+ if (keyFile.has_group("Wavelet")) {
assignFromKeyfile(keyFile, "Wavelet", "Enabled", pedited, wavelet.enabled, pedited->wavelet.enabled);
assignFromKeyfile(keyFile, "Wavelet", "Strength", pedited, wavelet.strength, pedited->wavelet.strength);
assignFromKeyfile(keyFile, "Wavelet", "Balance", pedited, wavelet.balance, pedited->wavelet.balance);
@@ -4268,15 +4313,18 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Wavelet", "Lipst", pedited, wavelet.lipst, pedited->wavelet.lipst);
assignFromKeyfile(keyFile, "Wavelet", "AvoidColorShift", pedited, wavelet.avoid, pedited->wavelet.avoid);
assignFromKeyfile(keyFile, "Wavelet", "TMr", pedited, wavelet.tmr, pedited->wavelet.tmr);
+
if (ppVersion < 331) { // wavelet.Lmethod was a string before version 331
Glib::ustring temp;
assignFromKeyfile(keyFile, "Wavelet", "LevMethod", pedited, temp, pedited->wavelet.Lmethod);
+
if (!temp.empty()) {
wavelet.Lmethod = std::stoi(temp);
}
} else {
assignFromKeyfile(keyFile, "Wavelet", "LevMethod", pedited, wavelet.Lmethod, pedited->wavelet.Lmethod);
}
+
assignFromKeyfile(keyFile, "Wavelet", "ChoiceLevMethod", pedited, wavelet.CLmethod, pedited->wavelet.CLmethod);
assignFromKeyfile(keyFile, "Wavelet", "BackMethod", pedited, wavelet.Backmethod, pedited->wavelet.Backmethod);
assignFromKeyfile(keyFile, "Wavelet", "TilesMethod", pedited, wavelet.Tilesmethod, pedited->wavelet.Tilesmethod);
@@ -4322,11 +4370,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Wavelet", "CHcurve", pedited, wavelet.Chcurve, pedited->wavelet.Chcurve);
assignFromKeyfile(keyFile, "Wavelet", "WavclCurve", pedited, wavelet.wavclCurve, pedited->wavelet.wavclCurve);
- if (keyFile.has_key ("Wavelet", "Hueskin")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "Hueskin");
+ if (keyFile.has_key("Wavelet", "Hueskin")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "Hueskin");
if (thresh.size() >= 4) {
- wavelet.hueskin.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.hueskin.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4334,11 +4382,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "HueRange")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "HueRange");
+ if (keyFile.has_key("Wavelet", "HueRange")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "HueRange");
if (thresh.size() >= 4) {
- wavelet.hueskin2.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.hueskin2.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4346,11 +4394,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "HLRange")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "HLRange");
+ if (keyFile.has_key("Wavelet", "HLRange")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "HLRange");
if (thresh.size() >= 4) {
- wavelet.hllev.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.hllev.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4358,11 +4406,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "SHRange")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "SHRange");
+ if (keyFile.has_key("Wavelet", "SHRange")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "SHRange");
if (thresh.size() >= 4) {
- wavelet.bllev.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.bllev.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4370,11 +4418,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Edgcont")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "Edgcont");
+ if (keyFile.has_key("Wavelet", "Edgcont")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "Edgcont");
if (thresh.size() >= 4) {
- wavelet.edgcont.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.edgcont.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4382,11 +4430,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Level0noise")) {
- const std::vector thresh = keyFile.get_double_list ("Wavelet", "Level0noise");
+ if (keyFile.has_key("Wavelet", "Level0noise")) {
+ const std::vector thresh = keyFile.get_double_list("Wavelet", "Level0noise");
if (thresh.size() >= 2) {
- wavelet.level0noise.setValues (thresh[0], thresh[1]);
+ wavelet.level0noise.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4394,11 +4442,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Level1noise")) {
- const std::vector thresh = keyFile.get_double_list ("Wavelet", "Level1noise");
+ if (keyFile.has_key("Wavelet", "Level1noise")) {
+ const std::vector thresh = keyFile.get_double_list("Wavelet", "Level1noise");
if (thresh.size() >= 2) {
- wavelet.level1noise.setValues (thresh[0], thresh[1]);
+ wavelet.level1noise.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4406,11 +4454,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Level2noise")) {
- const std::vector thresh = keyFile.get_double_list ("Wavelet", "Level2noise");
+ if (keyFile.has_key("Wavelet", "Level2noise")) {
+ const std::vector thresh = keyFile.get_double_list("Wavelet", "Level2noise");
if (thresh.size() >= 2) {
- wavelet.level2noise.setValues (thresh[0], thresh[1]);
+ wavelet.level2noise.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4418,11 +4466,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Level3noise")) {
- const std::vector thresh = keyFile.get_double_list ("Wavelet", "Level3noise");
+ if (keyFile.has_key("Wavelet", "Level3noise")) {
+ const std::vector thresh = keyFile.get_double_list("Wavelet", "Level3noise");
if (thresh.size() >= 2) {
- wavelet.level3noise.setValues (thresh[0], thresh[1]);
+ wavelet.level3noise.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4430,11 +4478,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Pastlev")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "Pastlev");
+ if (keyFile.has_key("Wavelet", "Pastlev")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "Pastlev");
if (thresh.size() >= 4) {
- wavelet.pastlev.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.pastlev.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4442,11 +4490,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("Wavelet", "Satlev")) {
- const std::vector thresh = keyFile.get_integer_list ("Wavelet", "Satlev");
+ if (keyFile.has_key("Wavelet", "Satlev")) {
+ const std::vector thresh = keyFile.get_integer_list("Wavelet", "Satlev");
if (thresh.size() >= 4) {
- wavelet.satlev.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ wavelet.satlev.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4462,8 +4510,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
std::stringstream ss;
ss << "Contrast" << (i + 1);
- if (keyFile.has_key ("Wavelet", ss.str())) {
- wavelet.c[i] = keyFile.get_integer ("Wavelet", ss.str());
+ if (keyFile.has_key("Wavelet", ss.str())) {
+ wavelet.c[i] = keyFile.get_integer("Wavelet", ss.str());
if (pedited) {
pedited->wavelet.c[i] = true;
@@ -4475,14 +4523,15 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
std::stringstream ss;
ss << "Chroma" << (i + 1);
- if (keyFile.has_key ("Wavelet", ss.str())) {
- wavelet.ch[i] = keyFile.get_integer ("Wavelet", ss.str());
+ if (keyFile.has_key("Wavelet", ss.str())) {
+ wavelet.ch[i] = keyFile.get_integer("Wavelet", ss.str());
if (pedited) {
pedited->wavelet.ch[i] = true;
}
}
}
+
assignFromKeyfile(keyFile, "Wavelet", "Expedge", pedited, wavelet.expedge, pedited->wavelet.expedge);
assignFromKeyfile(keyFile, "Wavelet", "Expresid", pedited, wavelet.expresid, pedited->wavelet.expresid);
assignFromKeyfile(keyFile, "Wavelet", "Expfinal", pedited, wavelet.expfinal, pedited->wavelet.expfinal);
@@ -4490,16 +4539,16 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "Wavelet", "Expnoise", pedited, wavelet.expnoise, pedited->wavelet.expnoise);
}
- if (keyFile.has_group ("Directional Pyramid Equalizer")) {
+ if (keyFile.has_group("Directional Pyramid Equalizer")) {
assignFromKeyfile(keyFile, "Directional Pyramid Equalizer", "Enabled", pedited, dirpyrequalizer.enabled, pedited->dirpyrequalizer.enabled);
assignFromKeyfile(keyFile, "Directional Pyramid Equalizer", "Gamutlab", pedited, dirpyrequalizer.gamutlab, pedited->dirpyrequalizer.gamutlab);
assignFromKeyfile(keyFile, "Directional Pyramid Equalizer", "cbdlMethod", pedited, dirpyrequalizer.cbdlMethod, pedited->dirpyrequalizer.cbdlMethod);
- if (keyFile.has_key ("Directional Pyramid Equalizer", "Hueskin")) {
- const std::vector thresh = keyFile.get_integer_list ("Directional Pyramid Equalizer", "Hueskin");
+ if (keyFile.has_key("Directional Pyramid Equalizer", "Hueskin")) {
+ const std::vector thresh = keyFile.get_integer_list("Directional Pyramid Equalizer", "Hueskin");
if (thresh.size() >= 4) {
- dirpyrequalizer.hueskin.setValues (thresh[0], thresh[1], min (thresh[2], 300), min (thresh[3], 300));
+ dirpyrequalizer.hueskin.setValues(thresh[0], thresh[1], min(thresh[2], 300), min(thresh[3], 300));
}
if (pedited) {
@@ -4512,15 +4561,15 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
std::stringstream ss;
ss << "Mult" << i;
- if (keyFile.has_key ("Directional Pyramid Equalizer", ss.str())) {
+ if (keyFile.has_key("Directional Pyramid Equalizer", ss.str())) {
if (i == 4) {
- dirpyrequalizer.threshold = keyFile.get_double ("Directional Pyramid Equalizer", ss.str());
+ dirpyrequalizer.threshold = keyFile.get_double("Directional Pyramid Equalizer", ss.str());
if (pedited) {
pedited->dirpyrequalizer.threshold = true;
}
} else {
- dirpyrequalizer.mult[i] = keyFile.get_double ("Directional Pyramid Equalizer", ss.str());
+ dirpyrequalizer.mult[i] = keyFile.get_double("Directional Pyramid Equalizer", ss.str());
if (pedited) {
pedited->dirpyrequalizer.mult[i] = true;
@@ -4536,8 +4585,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
std::stringstream ss;
ss << "Mult" << i;
- if (keyFile.has_key ("Directional Pyramid Equalizer", ss.str())) {
- dirpyrequalizer.mult[i] = keyFile.get_double ("Directional Pyramid Equalizer", ss.str());
+ if (keyFile.has_key("Directional Pyramid Equalizer", ss.str())) {
+ dirpyrequalizer.mult[i] = keyFile.get_double("Directional Pyramid Equalizer", ss.str());
if (pedited) {
pedited->dirpyrequalizer.mult[i] = true;
@@ -4555,14 +4604,15 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "SoftLight", "Strength", pedited, softlight.strength, pedited->softlight.strength);
}
- if (keyFile.has_group ("Film Simulation")) {
+ if (keyFile.has_group("Film Simulation")) {
assignFromKeyfile(keyFile, "Film Simulation", "Enabled", pedited, filmSimulation.enabled, pedited->filmSimulation.enabled);
assignFromKeyfile(keyFile, "Film Simulation", "ClutFilename", pedited, filmSimulation.clutFilename, pedited->filmSimulation.clutFilename);
- if (keyFile.has_key ("Film Simulation", "Strength")) {
+
+ if (keyFile.has_key("Film Simulation", "Strength")) {
if (ppVersion < 321) {
- filmSimulation.strength = keyFile.get_double ("Film Simulation", "Strength") * 100 + 0.1;
+ filmSimulation.strength = keyFile.get_double("Film Simulation", "Strength") * 100 + 0.1;
} else {
- filmSimulation.strength = keyFile.get_integer ("Film Simulation", "Strength");
+ filmSimulation.strength = keyFile.get_integer("Film Simulation", "Strength");
}
if (pedited) {
@@ -4571,15 +4621,17 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_group ("HSV Equalizer")) {
+ if (keyFile.has_group("HSV Equalizer")) {
if (ppVersion >= 329) {
assignFromKeyfile(keyFile, "HSV Equalizer", "Enabled", pedited, hsvequalizer.enabled, pedited->hsvequalizer.enabled);
} else {
hsvequalizer.enabled = true;
+
if (pedited) {
pedited->hsvequalizer.enabled = true;
}
}
+
if (ppVersion >= 300) {
assignFromKeyfile(keyFile, "HSV Equalizer", "HCurve", pedited, hsvequalizer.hcurve, pedited->hsvequalizer.hcurve);
assignFromKeyfile(keyFile, "HSV Equalizer", "SCurve", pedited, hsvequalizer.scurve, pedited->hsvequalizer.scurve);
@@ -4587,22 +4639,24 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_group ("RGB Curves")) {
+ if (keyFile.has_group("RGB Curves")) {
if (ppVersion >= 329) {
assignFromKeyfile(keyFile, "RGB Curves", "Enabled", pedited, rgbCurves.enabled, pedited->rgbCurves.enabled);
} else {
rgbCurves.enabled = true;
+
if (pedited) {
pedited->rgbCurves.enabled = true;
}
}
+
assignFromKeyfile(keyFile, "RGB Curves", "LumaMode", pedited, rgbCurves.lumamode, pedited->rgbCurves.lumamode);
assignFromKeyfile(keyFile, "RGB Curves", "rCurve", pedited, rgbCurves.rcurve, pedited->rgbCurves.rcurve);
assignFromKeyfile(keyFile, "RGB Curves", "gCurve", pedited, rgbCurves.gcurve, pedited->rgbCurves.gcurve);
assignFromKeyfile(keyFile, "RGB Curves", "bCurve", pedited, rgbCurves.bcurve, pedited->rgbCurves.bcurve);
}
- if (keyFile.has_group ("ColorToning")) {
+ if (keyFile.has_group("ColorToning")) {
assignFromKeyfile(keyFile, "ColorToning", "Enabled", pedited, colorToning.enabled, pedited->colorToning.enabled);
assignFromKeyfile(keyFile, "ColorToning", "Method", pedited, colorToning.method, pedited->colorToning.method);
assignFromKeyfile(keyFile, "ColorToning", "Lumamode", pedited, colorToning.lumamode, pedited->colorToning.lumamode);
@@ -4614,11 +4668,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "ColorToning", "SaturatedOpacity", pedited, colorToning.saturatedOpacity, pedited->colorToning.saturatedopacity);
assignFromKeyfile(keyFile, "ColorToning", "Strength", pedited, colorToning.strength, pedited->colorToning.strength);
- if (keyFile.has_key ("ColorToning", "HighlightsColorSaturation")) {
- const std::vector thresh = keyFile.get_integer_list ("ColorToning", "HighlightsColorSaturation");
+ if (keyFile.has_key("ColorToning", "HighlightsColorSaturation")) {
+ const std::vector thresh = keyFile.get_integer_list("ColorToning", "HighlightsColorSaturation");
if (thresh.size() >= 2) {
- colorToning.hlColSat.setValues (thresh[0], thresh[1]);
+ colorToning.hlColSat.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4626,11 +4680,11 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_key ("ColorToning", "ShadowsColorSaturation")) {
- const std::vector thresh = keyFile.get_integer_list ("ColorToning", "ShadowsColorSaturation");
+ if (keyFile.has_key("ColorToning", "ShadowsColorSaturation")) {
+ const std::vector thresh = keyFile.get_integer_list("ColorToning", "ShadowsColorSaturation");
if (thresh.size() >= 2) {
- colorToning.shadowsColSat.setValues (thresh[0], thresh[1]);
+ colorToning.shadowsColSat.setValues(thresh[0], thresh[1]);
}
if (pedited) {
@@ -4663,12 +4717,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
colorToning.labgridAHigh *= scale;
colorToning.labgridBLow *= scale;
colorToning.labgridBHigh *= scale;
- }
+ }
}
- if (keyFile.has_group ("RAW")) {
- if (keyFile.has_key ("RAW", "DarkFrame")) {
- raw.dark_frame = expandRelativePath (fname, "", keyFile.get_string ("RAW", "DarkFrame" ));
+ if (keyFile.has_group("RAW")) {
+ if (keyFile.has_key("RAW", "DarkFrame")) {
+ raw.dark_frame = expandRelativePath(fname, "", keyFile.get_string("RAW", "DarkFrame"));
if (pedited) {
pedited->raw.darkFrame = true;
@@ -4677,8 +4731,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "RAW", "DarkFrameAuto", pedited, raw.df_autoselect, pedited->raw.df_autoselect);
- if (keyFile.has_key ("RAW", "FlatFieldFile")) {
- raw.ff_file = expandRelativePath (fname, "", keyFile.get_string ("RAW", "FlatFieldFile" ));
+ if (keyFile.has_key("RAW", "FlatFieldFile")) {
+ raw.ff_file = expandRelativePath(fname, "", keyFile.get_string("RAW", "FlatFieldFile"));
if (pedited) {
pedited->raw.ff_file = true;
@@ -4689,6 +4743,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "RAW", "FlatFieldBlurRadius", pedited, raw.ff_BlurRadius, pedited->raw.ff_BlurRadius);
assignFromKeyfile(keyFile, "RAW", "FlatFieldBlurType", pedited, raw.ff_BlurType, pedited->raw.ff_BlurType);
assignFromKeyfile(keyFile, "RAW", "FlatFieldAutoClipControl", pedited, raw.ff_AutoClipControl, pedited->raw.ff_AutoClipControl);
+
if (ppVersion < 328) {
// With ppversion < 328 this value was stored as a boolean, which is nonsense.
// To avoid annoying warnings we skip reading and assume 0.
@@ -4696,20 +4751,24 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
} else {
assignFromKeyfile(keyFile, "RAW", "FlatFieldClipControl", pedited, raw.ff_clipControl, pedited->raw.ff_clipControl);
}
+
assignFromKeyfile(keyFile, "RAW", "CA", pedited, raw.ca_autocorrect, pedited->raw.ca_autocorrect);
assignFromKeyfile(keyFile, "RAW", "CARed", pedited, raw.cared, pedited->raw.cared);
assignFromKeyfile(keyFile, "RAW", "CABlue", pedited, raw.cablue, pedited->raw.cablue);
// For compatibility to elder pp3 versions
assignFromKeyfile(keyFile, "RAW", "HotDeadPixels", pedited, raw.hotPixelFilter, pedited->raw.hotPixelFilter);
raw.deadPixelFilter = raw.hotPixelFilter;
+
if (pedited) {
pedited->raw.deadPixelFilter = pedited->raw.hotPixelFilter;
}
+
assignFromKeyfile(keyFile, "RAW", "HotPixelFilter", pedited, raw.hotPixelFilter, pedited->raw.hotPixelFilter);
assignFromKeyfile(keyFile, "RAW", "DeadPixelFilter", pedited, raw.deadPixelFilter, pedited->raw.deadPixelFilter);
assignFromKeyfile(keyFile, "RAW", "HotDeadPixelThresh", pedited, raw.hotdeadpix_thresh, pedited->raw.hotdeadpix_thresh);
assignFromKeyfile(keyFile, "RAW", "PreExposure", pedited, raw.expos, pedited->raw.exPos);
assignFromKeyfile(keyFile, "RAW", "PrePreserv", pedited, raw.preser, pedited->raw.exPreser);
+
if (ppVersion < 320) {
assignFromKeyfile(keyFile, "RAW", "Method", pedited, raw.bayersensor.method, pedited->raw.bayersensor.method);
assignFromKeyfile(keyFile, "RAW", "CcSteps", pedited, raw.bayersensor.ccSteps, pedited->raw.bayersensor.ccSteps);
@@ -4726,12 +4785,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
}
- if (keyFile.has_group ("RAW Bayer")) {
+ if (keyFile.has_group("RAW Bayer")) {
assignFromKeyfile(keyFile, "RAW Bayer", "Method", pedited, raw.bayersensor.method, pedited->raw.bayersensor.method);
assignFromKeyfile(keyFile, "RAW Bayer", "Border", pedited, raw.bayersensor.border, pedited->raw.bayersensor.border);
- if (keyFile.has_key ("RAW Bayer", "ImageNum")) {
- raw.bayersensor.imageNum = keyFile.get_integer ("RAW Bayer", "ImageNum") - 1;
+ if (keyFile.has_key("RAW Bayer", "ImageNum")) {
+ raw.bayersensor.imageNum = keyFile.get_integer("RAW Bayer", "ImageNum") - 1;
if (pedited) {
pedited->raw.bayersensor.imageNum = true;
@@ -4745,20 +4804,23 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "RAW Bayer", "PreBlack3", pedited, raw.bayersensor.black3, pedited->raw.bayersensor.exBlack3);
assignFromKeyfile(keyFile, "RAW Bayer", "PreTwoGreen", pedited, raw.bayersensor.twogreen, pedited->raw.bayersensor.exTwoGreen);
assignFromKeyfile(keyFile, "RAW Bayer", "LineDenoise", pedited, raw.bayersensor.linenoise, pedited->raw.bayersensor.linenoise);
+
if (keyFile.has_key("RAW Bayer", "LineDenoiseDirection")) {
raw.bayersensor.linenoiseDirection = RAWParams::BayerSensor::LineNoiseDirection(keyFile.get_integer("RAW Bayer", "LineDenoiseDirection"));
+
if (pedited) {
pedited->raw.bayersensor.linenoiseDirection = true;
}
}
+
assignFromKeyfile(keyFile, "RAW Bayer", "GreenEqThreshold", pedited, raw.bayersensor.greenthresh, pedited->raw.bayersensor.greenEq);
assignFromKeyfile(keyFile, "RAW Bayer", "DCBIterations", pedited, raw.bayersensor.dcb_iterations, pedited->raw.bayersensor.dcbIterations);
assignFromKeyfile(keyFile, "RAW Bayer", "DCBEnhance", pedited, raw.bayersensor.dcb_enhance, pedited->raw.bayersensor.dcbEnhance);
assignFromKeyfile(keyFile, "RAW Bayer", "LMMSEIterations", pedited, raw.bayersensor.lmmse_iterations, pedited->raw.bayersensor.lmmseIterations);
assignFromKeyfile(keyFile, "RAW Bayer", "DualDemosaicContrast", pedited, raw.bayersensor.dualDemosaicContrast, pedited->raw.bayersensor.dualDemosaicContrast);
- if (keyFile.has_key ("RAW Bayer", "PixelShiftMotionCorrectionMethod")) {
- raw.bayersensor.pixelShiftMotionCorrectionMethod = (RAWParams::BayerSensor::PSMotionCorrectionMethod)keyFile.get_integer ("RAW Bayer", "PixelShiftMotionCorrectionMethod");
+ if (keyFile.has_key("RAW Bayer", "PixelShiftMotionCorrectionMethod")) {
+ raw.bayersensor.pixelShiftMotionCorrectionMethod = (RAWParams::BayerSensor::PSMotionCorrectionMethod)keyFile.get_integer("RAW Bayer", "PixelShiftMotionCorrectionMethod");
if (pedited) {
pedited->raw.bayersensor.pixelShiftMotionCorrectionMethod = true;
@@ -4800,7 +4862,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
assignFromKeyfile(keyFile, "RAW Bayer", "PDAFLinesFilter", pedited, raw.bayersensor.pdafLinesFilter, pedited->raw.bayersensor.pdafLinesFilter);
}
- if (keyFile.has_group ("RAW X-Trans")) {
+ if (keyFile.has_group("RAW X-Trans")) {
assignFromKeyfile(keyFile, "RAW X-Trans", "Method", pedited, raw.xtranssensor.method, pedited->raw.xtranssensor.method);
assignFromKeyfile(keyFile, "RAW X-Trans", "DualDemosaicContrast", pedited, raw.xtranssensor.dualDemosaicContrast, pedited->raw.xtranssensor.dualDemosaicContrast);
assignFromKeyfile(keyFile, "RAW X-Trans", "CcSteps", pedited, raw.xtranssensor.ccSteps, pedited->raw.xtranssensor.ccSteps);
@@ -4812,16 +4874,17 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
if (keyFile.has_group("MetaData")) {
int mode = int(MetaDataParams::TUNNEL);
assignFromKeyfile(keyFile, "MetaData", "Mode", pedited, mode, pedited->metadata.mode);
+
if (mode >= int(MetaDataParams::TUNNEL) && mode <= int(MetaDataParams::STRIP)) {
metadata.mode = static_cast(mode);
}
}
- if (keyFile.has_group ("Exif")) {
- std::vector keys = keyFile.get_keys ("Exif");
+ if (keyFile.has_group("Exif")) {
+ std::vector keys = keyFile.get_keys("Exif");
for (const auto& key : keyFile.get_keys("Exif")) {
- exif[key] = keyFile.get_string ("Exif", key);
+ exif[key] = keyFile.get_string("Exif", key);
if (pedited) {
pedited->exif = true;
@@ -4841,7 +4904,7 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
* tag content is fully replaced by the new one,
* i.e. they don't merge
*/
- if (keyFile.has_group ("IPTC")) {
+ if (keyFile.has_group("IPTC")) {
for (const auto& key : keyFile.get_keys("IPTC")) {
// does this key already exist?
const IPTCPairs::iterator element = iptc.find(key);
@@ -4852,8 +4915,8 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
}
// TODO: look out if merging Keywords and SupplementalCategories from the procparams chain would be interesting
- for (const auto& currLoadedTagValue : keyFile.get_string_list ("IPTC", key)) {
- iptc[key].push_back (currLoadedTagValue);
+ for (const auto& currLoadedTagValue : keyFile.get_string_list("IPTC", key)) {
+ iptc[key].push_back(currLoadedTagValue);
}
if (pedited) {
@@ -4864,12 +4927,12 @@ int ProcParams::load(const Glib::ustring& fname, ParamsEdited* pedited)
return 0;
} catch (const Glib::Error& e) {
- printf ("-->%s\n", e.what().c_str());
- setDefaults ();
+ printf("-->%s\n", e.what().c_str());
+ setDefaults();
return 1;
} catch (...) {
- printf ("-->unknown exception!\n");
- setDefaults ();
+ printf("-->unknown exception!\n");
+ setDefaults();
return 1;
}
@@ -4953,13 +5016,13 @@ int ProcParams::write(const Glib::ustring& fname, const Glib::ustring& content)
if (fname.length()) {
FILE *f;
- f = g_fopen (fname.c_str (), "wt");
+ f = g_fopen(fname.c_str(), "wt");
if (f == nullptr) {
error = 1;
} else {
- fprintf (f, "%s", content.c_str());
- fclose (f);
+ fprintf(f, "%s", content.c_str());
+ fclose(f);
}
}
@@ -4970,7 +5033,7 @@ PartialProfile::PartialProfile(bool createInstance, bool paramsEditedValue)
{
if (createInstance) {
pparams = new ProcParams();
- pedited = new ParamsEdited (paramsEditedValue);
+ pedited = new ParamsEdited(paramsEditedValue);
} else {
pparams = nullptr;
pedited = nullptr;
@@ -4980,13 +5043,13 @@ PartialProfile::PartialProfile(bool createInstance, bool paramsEditedValue)
PartialProfile::PartialProfile(ProcParams* pp, ParamsEdited* pe, bool fullCopy)
{
if (fullCopy && pp) {
- pparams = new ProcParams (*pp);
+ pparams = new ProcParams(*pp);
} else {
pparams = pp;
}
if (fullCopy && pe) {
- pedited = new ParamsEdited (*pe);
+ pedited = new ParamsEdited(*pe);
} else {
pedited = pe;
}
@@ -4995,13 +5058,13 @@ PartialProfile::PartialProfile(ProcParams* pp, ParamsEdited* pe, bool fullCopy)
PartialProfile::PartialProfile(const ProcParams* pp, const ParamsEdited* pe)
{
if (pp) {
- pparams = new ProcParams (*pp);
+ pparams = new ProcParams(*pp);
} else {
pparams = nullptr;
}
if (pe) {
- pedited = new ParamsEdited (*pe);
+ pedited = new ParamsEdited(*pe);
} else {
pedited = nullptr;
}
@@ -5044,7 +5107,7 @@ int PartialProfile::load(const Glib::ustring& fName)
} else if (fName == DEFPROFILE_DYNAMIC) {
return -1; // should not happen here
} else {
- return pparams->load (fName, pedited);
+ return pparams->load(fName, pedited);
}
}
@@ -5055,7 +5118,7 @@ int PartialProfile::load(const Glib::ustring& fName)
void PartialProfile::set(bool v)
{
if (pedited) {
- pedited->set (v);
+ pedited->set(v);
}
}
@@ -5063,7 +5126,7 @@ void PartialProfile::applyTo(ProcParams* destParams, bool fromLastSave) const
{
if (destParams && pparams && pedited) {
bool fromHistMatching = fromLastSave && destParams->toneCurve.histmatching && pparams->toneCurve.histmatching;
- pedited->combine (*destParams, *pparams, true);
+ pedited->combine(*destParams, *pparams, true);
if (!fromLastSave) {
destParams->toneCurve.fromHistMatching = fromHistMatching;
}
diff --git a/rtengine/procparams.h b/rtengine/procparams.h
index a3471fc65..bbc9763cf 100644
--- a/rtengine/procparams.h
+++ b/rtengine/procparams.h
@@ -76,14 +76,14 @@ public:
{
if (is_double) {
return
- std::fabs (bottom_left - rhs.bottom_left) < 1e-10
- && std::fabs (top_left - rhs.top_left) < 1e-10
- && std::fabs (bottom_right - rhs.bottom_right) < 1e-10
- && std::fabs (top_right - rhs.top_right) < 1e-10;
+ std::fabs(bottom_left - rhs.bottom_left) < 1e-10
+ && std::fabs(top_left - rhs.top_left) < 1e-10
+ && std::fabs(bottom_right - rhs.bottom_right) < 1e-10
+ && std::fabs(top_right - rhs.top_right) < 1e-10;
} else {
return
- std::fabs (bottom_left - rhs.bottom_left) < 1e-10
- && std::fabs (top_left - rhs.top_left) < 1e-10;
+ std::fabs(bottom_left - rhs.bottom_left) < 1e-10
+ && std::fabs(top_left - rhs.top_left) < 1e-10;
}
}
@@ -113,7 +113,7 @@ public:
return top_left;
}
- T getBottomLeft() const
+ T getBottomLeft() const
{
return bottom_left;
}
@@ -123,7 +123,7 @@ public:
return top_left;
}
- T getBottomRight() const
+ T getBottomRight() const
{
return bottom_right;
}
@@ -173,7 +173,7 @@ public:
// RV: Type of the value on the X axis
// RV2: Type of the maximum value on the Y axis
template
- RT multiply (RV x, RV2 y_max) const
+ RT multiply(RV x, RV2 y_max) const
{
const double val = x;
@@ -294,8 +294,7 @@ struct ToneCurveParams {
/**
* Parameters of Retinex
*/
-struct RetinexParams
-{
+struct RetinexParams {
bool enabled;
std::vector cdcurve;
std::vector cdHcurve;
@@ -341,8 +340,7 @@ struct RetinexParams
/**
* Parameters of the luminance curve
*/
-struct LCurveParams
-{
+struct LCurveParams {
bool enabled;
std::vector lcurve;
std::vector acurve;
@@ -369,7 +367,7 @@ struct LCurveParams
/**
* Parameters for local contrast
- */
+ */
struct LocalContrastParams {
bool enabled;
int radius;
@@ -1013,22 +1011,22 @@ struct ResizeParams {
* Parameters of the color spaces used during the processing
*/
struct ColorManagementParams {
- Glib::ustring input;
- bool toneCurve;
- bool applyLookTable;
- bool applyBaselineExposureOffset;
- bool applyHueSatMap;
+ Glib::ustring inputProfile;
+ bool toneCurve;
+ bool applyLookTable;
+ bool applyBaselineExposureOffset;
+ bool applyHueSatMap;
int dcpIlluminant;
- Glib::ustring working;
- Glib::ustring output;
+
+ Glib::ustring workingProfile;
+ Glib::ustring workingTRC;
+ double workingTRCGamma;
+ double workingTRCSlope;
+
+ Glib::ustring outputProfile;
RenderingIntent outputIntent;
bool outputBPC;
- Glib::ustring gamma;
- double gampos;
- double slpos;
- bool freegamma;
-
static const Glib::ustring NoICMString;
ColorManagementParams();
@@ -1347,7 +1345,7 @@ struct RAWParams {
static const std::vector& getMethodStrings();
static Glib::ustring getMethodString(Method method);
- };
+ };
BayerSensor bayersensor; ///< RAW parameters for Bayer sensors
XTransSensor xtranssensor; ///< RAW parameters for X-Trans sensors
@@ -1476,7 +1474,7 @@ public:
/** Creates a new instance of ProcParams.
* @return a pointer to the new ProcParams instance. */
- static ProcParams* create ();
+ static ProcParams* create();
/** Destroys an instance of ProcParams.
* @param pp a pointer to the ProcParams instance to destroy. */
diff --git a/rtengine/rawimagesource.cc b/rtengine/rawimagesource.cc
index 77cb6a522..7204862b0 100644
--- a/rtengine/rawimagesource.cc
+++ b/rtengine/rawimagesource.cc
@@ -911,16 +911,16 @@ DCPProfile *RawImageSource::getDCP(const ColorManagementParams &cmp, DCPProfile:
{
DCPProfile *dcpProf = nullptr;
cmsHPROFILE dummy;
- findInputProfile(cmp.input, nullptr, (static_cast(getMetaData()))->getCamera(), &dcpProf, dummy);
+ findInputProfile(cmp.inputProfile, nullptr, (static_cast(getMetaData()))->getCamera(), &dcpProf, dummy);
if (dcpProf == nullptr) {
if (settings->verbose) {
- printf("Can't load DCP profile '%s'!\n", cmp.input.c_str());
+ printf("Can't load DCP profile '%s'!\n", cmp.inputProfile.c_str());
}
return nullptr;
}
- dcpProf->setStep2ApplyState(cmp.working, cmp.toneCurve, cmp.applyLookTable, cmp.applyBaselineExposureOffset, as);
+ dcpProf->setStep2ApplyState(cmp.workingProfile, cmp.toneCurve, cmp.applyLookTable, cmp.applyBaselineExposureOffset, as);
return dcpProf;
}
@@ -2182,7 +2182,7 @@ void RawImageSource::retinexPrepareBuffers(const ColorManagementParams& cmp, con
int mode = 0;
Color::calcGamma(pwr, ts, mode, g_a); // call to calcGamma with selected gamma and slope
- // printf("g_a0=%f g_a1=%f g_a2=%f g_a3=%f g_a4=%f\n", g_a0,g_a1,g_a2,g_a3,g_a4);
+ // printf("g_a0=%f g_a1=%f g_a2=%f g_a3=%f g_a4=%f\n", g_a0,g_a1,g_a2,g_a3,g_a4);
double start;
double add;
@@ -2344,7 +2344,7 @@ void RawImageSource::retinexPrepareBuffers(const ColorManagementParams& cmp, con
}
} else {
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (cmp.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (cmp.workingProfile);
const float wp[3][3] = {
{static_cast(wprof[0][0]), static_cast(wprof[0][1]), static_cast(wprof[0][2])},
{static_cast(wprof[1][0]), static_cast(wprof[1][1]), static_cast(wprof[1][2])},
@@ -2621,7 +2621,7 @@ void RawImageSource::retinex(const ColorManagementParams& cmp, const RetinexPara
}
} else {
- TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.working);
+ TMatrix wiprof = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.workingProfile);
double wip[3][3] = {
{wiprof[0][0], wiprof[0][1], wiprof[0][2]},
@@ -3977,7 +3977,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
cmsHPROFILE in;
DCPProfile *dcpProf;
- if (!findInputProfile(cmp.input, embedded, camName, &dcpProf, in)) {
+ if (!findInputProfile(cmp.inputProfile, embedded, camName, &dcpProf, in)) {
return;
}
@@ -3994,7 +3994,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
{camMatrix[2][0], camMatrix[2][1], camMatrix[2][2]}
}
};
- dcpProf->apply(im, cmp.dcpIlluminant, cmp.working, wb, pre_mul_row, cam_matrix, cmp.applyHueSatMap);
+ dcpProf->apply(im, cmp.dcpIlluminant, cmp.workingProfile, wb, pre_mul_row, cam_matrix, cmp.applyHueSatMap);
return;
}
@@ -4003,7 +4003,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
// in this case we avoid using the slllllooooooowwww lcms
// Calculate matrix for direct conversion raw>working space
- TMatrix work = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.working);
+ TMatrix work = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.workingProfile);
double mat[3][3] = {{0, 0, 0}, {0, 0, 0}, {0, 0, 0}};
for (int i = 0; i < 3; i++)
@@ -4029,7 +4029,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
}
} else {
- bool working_space_is_prophoto = (cmp.working == "ProPhoto");
+ bool working_space_is_prophoto = (cmp.workingProfile == "ProPhoto");
// use supplied input profile
@@ -4101,7 +4101,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
// check if the working space is fully contained in prophoto
if (!working_space_is_prophoto && camera_icc_type == CAMERA_ICC_TYPE_GENERIC) {
- TMatrix toxyz = ICCStore::getInstance()->workingSpaceMatrix(cmp.working);
+ TMatrix toxyz = ICCStore::getInstance()->workingSpaceMatrix(cmp.workingProfile);
TMatrix torgb = ICCStore::getInstance()->workingSpaceInverseMatrix("ProPhoto");
float rgb[3] = {0.f, 0.f, 0.f};
for (int i = 0; i < 2 && !working_space_is_prophoto; ++i) {
@@ -4114,9 +4114,9 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
for (int j = 0; j < 2; ++j) {
if (rgb[j] < 0.f || rgb[j] > 1.f) {
working_space_is_prophoto = true;
- prophoto = ICCStore::getInstance()->workingSpace(cmp.working);
+ prophoto = ICCStore::getInstance()->workingSpace(cmp.workingProfile);
if (settings->verbose) {
- std::cout << "colorSpaceConversion_: converting directly to " << cmp.working << " instead of passing through ProPhoto" << std::endl;
+ std::cout << "colorSpaceConversion_: converting directly to " << cmp.workingProfile << " instead of passing through ProPhoto" << std::endl;
}
break;
}
@@ -4169,7 +4169,7 @@ void RawImageSource::colorSpaceConversion_ (Imagefloat* im, const ColorManagemen
if (!working_space_is_prophoto) {
toxyz = ICCStore::getInstance()->workingSpaceMatrix ("ProPhoto");
- torgb = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.working); //sRGB .. Adobe...Wide...
+ torgb = ICCStore::getInstance()->workingSpaceInverseMatrix (cmp.workingProfile); //sRGB .. Adobe...Wide...
}
#ifdef _OPENMP
diff --git a/rtengine/refreshmap.h b/rtengine/refreshmap.h
index 88092adfc..b9ccc2b65 100644
--- a/rtengine/refreshmap.h
+++ b/rtengine/refreshmap.h
@@ -66,7 +66,7 @@
#define DEFRINGE (M_LUMINANCE|M_COLOR)
#define DIRPYRDENOISE (M_LUMINANCE|M_COLOR)
#define DIRPYREQUALIZER (M_LUMINANCE|M_COLOR)
-#define GAMMA M_MONITOR
+#define GAMMA M_VOID //M_MONITOR
#define CROP M_CROP
#define RESIZE M_VOID
#define EXIF M_VOID
diff --git a/rtengine/rtthumbnail.cc b/rtengine/rtthumbnail.cc
index 9279e8829..c49112477 100644
--- a/rtengine/rtthumbnail.cc
+++ b/rtengine/rtthumbnail.cc
@@ -316,8 +316,8 @@ Image8 *load_inspector_mode(const Glib::ustring &fname, RawMetaDataLocation &rml
ProcParams neutral;
neutral.raw.bayersensor.method = RAWParams::BayerSensor::getMethodString(RAWParams::BayerSensor::Method::FAST);
neutral.raw.xtranssensor.method = RAWParams::XTransSensor::getMethodString(RAWParams::XTransSensor::Method::FAST);
- neutral.icm.input = "(camera)";
- neutral.icm.working = "RT_sRGB";
+ neutral.icm.inputProfile = "(camera)";
+ neutral.icm.workingProfile = options.rtSettings.srgb;
src.preprocess(neutral.raw, neutral.lensProf, neutral.coarse, false);
double thresholdDummy = 0.f;
@@ -1265,7 +1265,7 @@ IImage8* Thumbnail::processImage (const procparams::ProcParams& params, eSensorT
bool opautili = false;
if (params.colorToning.enabled) {
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.workingProfile);
double wp[3][3] = {
{wprof[0][0], wprof[0][1], wprof[0][2]},
{wprof[1][0], wprof[1][1], wprof[1][2]},
@@ -1317,10 +1317,10 @@ IImage8* Thumbnail::processImage (const procparams::ProcParams& params, eSensorT
if (isRaw) {
cmsHPROFILE dummy;
- RawImageSource::findInputProfile (params.icm.input, nullptr, camName, &dcpProf, dummy);
+ RawImageSource::findInputProfile (params.icm.inputProfile, nullptr, camName, &dcpProf, dummy);
if (dcpProf) {
- dcpProf->setStep2ApplyState (params.icm.working, params.icm.toneCurve, params.icm.applyLookTable, params.icm.applyBaselineExposureOffset, as);
+ dcpProf->setStep2ApplyState (params.icm.workingProfile, params.icm.toneCurve, params.icm.applyLookTable, params.icm.applyBaselineExposureOffset, as);
}
}
diff --git a/rtengine/settings.h b/rtengine/settings.h
index 639d3bf4a..65a469794 100644
--- a/rtengine/settings.h
+++ b/rtengine/settings.h
@@ -50,17 +50,17 @@ public:
bool verbose;
Glib::ustring darkFramesPath; ///< The default directory for dark frames
Glib::ustring flatFieldsPath; ///< The default directory for flat fields
- Glib::ustring adobe; // default name of AdobeRGB1998
- Glib::ustring prophoto; // default name of Prophoto
- Glib::ustring prophoto10; // default name of Prophoto
- Glib::ustring widegamut; //default name of WidegamutRGB
- Glib::ustring beta; // default name of BetaRGB
- Glib::ustring best; // default name of BestRGB
- Glib::ustring bruce; // default name of Bruce
- Glib::ustring srgb; // default name of SRGB space profile
- Glib::ustring srgb10; // default name of SRGB space profile
- Glib::ustring rec2020; // default name of rec2020
+ Glib::ustring adobe; // filename of AdobeRGB1998 profile (default to the bundled one)
+ Glib::ustring prophoto; // filename of Prophoto profile (default to the bundled one)
+ Glib::ustring widegamut; // filename of WidegamutRGB profile (default to the bundled one)
+ Glib::ustring beta; // filename of BetaRGB profile (default to the bundled one)
+ Glib::ustring best; // filename of BestRGB profile (default to the bundled one)
+ Glib::ustring bruce; // filename of BruceRGB profile (default to the bundled one)
+ Glib::ustring srgb; // filename of sRGB profile (default to the bundled one)
+ Glib::ustring rec2020; // filename of Rec2020 profile (default to the bundled one)
+ Glib::ustring ACESp0; // filename of ACES P0 profile (default to the bundled one)
+ Glib::ustring ACESp1; // filename of ACES P1 profile (default to the bundled one)
bool gamutICC; // no longer used
bool gamutLch;
@@ -89,13 +89,13 @@ public:
RAW_IF_NOT_JPEG_FULLSIZE
};
ThumbnailInspectorMode thumbnail_inspector_mode;
-
+
/** Creates a new instance of Settings.
* @return a pointer to the new Settings instance. */
- static Settings* create ();
+ static Settings* create();
/** Destroys an instance of Settings.
* @param s a pointer to the Settings instance to destroy. */
- static void destroy (Settings* s);
+ static void destroy(Settings* s);
};
}
diff --git a/rtengine/simpleprocess.cc b/rtengine/simpleprocess.cc
index d57264406..fbee20f44 100644
--- a/rtengine/simpleprocess.cc
+++ b/rtengine/simpleprocess.cc
@@ -375,21 +375,21 @@ private:
float multip = 1.f;
float adjustr = 1.f;
- if (params.icm.working == "ProPhoto") {
+ if (params.icm.workingProfile == "ProPhoto") {
adjustr = 1.f; //
- } else if (params.icm.working == "Adobe RGB") {
+ } else if (params.icm.workingProfile == "Adobe RGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "sRGB") {
+ } else if (params.icm.workingProfile == "sRGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "WideGamut") {
+ } else if (params.icm.workingProfile == "WideGamut") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Rec2020") {
+ } else if (params.icm.workingProfile == "Rec2020") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Beta RGB") {
+ } else if (params.icm.workingProfile == "Beta RGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BestRGB") {
+ } else if (params.icm.workingProfile == "BestRGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BruceRGB") {
+ } else if (params.icm.workingProfile == "BruceRGB") {
adjustr = 1.f / 1.2f;
}
@@ -618,21 +618,21 @@ private:
float MinRMoy = 0.f;
float MinBMoy = 0.f;
- if (params.icm.working == "ProPhoto") {
+ if (params.icm.workingProfile == "ProPhoto") {
adjustr = 1.f;
- } else if (params.icm.working == "Adobe RGB") {
+ } else if (params.icm.workingProfile == "Adobe RGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "sRGB") {
+ } else if (params.icm.workingProfile == "sRGB") {
adjustr = 1.f / 1.3f;
- } else if (params.icm.working == "WideGamut") {
+ } else if (params.icm.workingProfile == "WideGamut") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Rec2020") {
+ } else if (params.icm.workingProfile == "Rec2020") {
adjustr = 1.f / 1.1f;
- } else if (params.icm.working == "Beta RGB") {
+ } else if (params.icm.workingProfile == "Beta RGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BestRGB") {
+ } else if (params.icm.workingProfile == "BestRGB") {
adjustr = 1.f / 1.2f;
- } else if (params.icm.working == "BruceRGB") {
+ } else if (params.icm.workingProfile == "BruceRGB") {
adjustr = 1.f / 1.2f;
}
@@ -885,9 +885,49 @@ private:
const int W = baseImg->getWidth();
const int H = baseImg->getHeight();
LabImage labcbdl (W, H);
- ipf.rgb2lab (*baseImg, labcbdl, params.icm.working);
+ ipf.rgb2lab (*baseImg, labcbdl, params.icm.workingProfile);
ipf.dirpyrequalizer (&labcbdl, 1);
- ipf.lab2rgb (labcbdl, *baseImg, params.icm.working);
+ ipf.lab2rgb (labcbdl, *baseImg, params.icm.workingProfile);
+ }
+
+ //gamma TRC working
+ if (params.icm.workingTRC == "Custom") { //exec TRC IN free
+ Glib::ustring profile;
+ profile = params.icm.workingProfile;
+
+ if (profile == "sRGB" || profile == "Adobe RGB" || profile == "ProPhoto" || profile == "WideGamut" || profile == "BruceRGB" || profile == "Beta RGB" || profile == "BestRGB" || profile == "Rec2020" || profile == "ACESp0" || profile == "ACESp1") {
+ int cw = baseImg->getWidth();
+ int ch = baseImg->getHeight();
+ // put gamma TRC to 1
+ Imagefloat* readyImg0 = NULL;
+ readyImg0 = ipf.workingtrc(baseImg, cw, ch, -5, params.icm.workingProfile, 2.4, 12.92310);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ baseImg->r(row, col) = (float)readyImg0->r(row, col);
+ baseImg->g(row, col) = (float)readyImg0->g(row, col);
+ baseImg->b(row, col) = (float)readyImg0->b(row, col);
+ }
+ }
+
+ delete readyImg0;
+
+ //adjust TRC
+ Imagefloat* readyImg = NULL;
+ readyImg = ipf.workingtrc(baseImg, cw, ch, 5, params.icm.workingProfile, params.icm.workingTRCGamma, params.icm.workingTRCSlope);
+ #pragma omp parallel for
+
+ for (int row = 0; row < ch; row++) {
+ for (int col = 0; col < cw; col++) {
+ baseImg->r(row, col) = (float)readyImg->r(row, col);
+ baseImg->g(row, col) = (float)readyImg->g(row, col);
+ baseImg->b(row, col) = (float)readyImg->b(row, col);
+ }
+ }
+
+ delete readyImg;
+ }
}
// RGB processing
@@ -914,7 +954,7 @@ private:
bool opautili = false;
if (params.colorToning.enabled) {
- TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.working);
+ TMatrix wprof = ICCStore::getInstance()->workingSpaceMatrix (params.icm.workingProfile);
double wp[3][3] = {
{wprof[0][0], wprof[0][1], wprof[0][2]},
{wprof[1][0], wprof[1][1], wprof[1][2]},
@@ -1220,29 +1260,16 @@ private:
bool useLCMS = false;
bool bwonly = params.blackwhite.enabled && !params.colorToning.enabled && !autili && !butili ;
- if (params.icm.gamma != "default" || params.icm.freegamma) { // if select gamma output between BT709, sRGB, linear, low, high, 2.2 , 1.8
+ ///////////// Custom output gamma has been removed, the user now has to create
+ ///////////// a new output profile with the ICCProfileCreator
- GammaValues ga;
- // if(params.blackwhite.enabled) params.toneCurve.hrenabled=false;
- readyImg = ipf.lab2rgbOut (labView, cx, cy, cw, ch, params.icm, &ga);
- customGamma = true;
+ // if Default gamma mode: we use the profile selected in the "Output profile" combobox;
+ // gamma come from the selected profile, otherwise it comes from "Free gamma" tool
- //or selected Free gamma
- useLCMS = false;
+ readyImg = ipf.lab2rgbOut (labView, cx, cy, cw, ch, params.icm);
- if ((jprof = ICCStore::getInstance()->createCustomGammaOutputProfile (params.icm, ga)) == nullptr) {
- useLCMS = true;
- }
-
- } else {
- // if Default gamma mode: we use the profile selected in the "Output profile" combobox;
- // gamma come from the selected profile, otherwise it comes from "Free gamma" tool
-
- readyImg = ipf.lab2rgbOut (labView, cx, cy, cw, ch, params.icm);
-
- if (settings->verbose) {
- printf ("Output profile_: \"%s\"\n", params.icm.output.c_str());
- }
+ if (settings->verbose) {
+ printf ("Output profile_: \"%s\"\n", params.icm.outputProfile.c_str());
}
delete labView;
@@ -1301,21 +1328,21 @@ private:
} else {
// use the selected output profile if present, otherwise use LCMS2 profile generate by lab2rgb16 w/ gamma
- if (params.icm.output != "" && params.icm.output != ColorManagementParams::NoICMString) {
+ if (params.icm.outputProfile != "" && params.icm.outputProfile != ColorManagementParams::NoICMString) {
// if ICCStore::getInstance()->getProfile send back an object, then ICCStore::getInstance()->getContent will do too
- cmsHPROFILE jprof = ICCStore::getInstance()->getProfile (params.icm.output); //get outProfile
+ cmsHPROFILE jprof = ICCStore::getInstance()->getProfile (params.icm.outputProfile); //get outProfile
if (jprof == nullptr) {
if (settings->verbose) {
- printf ("\"%s\" ICC output profile not found!\n - use LCMS2 substitution\n", params.icm.output.c_str());
+ printf ("\"%s\" ICC output profile not found!\n - use LCMS2 substitution\n", params.icm.outputProfile.c_str());
}
} else {
if (settings->verbose) {
- printf ("Using \"%s\" output profile\n", params.icm.output.c_str());
+ printf ("Using \"%s\" output profile\n", params.icm.outputProfile.c_str());
}
- ProfileContent pc = ICCStore::getInstance()->getContent (params.icm.output);
+ ProfileContent pc = ICCStore::getInstance()->getContent (params.icm.outputProfile);
readyImg->setOutputProfile (pc.getData().c_str(), pc.getData().size());
}
} else {
@@ -1362,7 +1389,7 @@ private:
double scale_factor = ipf.resizeScale (¶ms, fw, fh, imw, imh);
std::unique_ptr tmplab (new LabImage (fw, fh));
- ipf.rgb2lab (*baseImg, *tmplab, params.icm.working);
+ ipf.rgb2lab (*baseImg, *tmplab, params.icm.workingProfile);
if (params.crop.enabled) {
int cx = params.crop.x;
@@ -1399,7 +1426,7 @@ private:
delete baseImg;
baseImg = new Imagefloat (fw, fh);
- ipf.lab2rgb (*tmplab, *baseImg, params.icm.working);
+ ipf.lab2rgb (*tmplab, *baseImg, params.icm.workingProfile);
}
void adjust_procparams (double scale_factor)
diff --git a/rtengine/stdimagesource.cc b/rtengine/stdimagesource.cc
index 7fa55cfb7..c75995b25 100644
--- a/rtengine/stdimagesource.cc
+++ b/rtengine/stdimagesource.cc
@@ -220,9 +220,9 @@ void StdImageSource::colorSpaceConversion (Imagefloat* im, const ColorManagement
bool skipTransform = false;
cmsHPROFILE in = nullptr;
- cmsHPROFILE out = ICCStore::getInstance()->workingSpace (cmp.working);
+ cmsHPROFILE out = ICCStore::getInstance()->workingSpace (cmp.workingProfile);
- if (cmp.input == "(embedded)" || cmp.input == "" || cmp.input == "(camera)" || cmp.input == "(cameraICC)") {
+ if (cmp.inputProfile == "(embedded)" || cmp.inputProfile == "" || cmp.inputProfile == "(camera)" || cmp.inputProfile == "(cameraICC)") {
if (embedded) {
in = embedded;
} else {
@@ -233,8 +233,8 @@ void StdImageSource::colorSpaceConversion (Imagefloat* im, const ColorManagement
}
}
} else {
- if (cmp.input != "(none)") {
- in = ICCStore::getInstance()->getProfile (cmp.input);
+ if (cmp.inputProfile != "(none)") {
+ in = ICCStore::getInstance()->getProfile (cmp.inputProfile);
if (in == nullptr && embedded) {
in = embedded;
@@ -270,7 +270,7 @@ void StdImageSource::colorSpaceConversion (Imagefloat* im, const ColorManagement
cmsDeleteTransform(hTransform);
} else {
- printf("Could not convert from %s to %s\n", in == embedded ? "embedded profile" : cmp.input.data(), cmp.working.data());
+ printf("Could not convert from %s to %s\n", in == embedded ? "embedded profile" : cmp.inputProfile.data(), cmp.workingProfile.data());
}
}
}
diff --git a/rtengine/tmo_fattal02.cc b/rtengine/tmo_fattal02.cc
index c6faef2e7..359b33575 100644
--- a/rtengine/tmo_fattal02.cc
+++ b/rtengine/tmo_fattal02.cc
@@ -1092,7 +1092,7 @@ void ImProcFunctions::ToneMapFattal02 (Imagefloat *rgb)
constexpr float luminance_noise_floor = 65.535f;
constexpr float min_luminance = 1.f;
- TMatrix ws = ICCStore::getInstance()->workingSpaceMatrix (params->icm.working);
+ TMatrix ws = ICCStore::getInstance()->workingSpaceMatrix (params->icm.workingProfile);
#ifdef _OPENMP
#pragma omp parallel for if(multiThread)
diff --git a/rtengine/utils.cc b/rtengine/utils.cc
index 4ab5bc1b8..613b67be8 100644
--- a/rtengine/utils.cc
+++ b/rtengine/utils.cc
@@ -265,3 +265,21 @@ void swab(const void* from, void* to, ssize_t n)
}
}
+
+#if __SIZEOF_WCHAR_T__ == 4
+Glib::ustring utf32_to_utf8(wchar_t* UTF32Buffer, size_t sizeOfUTF32Buffer)
+{
+ char *buffer2 = new char[sizeOfUTF32Buffer];
+ char *pBuffer2 = buffer2;
+ gchar a[6];
+ for (size_t i=0; i < sizeOfUTF32Buffer/4; ++i) {
+ gint bytesWritten = g_unichar_to_utf8((gunichar)UTF32Buffer[i], a);
+ for (gint j=0; j < bytesWritten; ++j) {
+ *(pBuffer2++) = a[j];
+ }
+ }
+ Glib::ustring modelDesc(buffer2);
+ delete [] buffer2;
+ return modelDesc;
+}
+#endif
diff --git a/rtengine/utils.h b/rtengine/utils.h
index 5730c2544..14593edae 100644
--- a/rtengine/utils.h
+++ b/rtengine/utils.h
@@ -55,3 +55,8 @@ bool hasPngExtension(const Glib::ustring& filename);
void swab(const void* from, void* to, ssize_t n);
}
+
+#if __SIZEOF_WCHAR_T__ == 4
+Glib::ustring utf32_to_utf8(wchar_t* UTF32Buffer, size_t sizeOfUTF32Buffer);
+#endif
+
diff --git a/rtgui/CMakeLists.txt b/rtgui/CMakeLists.txt
index f2167c654..b1c05d3b5 100644
--- a/rtgui/CMakeLists.txt
+++ b/rtgui/CMakeLists.txt
@@ -71,6 +71,7 @@ set(NONCLISOURCEFILES
histogrampanel.cc
history.cc
hsvequalizer.cc
+ iccprofilecreator.cc
icmpanel.cc
ilabel.cc
imagearea.cc
diff --git a/rtgui/addsetids.h b/rtgui/addsetids.h
index 95da5f900..8cf39aa29 100644
--- a/rtgui/addsetids.h
+++ b/rtgui/addsetids.h
@@ -50,8 +50,6 @@ enum {
ADDSET_SHARPENMICRO_UNIFORMITY,
ADDSET_VIBRANCE_PASTELS,
ADDSET_VIBRANCE_SATURATED,
- ADDSET_FREE_OUPUT_GAMMA,
- ADDSET_FREE_OUTPUT_SLOPE,
ADDSET_CAT_DEGREE,
ADDSET_CAT_ADAPTSCENE,
ADDSET_CAT_ADAPTVIEWING,
diff --git a/rtgui/batchtoolpanelcoord.cc b/rtgui/batchtoolpanelcoord.cc
index cbbff4060..b31f41e4f 100644
--- a/rtgui/batchtoolpanelcoord.cc
+++ b/rtgui/batchtoolpanelcoord.cc
@@ -150,7 +150,6 @@ void BatchToolPanelCoordinator::initSession ()
prsharpening->setAdjusterBehavior (false, false, false, false, false, false, false);
sharpenEdge->setAdjusterBehavior (false, false);
sharpenMicro->setAdjusterBehavior (false, false, false);
- icm->setAdjusterBehavior (false, false);
epd->setAdjusterBehavior (false, false, false, false, false);
fattal->setAdjusterBehavior (false, false, false);
@@ -199,7 +198,6 @@ void BatchToolPanelCoordinator::initSession ()
sharpenEdge->setAdjusterBehavior (options.baBehav[ADDSET_SHARPENEDGE_AMOUNT], options.baBehav[ADDSET_SHARPENEDGE_PASS]);
sharpenMicro->setAdjusterBehavior (options.baBehav[ADDSET_SHARPENMICRO_AMOUNT], options.baBehav[ADDSET_SHARPENMICRO_CONTRAST], options.baBehav[ADDSET_SHARPENMICRO_UNIFORMITY]);
- icm->setAdjusterBehavior (options.baBehav[ADDSET_FREE_OUPUT_GAMMA], options.baBehav[ADDSET_FREE_OUTPUT_SLOPE]);
// colortoning->setAdjusterBehavior (options.baBehav[ADDSET_COLORTONING_SPLIT], options.baBehav[ADDSET_COLORTONING_SATTHRESHOLD], options.baBehav[ADDSET_COLORTONING_SATOPACITY], options.baBehav[ADDSET_COLORTONING_STRPROTECT], options.baBehav[ADDSET_COLORTONING_BALANCE]);
colortoning->setAdjusterBehavior (options.baBehav[ADDSET_COLORTONING_SPLIT], options.baBehav[ADDSET_COLORTONING_SATTHRESHOLD], options.baBehav[ADDSET_COLORTONING_SATOPACITY], options.baBehav[ADDSET_COLORTONING_STRENGTH], options.baBehav[ADDSET_COLORTONING_BALANCE]);
filmSimulation->setAdjusterBehavior(options.baBehav[ADDSET_FILMSIMULATION_STRENGTH]);
@@ -279,8 +277,6 @@ void BatchToolPanelCoordinator::initSession ()
if (options.baBehav[ADDSET_CAT_CONTRAST]) { pparams.colorappearance.contrast = 0; }
if (options.baBehav[ADDSET_CAT_CONTRAST_Q]) { pparams.colorappearance.qcontrast = 0; }
if (options.baBehav[ADDSET_CAT_HUE]) { pparams.colorappearance.colorh = 0; }
- if (options.baBehav[ADDSET_FREE_OUPUT_GAMMA]) { pparams.icm.gampos = 0; }
- if (options.baBehav[ADDSET_FREE_OUTPUT_SLOPE]) { pparams.icm.slpos = 0; }
//if (options.baBehav[ADDSET_CBOOST_AMOUNT]) pparams.colorBoost.amount = 0;
//if (options.baBehav[ADDSET_CS_BLUEYELLOW]) pparams.colorShift.a = 0;
//if (options.baBehav[ADDSET_CS_GREENMAGENTA]) pparams.colorShift.b = 0;
diff --git a/rtgui/cropwindow.cc b/rtgui/cropwindow.cc
index 21b6d237c..255f666db 100644
--- a/rtgui/cropwindow.cc
+++ b/rtgui/cropwindow.cc
@@ -362,7 +362,7 @@ void CropWindow::buttonPress (int button, int type, int bstate, int x, int y)
// Add a new Color Picker
rtengine::Coord imgPos;
screenCoordToImage(x, y, imgPos.x, imgPos.y);
- LockableColorPicker *newPicker = new LockableColorPicker(this, &cropHandler.colorParams.output, &cropHandler.colorParams.working);
+ LockableColorPicker *newPicker = new LockableColorPicker(this, &cropHandler.colorParams.outputProfile, &cropHandler.colorParams.workingProfile);
colorPickers.push_back(newPicker);
hoveredPicker = newPicker;
updateHoveredPicker(&imgPos);
@@ -1014,12 +1014,12 @@ void CropWindow::pointerMoved (int bstate, int x, int y)
/* Glib::ustring outputProfile;
outputProfile =cropHandler.colorParams.output ;
printf("Using \"%s\" output\n", outputProfile.c_str());
- if(outputProfile=="RT_sRGB") printf("OK SRGB2");
+ if(outputProfile==options.rtSettings.srgb) printf("OK SRGB2");
*/
- pmlistener->pointerMoved (false, cropHandler.colorParams.output, cropHandler.colorParams.working, mx, my, -1, -1, -1);
+ pmlistener->pointerMoved (false, cropHandler.colorParams.outputProfile, cropHandler.colorParams.workingProfile, mx, my, -1, -1, -1);
if (pmhlistener) {
- pmhlistener->pointerMoved (false, cropHandler.colorParams.output, cropHandler.colorParams.working, mx, my, -1, -1, -1);
+ pmhlistener->pointerMoved (false, cropHandler.colorParams.outputProfile, cropHandler.colorParams.workingProfile, mx, my, -1, -1, -1);
}
} else {
@@ -1063,12 +1063,12 @@ void CropWindow::pointerMoved (int bstate, int x, int y)
}
}
// pmlistener->pointerMoved (true, cropHandler.colorParams.working, mx, my, pix[0], pix[1], pix[2]);
- pmlistener->pointerMoved (true, cropHandler.colorParams.output, cropHandler.colorParams.working, mx, my, rval, gval, bval);
+ pmlistener->pointerMoved (true, cropHandler.colorParams.outputProfile, cropHandler.colorParams.workingProfile, mx, my, rval, gval, bval);
if (pmhlistener)
// pmhlistener->pointerMoved (true, cropHandler.colorParams.working, mx, my, pix[0], pix[1], pix[2]);
{
- pmhlistener->pointerMoved (true, cropHandler.colorParams.output, cropHandler.colorParams.working, mx, my, pix[0], pix[1], pix[2]);
+ pmhlistener->pointerMoved (true, cropHandler.colorParams.outputProfile, cropHandler.colorParams.workingProfile, mx, my, pix[0], pix[1], pix[2]);
}
}
diff --git a/rtgui/editorpanel.cc b/rtgui/editorpanel.cc
index 969352902..69012745b 100644
--- a/rtgui/editorpanel.cc
+++ b/rtgui/editorpanel.cc
@@ -272,7 +272,7 @@ private:
}
#else
- profile = "RT_sRGB";
+ profile = options.rtSettings.srgb;
#endif
#if !defined(__APPLE__) // monitor profile not supported on apple
diff --git a/rtgui/exportpanel.h b/rtgui/exportpanel.h
index 0bea30d22..369682169 100644
--- a/rtgui/exportpanel.h
+++ b/rtgui/exportpanel.h
@@ -51,7 +51,7 @@ protected:
/* icm_input = "(camera)";
icm_working = "sRGB";
- icm_output = "RT_sRGB";
+ icm_output = options.rtSettings.srgb;
icm_gamma = "default";
*/
Gtk::CheckButton* bypass_dirpyrequalizer; // also could leave untouched but disable only small radius adjustments
diff --git a/rtgui/filecatalog.cc b/rtgui/filecatalog.cc
index 3b9b2a673..58184aa1c 100644
--- a/rtgui/filecatalog.cc
+++ b/rtgui/filecatalog.cc
@@ -1211,12 +1211,11 @@ void FileCatalog::developRequested (std::vector tbe, bool fas
params.raw.bayersensor.method = options.fastexport_raw_bayer_method;
params.raw.xtranssensor.method = options.fastexport_raw_xtrans_method;
- params.icm.input = options.fastexport_icm_input;
- params.icm.working = options.fastexport_icm_working;
- params.icm.output = options.fastexport_icm_output;
+ params.icm.inputProfile = options.fastexport_icm_input_profile;
+ params.icm.workingProfile = options.fastexport_icm_working_profile;
+ params.icm.outputProfile = options.fastexport_icm_output_profile;
params.icm.outputIntent = options.fastexport_icm_outputIntent;
params.icm.outputBPC = options.fastexport_icm_outputBPC;
- params.icm.gamma = options.fastexport_icm_gamma;
}
if (params.resize.enabled) {
diff --git a/rtgui/iccprofilecreator.cc b/rtgui/iccprofilecreator.cc
new file mode 100644
index 000000000..a430fba30
--- /dev/null
+++ b/rtgui/iccprofilecreator.cc
@@ -0,0 +1,1033 @@
+/*
+ * This file is part of RawTherapee.
+ *
+ * Copyright (c) 2018 Jacques DESMIS
+ * Copyright (c) 2018 Jean-Christophe FRISCH
+ *
+ * RawTherapee is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * RawTherapee is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with RawTherapee. If not, see .
+ */
+#include
+#include "iccprofilecreator.h"
+#include "multilangmgr.h"
+#include "cachemanager.h"
+#include "addsetids.h"
+#include "../rtengine/icons.h"
+#include "../rtengine/color.h"
+#include "rtimage.h"
+#ifdef _OPENMP
+#include
+#endif
+
+extern Options options;
+
+namespace rtengine
+{
+
+extern const Settings* settings;
+
+}
+
+const char* sTRCPreset[] = {"BT709_g2.2_s4.5", "sRGB_g2.4_s12.92", "linear_g1.0", "standard_g2.2", "standard_g1.8", "High_g1.3_s3.35", "Low_g2.6_s6.9", "Lab_g3.0s9.03296"}; //gamma free
+
+ICCProfileCreator::ICCProfileCreator(RTWindow *rtwindow)
+ : Gtk::Dialog (M ("MAIN_BUTTON_ICCPROFCREATOR"), *rtwindow, true)
+ , primariesPreset(options.ICCPC_primariesPreset)
+ , redPrimaryX(options.ICCPC_redPrimaryX)
+ , redPrimaryY(options.ICCPC_redPrimaryY)
+ , greenPrimaryX(options.ICCPC_greenPrimaryX)
+ , greenPrimaryY(options.ICCPC_greenPrimaryY)
+ , bluePrimaryX(options.ICCPC_bluePrimaryX)
+ , bluePrimaryY(options.ICCPC_bluePrimaryY)
+ , gammaPreset(options.ICCPC_gammaPreset)
+ , gamma(options.ICCPC_gamma)
+ , slope(options.ICCPC_slope)
+ , appendParamsToDesc(options.ICCPC_appendParamsToDesc)
+ , profileVersion(options.ICCPC_profileVersion)
+ , illuminant(options.ICCPC_illuminant)
+ , description(options.ICCPC_description)
+ , copyright(options.ICCPC_copyright)
+ , parent(rtwindow)
+{
+
+ set_default_size(600, -1);
+
+ Gtk::Grid* mainGrid = Gtk::manage(new Gtk::Grid());
+ mainGrid->set_column_spacing(3);
+ mainGrid->set_row_spacing(3);
+
+ //--------------------------------- primaries
+
+ Gtk::Label* prilab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_PRIMARIES")));
+ setExpandAlignProperties(prilab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*prilab, 0, 0, 1, 1);
+
+ primaries = Gtk::manage(new MyComboBoxText());
+ setExpandAlignProperties(primaries, false, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+ primaries->append(M("ICCPROFCREATOR_CUSTOM"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_ACESP0"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_ACESP1"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_ADOBE"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_PROPH"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_REC2020"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_SRGB"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_WIDEG"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_BEST"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_BETA"));
+ primaries->append(M("ICCPROFCREATOR_PRIM_BRUCE"));
+ primaries->set_tooltip_text(M("ICCPROFCREATOR_PRIM_TOOLTIP"));
+ mainGrid->attach(*primaries, 1, 0, 1, 1);
+
+ primariesGrid = Gtk::manage(new Gtk::Grid());
+ setExpandAlignProperties(primariesGrid, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ primariesGrid->set_column_spacing(5);
+
+ /*
+ Gtk::Image* gamuts0 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl0 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ Gtk::Image* gamuts1 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl1 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ Gtk::Image* gamuts2 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl2 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ Gtk::Image* gamuts3 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl3 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ Gtk::Image* gamuts4 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl4 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ Gtk::Image* gamuts5 = Gtk::manage(new RTImage("rt-logo-tiny.png"));
+ Gtk::Image* gamutl5 = Gtk::manage(new RTImage("rt-logo-small.png"));
+ */
+
+ aPrimariesRedX = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_REDX"), 0.6300, 0.7350, 0.0001, 0.6400/*, gamuts0, gamutl0*/));
+ setExpandAlignProperties(aPrimariesRedX, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ aPrimariesRedY = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_REDY"), 0.2650, 0.3350, 0.0001, 0.3300/*, gamutl1, gamuts1*/));
+ setExpandAlignProperties(aPrimariesRedY, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ aPrimariesGreenX = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_GREX"), 0.0000, 0.3100, 0.0001, 0.3000/*, gamutl2, gamuts2*/));
+ setExpandAlignProperties(aPrimariesGreenX, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ aPrimariesGreenY = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_GREY"), 0.5900, 1.0000, 0.0001, 0.6000/*, gamuts3, gamutl3*/));
+ setExpandAlignProperties(aPrimariesGreenY, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ aPrimariesBlueX = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_BLUX"), 0.0001, 0.1600, 0.0001, 0.1500/*, gamutl4, gamuts4*/));
+ setExpandAlignProperties(aPrimariesBlueX, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ aPrimariesBlueY = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_PRIM_BLUY"), -0.0700, 0.0700, 0.0001, 0.060/*, gamutl5, gamuts5*/));
+ setExpandAlignProperties(aPrimariesBlueY, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+
+ primariesGrid->attach(*aPrimariesRedX, 0, 0, 1, 1);
+ primariesGrid->attach(*aPrimariesRedY, 1, 0, 1, 1);
+
+ primariesGrid->attach(*aPrimariesGreenX, 0, 1, 1, 1);
+ primariesGrid->attach(*aPrimariesGreenY, 1, 1, 1, 1);
+
+ primariesGrid->attach(*aPrimariesBlueX, 0, 2, 1, 1);
+ primariesGrid->attach(*aPrimariesBlueY, 1, 2, 1, 1);
+
+ mainGrid->attach(*primariesGrid, 1, 1, 1, 1);
+
+ //--------------------------------- output gamma
+
+ Gtk::Label* galab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_TRC_PRESET")));
+ setExpandAlignProperties(galab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*galab, 0, 2, 1, 1);
+
+ trcPresets = Gtk::manage(new MyComboBoxText());
+ setExpandAlignProperties(trcPresets, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+ std::vector outputTRCPresets;
+ outputTRCPresets.push_back(M("ICCPROFCREATOR_CUSTOM"));
+ for (unsigned int i = 0; i < sizeof(sTRCPreset) / sizeof(sTRCPreset[0]); i++) {
+ outputTRCPresets.push_back(sTRCPreset[i]);
+ }
+ for (size_t i = 0; i < outputTRCPresets.size(); i++) {
+ trcPresets->append(outputTRCPresets[i]);
+ }
+ mainGrid->attach(*trcPresets, 1, 2, 1, 1);
+
+ //--------------------------------- sliders gampos and slpos
+
+ aGamma = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_GAMMA"), 1, 3.5, 0.01, 2.4));
+ setExpandAlignProperties(aGamma, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+
+ if (aGamma->delay < options.adjusterMaxDelay) {
+ aGamma->delay = options.adjusterMaxDelay;
+ }
+ aGamma->show();
+ mainGrid->attach(*aGamma, 1, 3, 1, 1); //gamma
+
+ aSlope = Gtk::manage(new Adjuster(M("ICCPROFCREATOR_SLOPE"), 0, 15, 0.00001, 12.92310));
+ setExpandAlignProperties(aSlope, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+
+ if (aSlope->delay < options.adjusterMaxDelay) {
+ aSlope->delay = options.adjusterMaxDelay;
+ }
+ aSlope->show();
+ mainGrid->attach(*aSlope, 1, 4, 1, 1); //slope
+
+ //--------------------------------- temperature
+
+ Gtk::Label* illlab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_ILL")));
+ setExpandAlignProperties(illlab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*illlab, 0, 5, 1, 1); //slope
+ cIlluminant = Gtk::manage(new MyComboBoxText());
+ setExpandAlignProperties(cIlluminant, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_DEF"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_41"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_50"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_55"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_60"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_65"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_80"));
+ cIlluminant->append(M("ICCPROFCREATOR_ILL_INC"));
+ cIlluminant->set_tooltip_text(M("ICCPROFCREATOR_ILL_TOOLTIP"));
+ mainGrid->attach(*cIlluminant, 1, 5, 1, 1);
+
+ //--------------------------------- V2 or V4 profiles
+
+ Gtk::Label* proflab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_ICCVERSION")));
+ setExpandAlignProperties(proflab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*proflab, 0, 6, 1, 1);
+ iccVersion = Gtk::manage(new MyComboBoxText());
+ setExpandAlignProperties(iccVersion, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_BASELINE);
+ iccVersion->append(M("ICCPROFCREATOR_PROF_V4"));
+ iccVersion->append(M("ICCPROFCREATOR_PROF_V2"));
+ mainGrid->attach(*iccVersion, 1, 6, 1, 1);
+
+ //--------------------------------- Description
+
+ Gtk::Label* desclab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_DESCRIPTION")));
+ setExpandAlignProperties(desclab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_START);
+ mainGrid->attach(*desclab, 0, 7, 1, 2);
+ eDescription = Gtk::manage(new Gtk::Entry());
+ setExpandAlignProperties(eDescription, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ eDescription->set_tooltip_text(M("ICCPROFCREATOR_DESCRIPTION_TOOLTIP"));
+ mainGrid->attach(*eDescription, 1, 7, 1, 1);
+ cAppendParamsToDesc = Gtk::manage(new Gtk::CheckButton(M("ICCPROFCREATOR_ADD_PARAM_IN_DESC")));
+ setExpandAlignProperties(cAppendParamsToDesc, true, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*cAppendParamsToDesc, 1, 8, 1, 1);
+
+ //--------------------------------- Copyright
+
+ Gtk::Label* copylab = Gtk::manage(new Gtk::Label(M("ICCPROFCREATOR_COPYRIGHT")));
+ setExpandAlignProperties(copylab, false, false, Gtk::ALIGN_START, Gtk::ALIGN_BASELINE);
+ mainGrid->attach(*copylab, 0, 9, 1, 1);
+ Gtk::Grid* copygrid = Gtk::manage(new Gtk::Grid());
+ setExpandAlignProperties(copygrid, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_START);
+ eCopyright = Gtk::manage(new Gtk::Entry());
+ setExpandAlignProperties(eCopyright, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
+ copygrid->attach(*eCopyright, 0, 0, 1, 1);
+ resetCopyright = Gtk::manage(new Gtk::Button());
+ resetCopyright->add (*Gtk::manage (new RTImage ("undo-small.png", "redo-small.png")));
+ setExpandAlignProperties(resetCopyright, false, false, Gtk::ALIGN_CENTER, Gtk::ALIGN_CENTER);
+ resetCopyright->set_relief (Gtk::RELIEF_NONE);
+ resetCopyright->set_tooltip_markup (M("ICCPROFCREATOR_COPYRIGHT_RESET_TOOLTIP"));
+ resetCopyright->get_style_context()->add_class(GTK_STYLE_CLASS_FLAT);
+ resetCopyright->set_can_focus(false);
+ copygrid->attach(*resetCopyright, 1, 0, 1, 1);
+ mainGrid->attach(*copygrid, 1, 9, 1, 1);
+
+ //--------------------------------- Adding the mainGrid
+
+ get_content_area()->add(*mainGrid);
+
+ //--------------------------------- Setting default values for Adjusters
+
+ aGamma->setDefault(gamma);
+ aSlope->setDefault(slope);
+ aPrimariesRedX->setDefault(redPrimaryX);
+ aPrimariesRedY->setDefault(redPrimaryY);
+ aPrimariesGreenX->setDefault(greenPrimaryX);
+ aPrimariesGreenY->setDefault(greenPrimaryY);
+ aPrimariesBlueX->setDefault(bluePrimaryX);
+ aPrimariesBlueY->setDefault(bluePrimaryY);
+
+ //--------------- Updating widgets with actual values (from options)
+
+ if (primariesPreset == "custom") {
+ primaries->set_active_text(M("ICCPROFCREATOR_CUSTOM"));
+ } else if (primariesPreset == "ACES-AP0") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_ACESP0"));
+ } else if (primariesPreset == "ACES-AP1") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_ACESP1"));
+ } else if (primariesPreset == "Adobe") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_ADOBE"));
+ } else if (primariesPreset == "ProPhoto") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_PROPH"));
+ } else if (primariesPreset == "Rec2020") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_REC2020"));
+ } else if (primariesPreset == "sRGB") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_SRGB"));
+ } else if (primariesPreset == "Widegamut") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_WIDEG"));
+ } else if (primariesPreset == "BestRGB") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_BEST"));
+ } else if (primariesPreset == "BetaRGB") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_BETA"));
+ } else if (primariesPreset == "BruceRGB") {
+ primaries->set_active_text(M("ICCPROFCREATOR_PRIM_BRUCE"));
+ }
+
+ trcPresets->set_active(0);
+ if (gammaPreset != "Custom") {
+ trcPresets->set_active_text(gammaPreset);
+ }
+
+ aGamma->setValue(gamma);
+ aSlope->setValue(slope);
+ aPrimariesRedX->setValue(redPrimaryX);
+ aPrimariesRedY->setValue(redPrimaryY);
+ aPrimariesGreenX->setValue(greenPrimaryX);
+ aPrimariesGreenY->setValue(greenPrimaryY);
+ aPrimariesBlueX->setValue(bluePrimaryX);
+ aPrimariesBlueY->setValue(bluePrimaryY);
+
+ eDescription->set_text(description);
+ eCopyright->set_text(copyright);
+ cAppendParamsToDesc->set_active(appendParamsToDesc);
+
+ if (illuminant == "DEF") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_DEF"));
+ } else if (illuminant == "D41") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_41"));
+ } else if (illuminant == "D50") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_50"));
+ } else if (illuminant == "D55") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_55"));
+ } else if (illuminant == "D60") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_60"));
+ } else if (illuminant == "D65") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_65"));
+ } else if (illuminant == "D80") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_80"));
+ } else if (illuminant == "stdA") {
+ cIlluminant->set_active_text(M("ICCPROFCREATOR_ILL_INC"));
+ }
+
+ iccVersion->set_active(0);
+ if (profileVersion == "v2") {
+ iccVersion->set_active(1);
+ }
+
+ trcPresetsChanged();
+ illuminantChanged();
+ primariesChanged();
+
+ //--------------- Action area button
+
+ Gtk::Button* save = Gtk::manage (new Gtk::Button (M ("GENERAL_SAVE_AS")));
+ save->signal_clicked().connect ( sigc::mem_fun (*this, &ICCProfileCreator::savePressed) );
+ get_action_area()->pack_start (*save);
+
+ Gtk::Button* close = Gtk::manage (new Gtk::Button (M ("GENERAL_CLOSE")));
+ close->signal_clicked().connect ( sigc::mem_fun (*this, &ICCProfileCreator::closePressed) );
+ get_action_area()->pack_start (*close);
+
+ //--------------- Show childrens
+
+ show_all_children ();
+
+ //--------------- Connecting the signals
+
+ aPrimariesRedX->setAdjusterListener(this);
+ aPrimariesRedY->setAdjusterListener(this);
+ aPrimariesGreenX->setAdjusterListener(this);
+ aPrimariesGreenY->setAdjusterListener(this);
+ aPrimariesBlueX->setAdjusterListener(this);
+ aPrimariesBlueY->setAdjusterListener(this);
+ aGamma->setAdjusterListener(this);
+ aSlope->setAdjusterListener(this);
+ primariesconn = primaries->signal_changed().connect(sigc::mem_fun(*this, &ICCProfileCreator::primariesChanged));
+ trcpresetsconn = trcPresets->signal_changed().connect(sigc::mem_fun(*this, &ICCProfileCreator::trcPresetsChanged));
+ illconn = cIlluminant->signal_changed().connect(sigc::mem_fun(*this, &ICCProfileCreator::illuminantChanged));
+ resetCopyright->signal_clicked().connect(sigc::mem_fun(*this, &ICCProfileCreator::onResetCopyright));
+}
+
+void ICCProfileCreator::closePressed()
+{
+ storeValues();
+ hide();
+}
+
+void ICCProfileCreator::updateICCVersion()
+{
+ if (cIlluminant->get_active_text() != M("ICCPROFCREATOR_ILL_DEF") || primaries->get_active_text() == M("ICCPROFCREATOR_CUSTOM")) {
+ iccVersion->set_active_text(M("ICCPROFCREATOR_PROF_V4"));
+ iccVersion->set_sensitive(false);
+ } else {
+ iccVersion->set_sensitive(true);
+ }
+}
+
+void ICCProfileCreator::adjusterChanged (Adjuster* a, double newval)
+{
+ if (a == aPrimariesRedX || a == aPrimariesRedY ||
+ a == aPrimariesGreenX || a == aPrimariesGreenY ||
+ a == aPrimariesBlueX || a == aPrimariesBlueY)
+ {
+ if (primaries->get_active_row_number() > 0) {
+ ConnectionBlocker blocker(primariesconn);
+ primaries->set_active(0);
+ updateICCVersion();
+ }
+ } else if (a == aGamma || a == aSlope) {
+ if (trcPresets->get_active_row_number() > 0) {
+ ConnectionBlocker blocker(trcpresetsconn);
+ trcPresets->set_active(0);
+ }
+ }
+}
+
+void ICCProfileCreator::primariesChanged()
+{
+ if (primaries->get_active_row_number() > 0) {
+ float p[6];
+ ColorTemp temp;
+ Glib::ustring activeValue = primaries->get_active_text();
+ Glib::ustring primPresetName = getPrimariesPresetName(activeValue);
+ getPrimaries(primPresetName, p, temp);
+ aPrimariesRedX->setValue(p[0]);
+ aPrimariesRedY->setValue(p[1]);
+ aPrimariesGreenX->setValue(p[2]);
+ aPrimariesGreenY->setValue(p[3]);
+ aPrimariesBlueX->setValue(p[4]);
+ aPrimariesBlueY->setValue(p[5]);
+ }
+ updateICCVersion();
+}
+
+void ICCProfileCreator::illuminantChanged()
+{
+ updateICCVersion();
+}
+
+void ICCProfileCreator::trcPresetsChanged()
+{
+ aGamma->block(true);
+ aSlope->block(true);
+
+ double gamma;
+ double slope;
+ getGamma(getGammaPresetName(trcPresets->get_active_text()), gamma, slope);
+ aGamma->setValue(gamma);
+ aSlope->setValue(slope);
+
+ aGamma->block(false);
+ aSlope->block(false);
+}
+
+void ICCProfileCreator::storeValues()
+{
+ if (iccVersion->get_active_text() == M("ICCPROFCREATOR_PROF_V4")) {
+ options.ICCPC_profileVersion = profileVersion = "v4";
+ } else if (iccVersion->get_active_text() == M("ICCPROFCREATOR_PROF_V2")) {
+ options.ICCPC_profileVersion = profileVersion = "v2";
+ }
+
+ if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_DEF")) {
+ options.ICCPC_illuminant = illuminant = "DEF";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_41")) {
+ options.ICCPC_illuminant = illuminant = "D41";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_50")) {
+ options.ICCPC_illuminant = illuminant = "D50";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_55")) {
+ options.ICCPC_illuminant = illuminant = "D55";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_60")) {
+ options.ICCPC_illuminant = illuminant = "D60";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_65")) {
+ options.ICCPC_illuminant = illuminant = "D65";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_80")) {
+ options.ICCPC_illuminant = illuminant = "D80";
+ } else if (cIlluminant->get_active_text() == M("ICCPROFCREATOR_ILL_INC")) {
+ options.ICCPC_illuminant = illuminant = "stdA";
+ }
+
+ options.ICCPC_primariesPreset = primariesPreset = getPrimariesPresetName(primaries->get_active_text());
+ options.ICCPC_gammaPreset = gammaPreset = getGammaPresetName(trcPresets->get_active_text());
+ options.ICCPC_gamma = gamma = aGamma->getValue();
+ options.ICCPC_slope = slope = aSlope->getValue();
+ options.ICCPC_redPrimaryX = redPrimaryX = aPrimariesRedX->getValue();
+ options.ICCPC_redPrimaryY = redPrimaryY = aPrimariesRedY->getValue();
+ options.ICCPC_greenPrimaryX = greenPrimaryX = aPrimariesGreenX->getValue();
+ options.ICCPC_greenPrimaryY = greenPrimaryY = aPrimariesGreenY->getValue();
+ options.ICCPC_bluePrimaryX = bluePrimaryX = aPrimariesBlueX->getValue();
+ options.ICCPC_bluePrimaryY = bluePrimaryY = aPrimariesBlueY->getValue();
+ options.ICCPC_description = description = eDescription->get_text();
+ options.ICCPC_copyright = copyright = eCopyright->get_text();
+ options.ICCPC_appendParamsToDesc = appendParamsToDesc = cAppendParamsToDesc->get_active();
+}
+
+Glib::ustring ICCProfileCreator::getPrimariesPresetName(const Glib::ustring &preset)
+{
+ if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_ACESP0")) {
+ return Glib::ustring("ACES-AP0");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_ACESP1")) {
+ return Glib::ustring("ACES-AP1");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_ADOBE")) {
+ return Glib::ustring("Adobe");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_PROPH")) {
+ return Glib::ustring("ProPhoto");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_REC2020")) {
+ return Glib::ustring("Rec2020");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_SRGB")) {
+ return Glib::ustring("sRGB");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_WIDEG")) {
+ return Glib::ustring("Widegamut");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_BEST")) {
+ return Glib::ustring("BestRGB");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_BETA")) {
+ return Glib::ustring("BetaRGB");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_PRIM_BRUCE")) {
+ return Glib::ustring("BruceRGB");
+ } else if (primaries->get_active_text() == M("ICCPROFCREATOR_CUSTOM")) {
+ return Glib::ustring("custom");
+ } else {
+ return Glib::ustring();
+ }
+}
+
+void ICCProfileCreator::getPrimaries(const Glib::ustring &preset, float *p, ColorTemp &temp)
+{
+ temp = ColorTemp::D50;
+ if (preset == "Widegamut") {
+ p[0] = 0.7350; //Widegamut primaries
+ p[1] = 0.2650;
+ p[2] = 0.1150;
+ p[3] = 0.8260;
+ p[4] = 0.1570;
+ p[5] = 0.0180;
+
+ } else if (preset == "Adobe") {
+ p[0] = 0.6400; //Adobe primaries
+ p[1] = 0.3300;
+ p[2] = 0.2100;
+ p[3] = 0.7100;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (preset == "sRGB") {
+ p[0] = 0.6400; // sRGB primaries
+ p[1] = 0.3300;
+ p[2] = 0.3000;
+ p[3] = 0.6000;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (preset == "BruceRGB") {
+ p[0] = 0.6400; // Bruce primaries
+ p[1] = 0.3300;
+ p[2] = 0.2800;
+ p[3] = 0.6500;
+ p[4] = 0.1500;
+ p[5] = 0.0600;
+ temp = ColorTemp::D65;
+ } else if (preset == "BetaRGB") {
+ p[0] = 0.6888; // Beta primaries
+ p[1] = 0.3112;
+ p[2] = 0.1986;
+ p[3] = 0.7551;
+ p[4] = 0.1265;
+ p[5] = 0.0352;
+ } else if (preset == "BestRGB") {
+ p[0] = 0.7347; // Best primaries
+ p[1] = 0.2653;
+ p[2] = 0.2150;
+ p[3] = 0.7750;
+ p[4] = 0.1300;
+ p[5] = 0.0350;
+ } else if (preset == "Rec2020") {
+ p[0] = 0.7080; // Rec2020 primaries
+ p[1] = 0.2920;
+ p[2] = 0.1700;
+ p[3] = 0.7970;
+ p[4] = 0.1310;
+ p[5] = 0.0460;
+ temp = ColorTemp::D65;
+ } else if (preset == "ACES-AP0") {
+ p[0] = 0.7347; // ACES P0 primaries
+ p[1] = 0.2653;
+ p[2] = 0.0000;
+ p[3] = 1.0;
+ p[4] = 0.0001;
+ p[5] = -0.0770;
+ temp = ColorTemp::D60;
+ } else if (preset == "ACES-AP1") {
+ p[0] = 0.713; // ACES P1 primaries
+ p[1] = 0.293;
+ p[2] = 0.165;
+ p[3] = 0.830;
+ p[4] = 0.128;
+ p[5] = 0.044;
+ temp = ColorTemp::D60;
+ } else if (preset == "ProPhoto") {
+ p[0] = 0.7347; // ProPhoto and default primaries
+ p[1] = 0.2653;
+ p[2] = 0.1596;
+ p[3] = 0.8404;
+ p[4] = 0.0366;
+ p[5] = 0.0001;
+ } else if (preset == "custom") {
+ p[0] = redPrimaryX;
+ p[1] = redPrimaryY;
+ p[2] = greenPrimaryX;
+ p[3] = greenPrimaryY;
+ p[4] = bluePrimaryX;
+ p[5] = bluePrimaryY;
+
+ } else {
+ p[0] = 0.7347; //default primaries
+ p[1] = 0.2653;
+ p[2] = 0.1596;
+ p[3] = 0.8404;
+ p[4] = 0.0366;
+ p[5] = 0.0001;
+ }
+}
+
+Glib::ustring ICCProfileCreator::getGammaPresetName(const Glib::ustring &preset)
+{
+ Glib::ustring name(trcPresets->get_active_text());
+ if (name == M("ICCPROFCREATOR_CUSTOM")) {
+ name = "Custom";
+ }
+ return name;
+}
+
+void ICCProfileCreator::getGamma(const Glib::ustring &preset, double &presetGamma, double &presetSlope)
+{
+ if (preset == "High_g1.3_s3.35") {
+ presetGamma = 1.3;
+ presetSlope = 3.35;
+ } else if (preset == "Low_g2.6_s6.9") {
+ presetGamma = 2.6;
+ presetSlope = 6.9;
+ } else if (preset == "sRGB_g2.4_s12.92") {
+ presetGamma = 2.4;
+ presetSlope = 12.92310;
+ } else if (preset == "BT709_g2.2_s4.5") {
+ presetGamma = 2.22;
+ presetSlope = 4.5;
+ } else if (preset == "linear_g1.0") {
+ presetGamma = 1.;
+ presetSlope = 0.;
+ } else if (preset == "standard_g2.2") {
+ presetGamma = 2.2;
+ presetSlope = 0.;
+ } else if (preset == "standard_g1.8") {
+ presetGamma = 1.8;
+ presetSlope = 0.;
+ } else if (preset == "Lab_g3.0s9.03296") {
+ presetGamma = 3.0;
+ presetSlope = 9.03296;
+ } else if (preset == "Custom") {
+ presetGamma = gamma;
+ presetSlope = slope;
+ } else {
+ presetGamma = 2.4;
+ presetSlope = 12.92310;
+ }
+}
+
+void ICCProfileCreator::onResetCopyright()
+{
+ eCopyright->set_text(Options::getICCProfileCopyright());
+}
+
+// Copyright (c) 2018 Jacques DESMIS
+// WARNING: the caller must lock lcmsMutex
+void ICCProfileCreator::savePressed()
+{
+ cmsHPROFILE newProfile = nullptr;
+ Glib::ustring sNewProfile;
+ Glib::ustring sPrimariesPreset;
+ Glib::ustring sGammaPreset;
+
+ storeValues();
+
+ // -------------------------------------------- Compute the default file name
+
+ //necessary for V2 profile
+ if (primariesPreset == "ACES-AP0" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.ACESp0)) {
+ sNewProfile = options.rtSettings.ACESp0;
+ sPrimariesPreset = "ACES-AP0";
+ } else if (primariesPreset == "ACES-AP1" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.ACESp1)) {
+ sNewProfile = options.rtSettings.ACESp1;
+ sPrimariesPreset = "ACES-AP1";
+ } else if (primariesPreset == "Adobe" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.adobe)) {
+ sNewProfile = options.rtSettings.adobe;
+ sPrimariesPreset = "Medium";
+ } else if (primariesPreset == "ProPhoto" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.prophoto)) {
+ sNewProfile = options.rtSettings.prophoto;
+ sPrimariesPreset = "Large";
+ } else if (primariesPreset == "Rec2020" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.rec2020)) {
+ sNewProfile = options.rtSettings.rec2020;
+ sPrimariesPreset = "Rec2020";
+ } else if (primariesPreset == "sRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.srgb)) {
+ sNewProfile = options.rtSettings.srgb;
+ sPrimariesPreset = "sRGB";
+ } else if (primariesPreset == "Widegamut" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.widegamut)) {
+ sNewProfile = options.rtSettings.widegamut;
+ sPrimariesPreset = "Wide";
+ } else if (primariesPreset == "BestRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.best)) {
+ sNewProfile = options.rtSettings.best;
+ sPrimariesPreset = "Best";
+ } else if (primariesPreset == "BetaRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.beta)) {
+ sNewProfile = options.rtSettings.beta;
+ sPrimariesPreset = "Beta";
+ } else if (primariesPreset == "BruceRGB" && rtengine::ICCStore::getInstance()->outputProfileExist(options.rtSettings.bruce)) {
+ sNewProfile = options.rtSettings.bruce;
+ sPrimariesPreset = "Bruce";
+ } else if (primariesPreset == "custom") {
+ sNewProfile = options.rtSettings.srgb;
+ sPrimariesPreset = "Custom";
+ } else {
+ // Should not occurs
+ if (rtengine::settings->verbose) {
+ printf("\"%s\": unknown working profile! - use LCMS2 substitution\n", primariesPreset.c_str());
+ }
+ return;
+ }
+
+ //begin adaptation rTRC gTRC bTRC
+ //"newProfile" profile has the same characteristics than RGB values, but TRC are adapted... for applying profile
+ if (rtengine::settings->verbose) {
+ printf("Output Gamma - profile Primaries as RT profile: \"%s\"\n", sNewProfile.c_str());
+ }
+
+ newProfile = rtengine::ICCStore::getInstance()->getProfile(sNewProfile); //get output profile
+
+ if (newProfile == nullptr) {
+
+ if (rtengine::settings->verbose) {
+ printf("\"%s\" ICC output profile not found!\n", sNewProfile.c_str());
+ }
+ return;
+ }
+
+ //change desc Tag , to "free gamma", or "BT709", etc.
+ Glib::ustring fName;
+ Glib::ustring sPrimariesAndIlluminant;
+ double presetGamma = 2.4;
+ double presetSlope = 12.92310;
+ const double eps = 0.000000001; // not divide by zero
+ getGamma(gammaPreset, presetGamma, presetSlope);
+ if (gammaPreset == "High_g1.3_s3.35") {
+ sGammaPreset = "High_g=1.3_s=3.35";
+ ga[0] = 1.3 ; //for high dynamic images
+ ga[1] = 0.998279;
+ ga[2] = 0.001721;
+ ga[3] = 0.298507;
+ ga[4] = 0.005746;
+ } else if (gammaPreset == "Low_g2.6_s6.9") {
+ sGammaPreset = "Low_g=2.6_s=6.9";
+ ga[0] = 2.6 ; //gamma 2.6 variable : for low contrast images
+ ga[1] = 0.891161;
+ ga[2] = 0.108839;
+ ga[3] = 0.144928;
+ ga[4] = 0.076332;
+ } else if (gammaPreset == "sRGB_g2.4_s12.92") {
+ sGammaPreset = "sRGB_g=2.4_s=12.92310";
+ ga[0] = 2.40; //sRGB 2.4 12.92 - RT default as Lightroom
+ ga[1] = 0.947858;
+ ga[2] = 0.052142;
+ ga[3] = 0.077399;
+ ga[4] = 0.039293;
+ } else if (gammaPreset == "BT709_g2.2_s4.5") {
+ sGammaPreset = "BT709_g=2.2_s=4.5";
+ ga[0] = 2.22; //BT709 2.2 4.5 - my preferred as D.Coffin
+ ga[1] = 0.909995;
+ ga[2] = 0.090005;
+ ga[3] = 0.222222;
+ ga[4] = 0.081071;
+ } else if (gammaPreset == "linear_g1.0") {
+ sGammaPreset = "Linear_g=1.0";
+ ga[0] = 1.0; //gamma=1 linear : for high dynamic images (cf D.Coffin...)
+ ga[1] = 1.;
+ ga[2] = 0.;
+ ga[3] = 1. / eps;
+ ga[4] = 0.;
+ } else if (gammaPreset == "standard_g2.2") {
+ sGammaPreset = "g=2.2";
+ ga[0] = 2.2; //gamma=2.2(as gamma of Adobe, Widegamut...)
+ ga[1] = 1.;
+ ga[2] = 0.;
+ ga[3] = 1. / eps;
+ ga[4] = 0.;
+ } else if (gammaPreset == "standard_g1.8") {
+ sGammaPreset = "g=1.8";
+ ga[0] = 1.8; //gamma=1.8(as gamma of Prophoto)
+ ga[1] = 1.;
+ ga[2] = 0.;
+ ga[3] = 1. / eps;
+ ga[4] = 0.;
+ } else if (gammaPreset == "Lab_g3.0s9.03296") {
+ sGammaPreset = "LAB_g3.0_s9.03296";
+ ga[0] = 3.0; //Lab gamma =3 slope=9.03296
+ ga[1] = 0.8621;
+ ga[2] = 0.1379;
+ ga[3] = 0.1107;
+ ga[4] = 0.08;
+ } else if (gammaPreset == "Custom") {
+ rtengine::GammaValues g_a; //gamma parameters
+ double pwr = 1.0 / gamma;
+ double ts = slope;
+ double slope2 = slope == 0 ? eps : slope;
+
+ int mode = 0;
+ rtengine::Color::calcGamma(pwr, ts, mode, g_a); // call to calcGamma with selected gamma and slope : return parameters for LCMS2
+ ga[4] = g_a[3] * ts;
+ //printf("g_a.gamma0=%f g_a.gamma1=%f g_a.gamma2=%f g_a.gamma3=%f g_a.gamma4=%f\n", g_a.gamma0,g_a.gamma1,g_a.gamma2,g_a.gamma3,g_a.gamma4);
+ ga[0] = gamma;
+ ga[1] = 1. /(1.0 + g_a[4]);
+ ga[2] = g_a[4] /(1.0 + g_a[4]);
+ ga[3] = 1. / slope2;
+ //printf("ga[0]=%f ga[1]=%f ga[2]=%f ga[3]=%f ga[4]=%f\n", ga[0],ga[1],ga[2],ga[3],ga[4]);
+
+ sGammaPreset = Glib::ustring::compose("g%1_s%2",
+ Glib::ustring::format (std::setw(3), std::fixed, std::setprecision(2), gamma),
+ Glib::ustring::format (std::setw(6), std::fixed, std::setprecision(5), slope));
+ presetGamma = gamma;
+ presetSlope = slope;
+ }
+ ga[5] = 0.0;
+ ga[6] = 0.0;
+
+
+ sPrimariesAndIlluminant = sPrimariesPreset;
+
+ if (profileVersion == "v4" && illuminant != "DEF") {
+ sPrimariesPreset += "-" + illuminant;
+ // printf("outpr=%s \n",outPr.c_str());
+ }
+
+ Glib::ustring profileDesc;
+ Glib::ustring sGammaSlopeParam;//to save gamma and slope in a dmdd
+ Glib::ustring sGammaSlopeDesc; //to save gamma and slope in a desc
+ Glib::ustring sGamma;
+ Glib::ustring sSlope;
+
+ if (gammaPreset == "Custom") {
+ sGamma = Glib::ustring::format (std::setw(3), std::fixed, std::setprecision(2), gamma);
+ sSlope = Glib::ustring::format (std::setw(6), std::fixed, std::setprecision(5), slope);
+ fName = Glib::ustring::compose("RT%1_%2_g%3_s%4.icc", profileVersion, sPrimariesAndIlluminant, sGamma, sSlope);
+ profileDesc = sPrimariesPreset;
+ } else {
+ sGamma = Glib::ustring::format (std::setw(3), std::fixed, std::setprecision(2), presetGamma);
+ sSlope = Glib::ustring::format (std::setw(6), std::fixed, std::setprecision(5), presetSlope);
+ fName = Glib::ustring::compose("RT%1_%2_%3.icc", profileVersion, sPrimariesAndIlluminant, sGammaPreset);
+ profileDesc == sPrimariesPreset + sGammaPreset;
+ }
+ sGammaSlopeParam = Glib::ustring::compose("g%1s%2!", sGamma, sSlope);
+ sGammaSlopeDesc = Glib::ustring::compose("g=%1 s=%2", sGamma, sSlope);
+
+ // -------------------------------------------- Asking the file name
+
+ Gtk::FileChooserDialog dialog(getToplevelWindow(this), M("ICCPROFCREATOR_SAVEDIALOG_TITLE"), Gtk::FILE_CHOOSER_ACTION_SAVE);
+ bindCurrentFolder(dialog, options.lastICCProfCreatorDir);
+ dialog.set_current_name(fName);
+ //dialog.set_current_folder(lastPath);
+
+ dialog.add_button(M("GENERAL_CANCEL"), Gtk::RESPONSE_CANCEL);
+ dialog.add_button(M("GENERAL_SAVE"), Gtk::RESPONSE_OK);
+
+ Glib::RefPtr filter_icc = Gtk::FileFilter::create();
+ filter_icc->set_name(M("FILECHOOSER_FILTER_COLPROF"));
+ filter_icc->add_pattern("*.icc");
+ dialog.add_filter(filter_icc);
+
+ /*
+ Glib::RefPtr filter_any = Gtk::FileFilter::create();
+ filter_any->set_name(M("FILECHOOSER_FILTER_ANY"));
+ filter_any->add_pattern("*");
+ dialog.add_filter(filter_any);
+ */
+
+ dialog.show_all_children();
+ //dialog.set_do_overwrite_confirmation (true);
+
+ Glib::ustring absoluteFName;
+
+ do {
+ int result = dialog.run();
+
+ if (result != Gtk::RESPONSE_OK) {
+ return;
+ } else {
+ absoluteFName = dialog.get_filename();
+ Glib::ustring ext = getExtension(absoluteFName);
+
+ if (ext != "icc") {
+ absoluteFName += ".icc";
+ }
+
+ if (confirmOverwrite(dialog, absoluteFName)) {
+ //lastPath = Glib::path_get_dirname(absoluteFName);
+ break;
+ }
+ }
+ } while (1);
+
+ // --------------- main tags ------------------
+
+ if (profileVersion == "v4") {
+ cmsSetProfileVersion(newProfile, 4.3);
+ } else {
+ cmsSetProfileVersion(newProfile, 2.0);
+ }
+
+//change
+ float p[6]; //primaries
+ ga[6] = 0.0;
+
+ ColorTemp temp;
+ getPrimaries(primariesPreset, p, temp);
+
+ cmsCIExyY xyD;
+ cmsCIExyYTRIPLE Primaries = {
+ {p[0], p[1], 1.0}, // red
+ {p[2], p[3], 1.0}, // green
+ {p[4], p[5], 1.0} // blue
+ };
+
+ if (profileVersion == "v4" && illuminant != "DEF") {
+ double tempv4 = 5000.;
+ if (illuminant == "D41") {
+ tempv4 = 4100.;
+ } else if (illuminant == "D50") {
+ tempv4 = 5003.;
+ } else if (illuminant == "D55") {
+ tempv4 = 5500.;
+ } else if (illuminant == "D60") {
+ tempv4 = 6004.;
+ } else if (illuminant == "D65") {
+ tempv4 = 6504.;
+ } else if (illuminant == "D80") {
+ tempv4 = 8000.;
+ } else if (illuminant == "stdA") {
+ tempv4 = 5003.;
+ }
+ cmsWhitePointFromTemp(&xyD, tempv4);
+ } else {
+ cmsWhitePointFromTemp(&xyD, (double)temp);
+ }
+
+ if (illuminant == "stdA") {
+ xyD = {0.447573, 0.407440, 1.0};
+ }
+
+ // Calculate output profile's rTRC gTRC bTRC
+ cmsToneCurve* GammaTRC[3];
+ GammaTRC[0] = GammaTRC[1] = GammaTRC[2] = cmsBuildParametricToneCurve(nullptr, 5, ga);
+
+ if (profileVersion == "v4") {
+ newProfile = cmsCreateRGBProfile(&xyD, &Primaries, GammaTRC);
+ }
+
+ cmsWriteTag(newProfile, cmsSigRedTRCTag, GammaTRC[0]);
+ cmsWriteTag(newProfile, cmsSigGreenTRCTag, GammaTRC[1]);
+ cmsWriteTag(newProfile, cmsSigBlueTRCTag, GammaTRC[2]);
+
+ // --------------- set dmnd tag ------------------
+
+ cmsMLU *dmnd;
+ dmnd = cmsMLUalloc(nullptr, 1);
+ cmsMLUsetASCII(dmnd, "en", "US", "RawTherapee");
+ cmsWriteTag(newProfile, cmsSigDeviceMfgDescTag, dmnd);
+ cmsMLUfree(dmnd);
+
+ // --------------- set dmdd tag ------------------
+
+ if (profileVersion == "v2") {
+ //write in tag 'dmdd' values of current gamma and slope to retrieve after in Output profile
+ std::wostringstream wGammaSlopeParam;
+ wGammaSlopeParam << sGammaSlopeParam;
+
+ cmsMLU *dmdd = cmsMLUalloc(nullptr, 1);
+ // Language code (2 letters code) : https://www.iso.org/obp/ui/
+ // Country code (2 letters code) : http://www.loc.gov/standards/iso639-2/php/code_list.php
+ if (sGammaSlopeParam.is_ascii()) {
+ if (cmsMLUsetASCII(dmdd, "en", "US", sGammaSlopeParam.c_str())) {
+ if (!cmsWriteTag(newProfile, cmsSigProfileDescriptionTag, dmdd)) {
+ printf("Error: Can't write cmsSigProfileDescriptionTag!\n");
+ }
+ }
+ } else if (cmsMLUsetWide(dmdd, "en", "US", wGammaSlopeParam.str().c_str())) {
+ if (!cmsWriteTag(newProfile, cmsSigDeviceModelDescTag, dmdd)) {
+ printf("Error: Can't write cmsSigDeviceModelDescTag!\n");
+ }
+ } else {
+ printf("Error: cmsMLUsetWide failed for dmdd \"%s\" !\n", sGammaSlopeParam.c_str());
+ }
+ cmsMLUfree(dmdd);
+ }
+
+ // --------------- set desc tag ------------------
+
+ Glib::ustring sDescription;
+ if (!description.empty()) {
+ if (cAppendParamsToDesc->get_active()) {
+ sDescription = description + " / " + sGammaSlopeDesc;
+ } else {
+ sDescription = description;
+ }
+ } else {
+ if (cAppendParamsToDesc->get_active()) {
+ sDescription = profileDesc + " / " + sGammaSlopeDesc;
+ } else {
+ sDescription = profileDesc;
+ }
+ }
+
+ //write in tag 'dmdd' values of current gamma and slope to retrieve after in Output profile
+ std::wostringstream wDescription;
+ wDescription << sDescription;
+
+ cmsMLU *descMLU = cmsMLUalloc(nullptr, 1);
+ // Language code (2 letters code) : https://www.iso.org/obp/ui/
+ // Country code (2 letters code) : http://www.loc.gov/standards/iso639-2/php/code_list.php
+ if (sDescription.is_ascii()) {
+ if (cmsMLUsetASCII(descMLU, "en", "US", sDescription.c_str())) {
+ if (!cmsWriteTag(newProfile, cmsSigProfileDescriptionTag, descMLU)) {
+ printf("Error: Can't write cmsSigProfileDescriptionTag!\n");
+ }
+ }
+ } else if (cmsMLUsetWide(descMLU, "en", "US", wDescription.str().c_str())) {
+ if (!cmsWriteTag(newProfile, cmsSigProfileDescriptionTag, descMLU)) {
+ printf("Error: Can't write cmsSigProfileDescriptionTag!\n");
+ }
+ } else {
+ printf("Error: cmsMLUsetWide failed for desc \"%s\" !\n", sDescription.c_str());
+ }
+ cmsMLUfree(descMLU);
+
+ // --------------- set cprt tag ------------------
+
+ std::wostringstream wCopyright;
+ wCopyright << copyright;
+
+ cmsMLU *copyMLU = cmsMLUalloc(nullptr, 1);
+ if (cmsMLUsetWide(copyMLU, "en", "US", wCopyright.str().c_str())) {
+ if (!cmsWriteTag(newProfile, cmsSigCopyrightTag, copyMLU)) {
+ printf("Error: Can't write cmsSigCopyrightTag!\n");
+ }
+ } else {
+ printf("Error: cmsMLUsetWide failed for cprt \"%s\" !\n", copyright.c_str());
+ }
+ cmsMLUfree(copyMLU);
+
+
+ /* //to read XYZ values
+ cmsCIEXYZ *redT = static_cast(cmsReadTag(newProfile, cmsSigRedMatrixColumnTag));
+ cmsCIEXYZ *greenT = static_cast(cmsReadTag(newProfile, cmsSigGreenMatrixColumnTag));
+ cmsCIEXYZ *blueT = static_cast(cmsReadTag(newProfile, cmsSigBlueMatrixColumnTag));
+ printf("rx=%f gx=%f bx=%f ry=%f gy=%f by=%f rz=%f gz=%f bz=%f\n", redT->X, greenT->X, blueT->X, redT->Y, greenT->Y, blueT->Y, redT->Z, greenT->Z, blueT->Z);
+ */
+
+ cmsSaveProfileToFile(newProfile, absoluteFName.c_str());
+
+ cmsFreeToneCurve(GammaTRC[0]);
+}
diff --git a/rtgui/iccprofilecreator.h b/rtgui/iccprofilecreator.h
new file mode 100644
index 000000000..c3f2e48a1
--- /dev/null
+++ b/rtgui/iccprofilecreator.h
@@ -0,0 +1,106 @@
+/*
+ * This file is part of RawTherapee.
+ *
+ * Copyright (c) 2018 Jacques DESMIS
+ * Copyright (c) 2018 Jean-Christophe FRISCH
+ *
+ * RawTherapee is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * RawTherapee is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with RawTherapee. If not, see .
+ */
+#pragma once
+
+#include
+#include "adjuster.h"
+#include "options.h"
+#include
+#include "rtwindow.h"
+
+class ICCProfileCreator : public Gtk::Dialog, public AdjusterListener
+{
+
+private:
+
+ enum class ColorTemp {
+ D50 = 5003, // for Widegamut, Prophoto Best, Beta -> D50
+ D60 = 6005, // for ACESc -> D60
+ D65 = 6504 // for sRGB, AdobeRGB, Bruce Rec2020 -> D65
+ };
+
+ cmsFloat64Number ga[7]; // 7 parameters for smoother curves
+
+ //------------------------ Params -----------------------
+ Glib::ustring primariesPreset;
+ double redPrimaryX;
+ double redPrimaryY;
+ double greenPrimaryX;
+ double greenPrimaryY;
+ double bluePrimaryX;
+ double bluePrimaryY;
+ Glib::ustring gammaPreset;
+ double gamma;
+ double slope;
+ bool appendParamsToDesc;
+
+ Glib::ustring profileVersion;
+ Glib::ustring illuminant;
+ Glib::ustring description;
+ Glib::ustring copyright;
+ //-------------------------------------------------------
+
+ RTWindow *parent;
+
+ Adjuster* aGamma;
+ Adjuster* aSlope;
+ Adjuster* aPrimariesRedX;
+ Adjuster* aPrimariesRedY;
+ Adjuster* aPrimariesGreenX;
+ Adjuster* aPrimariesGreenY;
+ Adjuster* aPrimariesBlueX;
+ Adjuster* aPrimariesBlueY;
+
+ Gtk::Grid* primariesGrid;
+ MyComboBoxText* iccVersion;
+ MyComboBoxText* trcPresets;
+ sigc::connection trcpresetsconn;
+ MyComboBoxText* primaries;
+ sigc::connection primariesconn;
+ MyComboBoxText* cIlluminant;
+ sigc::connection illconn;
+ Gtk::Entry* eDescription;
+ Gtk::Entry* eCopyright;
+ Gtk::Button* resetCopyright;
+ Gtk::CheckButton *cAppendParamsToDesc;
+
+ //Glib::ustring lastPath;
+
+ void initWithDefaults ();
+ void storeDefaults ();
+ void storeValues();
+
+ void updateICCVersion();
+ void primariesChanged();
+ void illuminantChanged();
+ void trcPresetsChanged();
+ void adjusterChanged (Adjuster* a, double newval);
+ static std::vector getGamma();
+ Glib::ustring getPrimariesPresetName(const Glib::ustring &preset);
+ void getPrimaries(const Glib::ustring &preset, float *p, ColorTemp &temp);
+ Glib::ustring getGammaPresetName(const Glib::ustring &preset);
+ void getGamma(const Glib::ustring &preset, double &gamma, double &slope);
+ void savePressed();
+ void closePressed();
+ void onResetCopyright();
+
+public:
+ explicit ICCProfileCreator (RTWindow *rtwindow);
+};
diff --git a/rtgui/icmpanel.cc b/rtgui/icmpanel.cc
index bfb13ba3f..84aa26014 100644
--- a/rtgui/icmpanel.cc
+++ b/rtgui/icmpanel.cc
@@ -19,6 +19,8 @@
#include
#include "icmpanel.h"
#include "options.h"
+#include "eventmapper.h"
+
#include "guiutils.h"
#include "../rtengine/iccstore.h"
#include "../rtengine/dcp.h"
@@ -29,103 +31,115 @@ using namespace rtengine::procparams;
extern Options options;
-ICMPanel::ICMPanel () : FoldableToolPanel(this, "icm", M("TP_ICM_LABEL")), iunchanged(nullptr), icmplistener(nullptr), lastRefFilename(""), camName("")
+ICMPanel::ICMPanel() : FoldableToolPanel(this, "icm", M("TP_ICM_LABEL")), iunchanged(nullptr), icmplistener(nullptr), lastRefFilename(""), camName("")
{
+ auto m = ProcEventMapper::getInstance();
+ EvICMprimariMethod = m->newEvent(GAMMA, "HISTORY_MSG_ICMPRIMARI");
+ EvICMprofileMethod = m->newEvent(GAMMA, "HISTORY_MSG_ICMPROFILE");
+ EvICMtempMethod = m->newEvent(GAMMA, "HISTORY_MSG_ICMTEMP");
+ EvICMpredx = m->newEvent(GAMMA, "HISTORY_MSG_ICMPREDX");
+ EvICMpredy = m->newEvent(GAMMA, "HISTORY_MSG_ICMPREDY");
+ EvICMpgrex = m->newEvent(GAMMA, "HISTORY_MSG_ICMPGREX");
+ EvICMpgrey = m->newEvent(GAMMA, "HISTORY_MSG_ICMPGREY");
+ EvICMpblux = m->newEvent(GAMMA, "HISTORY_MSG_ICMPBLUX");
+ EvICMpbluy = m->newEvent(GAMMA, "HISTORY_MSG_ICMPBLUY");
+ EvICMgamm = m->newEvent(ALLNORAW, "HISTORY_MSG_ICMGAMM");
+ EvICMslop = m->newEvent(ALLNORAW, "HISTORY_MSG_ICMSLOP");
+ EvICMtrcinMethod = m->newEvent(ALLNORAW, "HISTORY_MSG_ICMTRCIN");
- isBatchMode = lastToneCurve = lastApplyLookTable = lastApplyBaselineExposureOffset = lastApplyHueSatMap = lastgamfree = false;
+ isBatchMode = lastToneCurve = lastApplyLookTable = lastApplyBaselineExposureOffset = lastApplyHueSatMap = false;
- ipDialog = Gtk::manage (new MyFileChooserButton (M("TP_ICM_INPUTDLGLABEL"), Gtk::FILE_CHOOSER_ACTION_OPEN));
- ipDialog->set_tooltip_text (M("TP_ICM_INPUTCUSTOM_TOOLTIP"));
- bindCurrentFolder (*ipDialog, options.lastIccDir);
+ ipDialog = Gtk::manage(new MyFileChooserButton(M("TP_ICM_INPUTDLGLABEL"), Gtk::FILE_CHOOSER_ACTION_OPEN));
+ ipDialog->set_tooltip_text(M("TP_ICM_INPUTCUSTOM_TOOLTIP"));
+ bindCurrentFolder(*ipDialog, options.lastIccDir);
// ------------------------------- Input profile
- Gtk::Frame *iFrame = Gtk::manage (new Gtk::Frame(M("TP_ICM_INPUTPROFILE")) );
+ Gtk::Frame *iFrame = Gtk::manage(new Gtk::Frame(M("TP_ICM_INPUTPROFILE")));
iFrame->set_label_align(0.025, 0.5);
- iVBox = Gtk::manage ( new Gtk::VBox());
- iVBox->set_spacing(2);
+ iVBox = Gtk::manage(new Gtk::VBox());
- inone = Gtk::manage (new Gtk::RadioButton (M("TP_ICM_INPUTNONE")));
- inone->set_tooltip_text (M("TP_ICM_INPUTNONE_TOOLTIP"));
- iVBox->pack_start (*inone, Gtk::PACK_SHRINK);
+ inone = Gtk::manage(new Gtk::RadioButton(M("TP_ICM_INPUTNONE")));
+ inone->set_tooltip_text(M("TP_ICM_INPUTNONE_TOOLTIP"));
+ iVBox->pack_start(*inone, Gtk::PACK_SHRINK);
- iembedded = Gtk::manage (new Gtk::RadioButton (M("TP_ICM_INPUTEMBEDDED")));
- iembedded->set_tooltip_text (M("TP_ICM_INPUTEMBEDDED_TOOLTIP"));
- iVBox->pack_start (*iembedded, Gtk::PACK_SHRINK);
+ iembedded = Gtk::manage(new Gtk::RadioButton(M("TP_ICM_INPUTEMBEDDED")));
+ iembedded->set_tooltip_text(M("TP_ICM_INPUTEMBEDDED_TOOLTIP"));
+ iVBox->pack_start(*iembedded, Gtk::PACK_SHRINK);
- icamera = Gtk::manage (new Gtk::RadioButton (M("TP_ICM_INPUTCAMERA")));
- icamera->set_tooltip_text (M("TP_ICM_INPUTCAMERA_TOOLTIP"));
- iVBox->pack_start (*icamera, Gtk::PACK_SHRINK);
+ icamera = Gtk::manage(new Gtk::RadioButton(M("TP_ICM_INPUTCAMERA")));
+ icamera->set_tooltip_text(M("TP_ICM_INPUTCAMERA_TOOLTIP"));
+ iVBox->pack_start(*icamera, Gtk::PACK_SHRINK);
- icameraICC = Gtk::manage (new Gtk::RadioButton (M("TP_ICM_INPUTCAMERAICC")));
- icameraICC->set_tooltip_text (M("TP_ICM_INPUTCAMERAICC_TOOLTIP"));
- iVBox->pack_start (*icameraICC, Gtk::PACK_SHRINK);
+ icameraICC = Gtk::manage(new Gtk::RadioButton(M("TP_ICM_INPUTCAMERAICC")));
+ icameraICC->set_tooltip_text(M("TP_ICM_INPUTCAMERAICC_TOOLTIP"));
+ iVBox->pack_start(*icameraICC, Gtk::PACK_SHRINK);
- ifromfile = Gtk::manage (new Gtk::RadioButton (M("TP_ICM_INPUTCUSTOM") + ":"));
- Gtk::HBox* ffbox = Gtk::manage (new Gtk::HBox ());
- ifromfile->set_tooltip_text (M("TP_ICM_INPUTCUSTOM_TOOLTIP"));
- ffbox->pack_start (*ifromfile, Gtk::PACK_SHRINK);
- ffbox->pack_start (*ipDialog);
+ ifromfile = Gtk::manage(new Gtk::RadioButton(M("TP_ICM_INPUTCUSTOM") + ":"));
+ Gtk::HBox* ffbox = Gtk::manage(new Gtk::HBox());
+ ifromfile->set_tooltip_text(M("TP_ICM_INPUTCUSTOM_TOOLTIP"));
+ ffbox->pack_start(*ifromfile, Gtk::PACK_SHRINK);
+ ffbox->pack_start(*ipDialog);
- iVBox->pack_start (*ffbox, Gtk::PACK_SHRINK);
+ iVBox->pack_start(*ffbox, Gtk::PACK_SHRINK);
opts = icamera->get_group();
- icameraICC->set_group (opts);
- iembedded->set_group (opts);
- ifromfile->set_group (opts);
- inone->set_group (opts);
+ icameraICC->set_group(opts);
+ iembedded->set_group(opts);
+ ifromfile->set_group(opts);
+ inone->set_group(opts);
- dcpFrame = Gtk::manage (new Gtk::Frame ("DCP"));
+ dcpFrame = Gtk::manage(new Gtk::Frame("DCP"));
- Gtk::Grid* dcpGrid = Gtk::manage ( new Gtk::Grid());
+ Gtk::Grid* dcpGrid = Gtk::manage(new Gtk::Grid());
dcpGrid->set_column_homogeneous(false);
dcpGrid->set_row_homogeneous(false);
dcpGrid->set_column_spacing(2);
dcpGrid->set_row_spacing(2);
- Gtk::Grid* dcpIllGrid = Gtk::manage ( new Gtk::Grid());
+ Gtk::Grid* dcpIllGrid = Gtk::manage(new Gtk::Grid());
dcpIllGrid->set_column_homogeneous(false);
dcpIllGrid->set_row_homogeneous(false);
dcpIllGrid->set_column_spacing(2);
dcpIllGrid->set_row_spacing(2);
- dcpIllLabel = Gtk::manage (new Gtk::Label (M("TP_ICM_DCPILLUMINANT") + ":"));
+ dcpIllLabel = Gtk::manage(new Gtk::Label(M("TP_ICM_DCPILLUMINANT") + ":"));
setExpandAlignProperties(dcpIllLabel, false, false, Gtk::ALIGN_START, Gtk::ALIGN_CENTER);
- dcpIllLabel->set_tooltip_text (M("TP_ICM_DCPILLUMINANT_TOOLTIP"));
- dcpIllLabel->show ();
- dcpIll = Gtk::manage (new MyComboBoxText ());
+ dcpIllLabel->set_tooltip_text(M("TP_ICM_DCPILLUMINANT_TOOLTIP"));
+ dcpIllLabel->show();
+ dcpIll = Gtk::manage(new MyComboBoxText());
setExpandAlignProperties(dcpIll, true, false, Gtk::ALIGN_FILL, Gtk::ALIGN_CENTER);
- dcpIll->set_tooltip_text (M("TP_ICM_DCPILLUMINANT_TOOLTIP"));
- dcpIll->append (M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 1");
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 2");
- dcpIll->show ();
+ dcpIll->set_tooltip_text(M("TP_ICM_DCPILLUMINANT_TOOLTIP"));
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 1");
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 2");
+ dcpIll->show();
dcpTemperatures[0] = 0;
dcpTemperatures[1] = 0;
dcpIllGrid->attach_next_to(*dcpIllLabel, Gtk::POS_LEFT, 1, 1);
dcpIllGrid->attach_next_to(*dcpIll, *dcpIllLabel, Gtk::POS_RIGHT, 1, 1);
- ckbToneCurve = Gtk::manage (new Gtk::CheckButton (M("TP_ICM_TONECURVE")));
- ckbToneCurve->set_sensitive (false);
- ckbToneCurve->set_tooltip_text (M("TP_ICM_TONECURVE_TOOLTIP"));
+ ckbToneCurve = Gtk::manage(new Gtk::CheckButton(M("TP_ICM_TONECURVE")));
+ ckbToneCurve->set_sensitive(false);
+ ckbToneCurve->set_tooltip_text(M("TP_ICM_TONECURVE_TOOLTIP"));
setExpandAlignProperties(ckbToneCurve, false, false, Gtk::ALIGN_START, Gtk::ALIGN_CENTER);
- ckbApplyLookTable = Gtk::manage (new Gtk::CheckButton (M("TP_ICM_APPLYLOOKTABLE")));
- ckbApplyLookTable->set_sensitive (false);
- ckbApplyLookTable->set_tooltip_text (M("TP_ICM_APPLYLOOKTABLE_TOOLTIP"));
+ ckbApplyLookTable = Gtk::manage(new Gtk::CheckButton(M("TP_ICM_APPLYLOOKTABLE")));
+ ckbApplyLookTable->set_sensitive(false);
+ ckbApplyLookTable->set_tooltip_text(M("TP_ICM_APPLYLOOKTABLE_TOOLTIP"));
setExpandAlignProperties(ckbApplyLookTable, false, false, Gtk::ALIGN_START, Gtk::ALIGN_CENTER);
- ckbApplyHueSatMap = Gtk::manage (new Gtk::CheckButton (M("TP_ICM_APPLYHUESATMAP")));
- ckbApplyHueSatMap->set_sensitive (false);
- ckbApplyHueSatMap->set_tooltip_text (M("TP_ICM_APPLYHUESATMAP_TOOLTIP"));
+ ckbApplyHueSatMap = Gtk::manage(new Gtk::CheckButton(M("TP_ICM_APPLYHUESATMAP")));
+ ckbApplyHueSatMap->set_sensitive(false);
+ ckbApplyHueSatMap->set_tooltip_text(M("TP_ICM_APPLYHUESATMAP_TOOLTIP"));
setExpandAlignProperties(ckbApplyHueSatMap, false, false, Gtk::ALIGN_START, Gtk::ALIGN_CENTER);
- ckbApplyBaselineExposureOffset = Gtk::manage (new Gtk::CheckButton (M("TP_ICM_APPLYBASELINEEXPOSUREOFFSET")));
- ckbApplyBaselineExposureOffset->set_sensitive (false);
- ckbApplyBaselineExposureOffset->set_tooltip_text (M("TP_ICM_APPLYBASELINEEXPOSUREOFFSET_TOOLTIP"));
+ ckbApplyBaselineExposureOffset = Gtk::manage(new Gtk::CheckButton(M("TP_ICM_APPLYBASELINEEXPOSUREOFFSET")));
+ ckbApplyBaselineExposureOffset->set_sensitive(false);
+ ckbApplyBaselineExposureOffset->set_tooltip_text(M("TP_ICM_APPLYBASELINEEXPOSUREOFFSET_TOOLTIP"));
setExpandAlignProperties(ckbApplyBaselineExposureOffset, false, false, Gtk::ALIGN_START, Gtk::ALIGN_CENTER);
dcpGrid->attach_next_to(*dcpIllGrid, Gtk::POS_BOTTOM, 1, 1);
@@ -136,142 +150,128 @@ ICMPanel::ICMPanel () : FoldableToolPanel(this, "icm", M("TP_ICM_LABEL")), iunch
dcpFrame->add(*dcpGrid);
dcpFrame->set_sensitive(false);
- iVBox->pack_start (*dcpFrame);
+ iVBox->pack_start(*dcpFrame);
- saveRef = Gtk::manage (new Gtk::Button (M("TP_ICM_SAVEREFERENCE")));
- saveRef->set_image (*Gtk::manage (new RTImage ("save-small.png")));
- saveRef->set_alignment (0.5f, 0.5f);
- saveRef->set_tooltip_markup (M("TP_ICM_SAVEREFERENCE_TOOLTIP"));
- iVBox->pack_start (*saveRef, Gtk::PACK_SHRINK);
+ saveRef = Gtk::manage(new Gtk::Button(M("TP_ICM_SAVEREFERENCE")));
+ saveRef->set_image(*Gtk::manage(new RTImage("save-small.png")));
+ saveRef->set_alignment(0.5f, 0.5f);
+ saveRef->set_tooltip_markup(M("TP_ICM_SAVEREFERENCE_TOOLTIP"));
+ iVBox->pack_start(*saveRef, Gtk::PACK_SHRINK);
iFrame->add(*iVBox);
- pack_start (*iFrame, Gtk::PACK_EXPAND_WIDGET);
+ pack_start(*iFrame, Gtk::PACK_EXPAND_WIDGET);
// ---------------------------- Working profile
- Gtk::Frame *wFrame = Gtk::manage (new Gtk::Frame(M("TP_ICM_WORKINGPROFILE")) );
+ Gtk::Frame *wFrame = Gtk::manage(new Gtk::Frame(M("TP_ICM_WORKINGPROFILE")));
wFrame->set_label_align(0.025, 0.5);
- Gtk::VBox *wVBox = Gtk::manage ( new Gtk::VBox());
- wVBox->set_spacing(2);
+ Gtk::VBox *wProfVBox = Gtk::manage(new Gtk::VBox());
- wnames = Gtk::manage (new MyComboBoxText ());
- wVBox->pack_start (*wnames, Gtk::PACK_SHRINK);
+ wProfNames = Gtk::manage(new MyComboBoxText());
+ wProfVBox->pack_start(*wProfNames, Gtk::PACK_SHRINK);
std::vector wpnames = rtengine::ICCStore::getInstance()->getWorkingProfiles();
for (size_t i = 0; i < wpnames.size(); i++) {
- wnames->append (wpnames[i]);
+ wProfNames->append(wpnames[i]);
}
- wnames->set_active (0);
+ wProfNames->set_active(0);
- wFrame->add(*wVBox);
- pack_start (*wFrame, Gtk::PACK_EXPAND_WIDGET);
+ // wFrame->add(*wVBox);
+
+ //-----------------gamma TRC working
+
+ wTRCHBox = Gtk::manage(new Gtk::HBox());
+
+ Gtk::Label* wtrclab = Gtk::manage(new Gtk::Label(M("TP_ICM_WORKTRC")));
+
+ wTRCHBox->pack_start(*wtrclab, Gtk::PACK_SHRINK);
+ wTRC = Gtk::manage(new MyComboBoxText());
+ wTRCHBox->pack_start(*wTRC, Gtk::PACK_EXPAND_WIDGET);
+ wProfVBox->pack_start(*wTRCHBox, Gtk::PACK_EXPAND_WIDGET);
+ wTRC->append(M("TP_ICM_WORKTRC_NONE"));
+ wTRC->append(M("TP_ICM_WORKTRC_CUSTOM"));
+
+ wTRC->set_active(0);
+ wTRC->set_tooltip_text(M("TP_ICM_WORKTRC_TOOLTIP"));
+
+
+ wGamma = Gtk::manage(new Adjuster(M("TP_ICM_WORKTRC_GAMMA"), 0.40, 15.0, 0.001, 2.4));
+ wSlope = Gtk::manage(new Adjuster(M("TP_ICM_WORKTRC_SLOPE"), 0., 150., 0.01, 12.92310));
+ wProfVBox->pack_start(*wGamma, Gtk::PACK_SHRINK);
+ wGamma->show();
+
+ wProfVBox->pack_start(*wSlope, Gtk::PACK_SHRINK);
+ wSlope->show();
+
+
+ wGamma->setAdjusterListener(this);
+ wSlope->setAdjusterListener(this);
+
+ if (wGamma->delay < options.adjusterMaxDelay) {
+ wGamma->delay = options.adjusterMaxDelay;
+ }
+
+ if (wSlope->delay < options.adjusterMaxDelay) {
+ wSlope->delay = options.adjusterMaxDelay;
+ }
+
+ wFrame->add(*wProfVBox);
+
+ pack_start(*wFrame, Gtk::PACK_EXPAND_WIDGET);
// ---------------------------- Output profile
- Gtk::Frame *oFrame = Gtk::manage (new Gtk::Frame(M("TP_ICM_OUTPUTPROFILE")) );
+ Gtk::Frame *oFrame = Gtk::manage(new Gtk::Frame(M("TP_ICM_OUTPUTPROFILE")));
oFrame->set_label_align(0.025, 0.5);
- Gtk::VBox *oVBox = Gtk::manage ( new Gtk::VBox());
- oVBox->set_spacing(2);
+ Gtk::VBox *oProfVBox = Gtk::manage(new Gtk::VBox());
- onames = Gtk::manage (new MyComboBoxText ());
- oVBox->pack_start (*onames, Gtk::PACK_SHRINK);
+ oProfNames = Gtk::manage(new MyComboBoxText());
+ oProfVBox->pack_start(*oProfNames, Gtk::PACK_SHRINK);
- onames->append (M("TP_ICM_NOICM"));
- onames->set_active (0);
+ oProfNames->append(M("TP_ICM_NOICM"));
+ oProfNames->set_active(0);
- std::vector opnames = ICCStore::getInstance()->getProfiles (rtengine::ICCStore::ProfileType::OUTPUT);
+ std::vector opnames = ICCStore::getInstance()->getProfiles(rtengine::ICCStore::ProfileType::OUTPUT);
for (size_t i = 0; i < opnames.size(); i++) {
- onames->append (opnames[i]);
+ oProfNames->append(opnames[i]);
}
- onames->set_active (0);
+ oProfNames->set_active(0);
// Rendering intent
- Gtk::HBox *riHBox = Gtk::manage ( new Gtk::HBox());
- Gtk::Label* outputIntentLbl = Gtk::manage (new Gtk::Label(M("TP_ICM_PROFILEINTENT")+":"));
- riHBox->pack_start (*outputIntentLbl, Gtk::PACK_SHRINK);
- ointent.reset (new PopUpButton ());
- ointent->addEntry("intent-perceptual.png", M("PREFERENCES_INTENT_PERCEPTUAL"));
- ointent->addEntry("intent-relative.png", M("PREFERENCES_INTENT_RELATIVE"));
- ointent->addEntry("intent-saturation.png", M("PREFERENCES_INTENT_SATURATION"));
- ointent->addEntry("intent-absolute.png", M("PREFERENCES_INTENT_ABSOLUTE"));
- ointent->setSelected (1);
- ointent->show();
- riHBox->pack_start (*ointent->buttonGroup, Gtk::PACK_EXPAND_PADDING);
- oVBox->pack_start(*riHBox, Gtk::PACK_SHRINK);
+ Gtk::HBox *riHBox = Gtk::manage(new Gtk::HBox());
+ Gtk::Label* outputIntentLbl = Gtk::manage(new Gtk::Label(M("TP_ICM_PROFILEINTENT")));
+ riHBox->pack_start(*outputIntentLbl, Gtk::PACK_SHRINK);
+ oRendIntent.reset(new PopUpButton());
+ oRendIntent->addEntry("intent-perceptual.png", M("PREFERENCES_INTENT_PERCEPTUAL"));
+ oRendIntent->addEntry("intent-relative.png", M("PREFERENCES_INTENT_RELATIVE"));
+ oRendIntent->addEntry("intent-saturation.png", M("PREFERENCES_INTENT_SATURATION"));
+ oRendIntent->addEntry("intent-absolute.png", M("PREFERENCES_INTENT_ABSOLUTE"));
+ oRendIntent->setSelected(1);
+ oRendIntent->show();
+ riHBox->pack_start(*oRendIntent->buttonGroup, Gtk::PACK_EXPAND_PADDING);
+ oProfVBox->pack_start(*riHBox, Gtk::PACK_SHRINK);
// Black Point Compensation
obpc = Gtk::manage(new Gtk::CheckButton((M("TP_ICM_BPC"))));
- obpc->set_active (true);
- oVBox->pack_start(*obpc, Gtk::PACK_SHRINK);
+ obpc->set_active(true);
+ oProfVBox->pack_start(*obpc, Gtk::PACK_SHRINK);
- // Output gamma
-
- Gtk::HBox* gaHBox = Gtk::manage (new Gtk::HBox ());
- Gtk::Label* galab = Gtk::manage (new Gtk::Label (M("TP_GAMMA_OUTPUT") + ":"));
- //galab->set_alignment (0.0, 0.5);
-
- gaHBox->pack_start (*galab, Gtk::PACK_SHRINK);
- wgamma = Gtk::manage (new MyComboBoxText ());
- gaHBox->pack_start (*wgamma, Gtk::PACK_EXPAND_WIDGET);
-
- oVBox->pack_start(*gaHBox, Gtk::PACK_EXPAND_WIDGET);
-
- std::vector wpgamma = rtengine::ICCStore::getGamma();
-
- for (size_t i = 0; i < wpgamma.size(); i++) {
- wgamma->append (wpgamma[i]);
- }
-
- wgamma->set_active (0);
-
- Gtk::Frame* fgFrame = Gtk::manage (new Gtk::Frame ());
-
- Gtk::VBox *fgVBox = Gtk::manage ( new Gtk::VBox());
- fgVBox->set_spacing(2);
-
- freegamma = Gtk::manage(new Gtk::CheckButton((M("TP_GAMMA_FREE"))));
- freegamma->set_active (false);
- fgFrame->set_label_widget(*freegamma);
-
- gampos = Gtk::manage(new Adjuster (M("TP_GAMMA_CURV"), 1, 3.5, 0.01, 2.22));
- gampos->setAdjusterListener (this);
-
- if (gampos->delay < options.adjusterMaxDelay) {
- gampos->delay = options.adjusterMaxDelay;
- }
-
- gampos->show();
- slpos = Gtk::manage(new Adjuster (M("TP_GAMMA_SLOP"), 0, 15, 0.01, 4.5));
- slpos->setAdjusterListener (this);
-
- if (slpos->delay < options.adjusterMaxDelay) {
- slpos->delay = options.adjusterMaxDelay;
- }
-
- slpos->show();
- fgVBox->pack_start( *gampos, Gtk::PACK_SHRINK);//gamma
- fgVBox->pack_start( *slpos, Gtk::PACK_SHRINK);//slope
-
- fgFrame->add(*fgVBox);
- oVBox->pack_start(*fgFrame, Gtk::PACK_EXPAND_WIDGET);
-
- oFrame->add(*oVBox);
- pack_start (*oFrame, Gtk::PACK_EXPAND_WIDGET);
+ oFrame->add(*oProfVBox);
+ pack_start(*oFrame, Gtk::PACK_EXPAND_WIDGET);
// ---------------------------- Output gamma list entries
-
Glib::RefPtr filter_icc = Gtk::FileFilter::create();
filter_icc->set_name(M("FILECHOOSER_FILTER_COLPROF"));
filter_icc->add_pattern("*.dcp");
@@ -294,42 +294,41 @@ ICMPanel::ICMPanel () : FoldableToolPanel(this, "icm", M("TP_ICM_LABEL")), iunch
filter_any->set_name(M("FILECHOOSER_FILTER_ANY"));
filter_any->add_pattern("*");
- ipDialog->add_filter (filter_icc);
- ipDialog->add_filter (filter_iccdng);
- ipDialog->add_filter (filter_any);
+ ipDialog->add_filter(filter_icc);
+ ipDialog->add_filter(filter_iccdng);
+ ipDialog->add_filter(filter_any);
#ifdef WIN32
ipDialog->set_show_hidden(true); // ProgramData is hidden on Windows
#endif
-
oldip = "";
- wnamesconn = wnames->signal_changed().connect( sigc::mem_fun(*this, &ICMPanel::wpChanged) );
- onamesconn = onames->signal_changed().connect( sigc::mem_fun(*this, &ICMPanel::opChanged) );
- ointentconn = ointent->signal_changed().connect( sigc::mem_fun(*this, &ICMPanel::oiChanged) );
- wgammaconn = wgamma->signal_changed().connect( sigc::mem_fun(*this, &ICMPanel::gpChanged) );
- dcpillconn = dcpIll->signal_changed().connect( sigc::mem_fun(*this, &ICMPanel::dcpIlluminantChanged) );
+ wprofnamesconn = wProfNames->signal_changed().connect(sigc::mem_fun(*this, &ICMPanel::wpChanged));
+ oprofnamesconn = oProfNames->signal_changed().connect(sigc::mem_fun(*this, &ICMPanel::opChanged));
+ orendintentconn = oRendIntent->signal_changed().connect(sigc::mem_fun(*this, &ICMPanel::oiChanged));
+ dcpillconn = dcpIll->signal_changed().connect(sigc::mem_fun(*this, &ICMPanel::dcpIlluminantChanged));
+ wtrcconn = wTRC->signal_changed().connect(sigc::mem_fun(*this, &ICMPanel::wtrcinChanged));
- obpcconn = obpc->signal_toggled().connect( sigc::mem_fun(*this, &ICMPanel::oBPCChanged) );
- gamcsconn = freegamma->signal_toggled().connect ( sigc::mem_fun(*this, &ICMPanel::GamChanged));
- tcurveconn = ckbToneCurve->signal_toggled().connect ( sigc::mem_fun(*this, &ICMPanel::toneCurveChanged));
- ltableconn = ckbApplyLookTable->signal_toggled().connect ( sigc::mem_fun(*this, &ICMPanel::applyLookTableChanged));
- beoconn = ckbApplyBaselineExposureOffset->signal_toggled().connect ( sigc::mem_fun(*this, &ICMPanel::applyBaselineExposureOffsetChanged));
- hsmconn = ckbApplyHueSatMap->signal_toggled().connect ( sigc::mem_fun(*this, &ICMPanel::applyHueSatMapChanged));
+ obpcconn = obpc->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::oBPCChanged));
+ tcurveconn = ckbToneCurve->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::toneCurveChanged));
+ ltableconn = ckbApplyLookTable->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::applyLookTableChanged));
+ beoconn = ckbApplyBaselineExposureOffset->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::applyBaselineExposureOffsetChanged));
+ hsmconn = ckbApplyHueSatMap->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::applyHueSatMapChanged));
- icamera->signal_toggled().connect( sigc::mem_fun(*this, &ICMPanel::ipChanged) );
- icameraICC->signal_toggled().connect( sigc::mem_fun(*this, &ICMPanel::ipChanged) );
- iembedded->signal_toggled().connect( sigc::mem_fun(*this, &ICMPanel::ipChanged) );
- ifromfile->signal_toggled().connect( sigc::mem_fun(*this, &ICMPanel::ipChanged) );
+ icamera->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::ipChanged));
+ icameraICC->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::ipChanged));
+ iembedded->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::ipChanged));
+ ifromfile->signal_toggled().connect(sigc::mem_fun(*this, &ICMPanel::ipChanged));
- ipc = ipDialog->signal_selection_changed().connect( sigc::mem_fun(*this, &ICMPanel::ipSelectionChanged) );
- saveRef->signal_pressed().connect( sigc::mem_fun(*this, &ICMPanel::saveReferencePressed) );
+ ipc = ipDialog->signal_selection_changed().connect(sigc::mem_fun(*this, &ICMPanel::ipSelectionChanged));
+ saveRef->signal_pressed().connect(sigc::mem_fun(*this, &ICMPanel::saveReferencePressed));
- show_all ();
+ show_all();
}
-void ICMPanel::updateRenderingIntent (const Glib::ustring &profile) {
- const uint8_t supportedIntents = rtengine::ICCStore::getInstance()->getOutputIntents (profile);
+void ICMPanel::updateRenderingIntent(const Glib::ustring &profile)
+{
+ const uint8_t supportedIntents = rtengine::ICCStore::getInstance()->getOutputIntents(profile);
const bool supportsPerceptual = supportedIntents & 1 << INTENT_PERCEPTUAL;
const bool supportsRelative = supportedIntents & 1 << INTENT_RELATIVE_COLORIMETRIC;
const bool supportsSaturation = supportedIntents & 1 << INTENT_SATURATION;
@@ -338,44 +337,44 @@ void ICMPanel::updateRenderingIntent (const Glib::ustring &profile) {
//printf("Intents: %d / Perceptual: %d Relative: %d Saturation: %d Absolute: %d\n", supportedIntents, supportsPerceptual, supportsRelative, supportsSaturation, supportsAbsolute);
if (!profile.empty() && (supportsPerceptual || supportsRelative || supportsSaturation || supportsAbsolute)) {
- ointent->set_sensitive (true);
- ointent->setItemSensitivity(0, supportsPerceptual);
- ointent->setItemSensitivity(1, supportsRelative);
- ointent->setItemSensitivity(2, supportsSaturation);
- ointent->setItemSensitivity(3, supportsAbsolute);
+ oRendIntent->set_sensitive(true);
+ oRendIntent->setItemSensitivity(0, supportsPerceptual);
+ oRendIntent->setItemSensitivity(1, supportsRelative);
+ oRendIntent->setItemSensitivity(2, supportsSaturation);
+ oRendIntent->setItemSensitivity(3, supportsAbsolute);
} else {
- ointent->setItemSensitivity(0, true);
- ointent->setItemSensitivity(1, true);
- ointent->setItemSensitivity(2, true);
- ointent->setItemSensitivity(3, true);
- ointent->set_sensitive (false);
- ointent->setSelected (1);
+ oRendIntent->setItemSensitivity(0, true);
+ oRendIntent->setItemSensitivity(1, true);
+ oRendIntent->setItemSensitivity(2, true);
+ oRendIntent->setItemSensitivity(3, true);
+ oRendIntent->set_sensitive(false);
+ oRendIntent->setSelected(1);
}
}
-void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
+void ICMPanel::updateDCP(int dcpIlluminant, Glib::ustring dcp_name)
{
ConnectionBlocker dcpillconn_(dcpillconn);
if (isBatchMode) {
dcpFrame->set_sensitive(true);
- ckbToneCurve->set_sensitive (true);
- ckbApplyLookTable->set_sensitive (true);
- ckbApplyBaselineExposureOffset->set_sensitive (true);
- ckbApplyHueSatMap->set_sensitive (true);
- dcpIllLabel->set_sensitive (true);
- dcpIll->set_sensitive (true);
+ ckbToneCurve->set_sensitive(true);
+ ckbApplyLookTable->set_sensitive(true);
+ ckbApplyBaselineExposureOffset->set_sensitive(true);
+ ckbApplyHueSatMap->set_sensitive(true);
+ dcpIllLabel->set_sensitive(true);
+ dcpIll->set_sensitive(true);
if (dcpTemperatures[0] != 0 || dcpTemperatures[1] != 0) {
int curr_active = dcpIll->get_active_row_number();
- dcpIll->remove_all ();
- dcpIll->append (M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 1");
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 2");
- dcpIll->append (M("GENERAL_UNCHANGED"));
+ dcpIll->remove_all();
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 1");
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 2");
+ dcpIll->append(M("GENERAL_UNCHANGED"));
dcpTemperatures[0] = 0;
dcpTemperatures[1] = 0;
- dcpIll->set_active (curr_active);
+ dcpIll->set_active(curr_active);
}
if (dcpIll->get_active_row_number() == -1 && dcpIlluminant == -1) {
@@ -384,22 +383,22 @@ void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
dcpIll->set_active(dcpIlluminant);
}
- dcpIll->set_sensitive (true);
- dcpIllLabel->set_sensitive (true);
+ dcpIll->set_sensitive(true);
+ dcpIllLabel->set_sensitive(true);
return;
}
- ckbToneCurve->set_sensitive (false);
- ckbApplyLookTable->set_sensitive (false);
- ckbApplyBaselineExposureOffset->set_sensitive (false);
- ckbApplyHueSatMap->set_sensitive (false);
- dcpIllLabel->set_sensitive (false);
- dcpIll->set_sensitive (false);
+ ckbToneCurve->set_sensitive(false);
+ ckbApplyLookTable->set_sensitive(false);
+ ckbApplyBaselineExposureOffset->set_sensitive(false);
+ ckbApplyHueSatMap->set_sensitive(false);
+ dcpIllLabel->set_sensitive(false);
+ dcpIll->set_sensitive(false);
dcpFrame->set_sensitive(false);
DCPProfile* dcp = nullptr;
- if(dcp_name == "(cameraICC)") {
+ if (dcp_name == "(cameraICC)") {
dcp = DCPStore::getInstance()->getStdProfile(camName);
} else if (ifromfile->get_active() && DCPStore::getInstance()->isValidDCPFileName(dcp_name)) {
dcp = DCPStore::getInstance()->getProfile(dcp_name);
@@ -409,19 +408,19 @@ void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
dcpFrame->set_sensitive(true);
if (dcp->getHasToneCurve()) {
- ckbToneCurve->set_sensitive (true);
+ ckbToneCurve->set_sensitive(true);
}
if (dcp->getHasLookTable()) {
- ckbApplyLookTable->set_sensitive (true);
+ ckbApplyLookTable->set_sensitive(true);
}
if (dcp->getHasBaselineExposureOffset()) {
- ckbApplyBaselineExposureOffset->set_sensitive (true);
+ ckbApplyBaselineExposureOffset->set_sensitive(true);
}
if (dcp->getHasHueSatMap()) {
- ckbApplyHueSatMap->set_sensitive (true);
+ ckbApplyHueSatMap->set_sensitive(true);
}
const DCPProfile::Illuminants illuminants = dcp->getIlluminants();
@@ -432,13 +431,13 @@ void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
sprintf(tempstr1, "%.0fK", illuminants.temperature_1);
sprintf(tempstr2, "%.0fK", illuminants.temperature_2);
int curr_active = dcpIll->get_active_row_number();
- dcpIll->remove_all ();
- dcpIll->append (M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
- dcpIll->append (tempstr1);
- dcpIll->append (tempstr2);
+ dcpIll->remove_all();
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
+ dcpIll->append(tempstr1);
+ dcpIll->append(tempstr2);
dcpTemperatures[0] = illuminants.temperature_1;
dcpTemperatures[1] = illuminants.temperature_2;
- dcpIll->set_active (curr_active);
+ dcpIll->set_active(curr_active);
}
if (dcpIlluminant > 2) {
@@ -451,8 +450,8 @@ void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
dcpIll->set_active(dcpIlluminant);
}
- dcpIll->set_sensitive (true);
- dcpIllLabel->set_sensitive (true);
+ dcpIll->set_sensitive(true);
+ dcpIllLabel->set_sensitive(true);
} else {
if (dcpIll->get_active_row_number() != -1) {
dcpIll->set_active(-1);
@@ -463,270 +462,269 @@ void ICMPanel::updateDCP (int dcpIlluminant, Glib::ustring dcp_name)
if (!dcpIllLabel->get_sensitive() && dcpIll->get_active_row_number() != 0) {
if (dcpTemperatures[0] != 0 || dcpTemperatures[1] != 0) {
int curr_active = dcpIll->get_active_row_number();
- dcpIll->remove_all ();
- dcpIll->append (M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 1");
- dcpIll->append (M("TP_ICM_DCPILLUMINANT") + " 2");
+ dcpIll->remove_all();
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT_INTERPOLATED"));
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 1");
+ dcpIll->append(M("TP_ICM_DCPILLUMINANT") + " 2");
if (isBatchMode) {
- dcpIll->append (M("GENERAL_UNCHANGED"));
+ dcpIll->append(M("GENERAL_UNCHANGED"));
}
dcpTemperatures[0] = 0;
dcpTemperatures[1] = 0;
- dcpIll->set_active (curr_active);
+ dcpIll->set_active(curr_active);
}
}
}
-void ICMPanel::read (const ProcParams* pp, const ParamsEdited* pedited)
+void ICMPanel::read(const ProcParams* pp, const ParamsEdited* pedited)
{
- disableListener ();
+ disableListener();
ConnectionBlocker obpcconn_(obpcconn);
ConnectionBlocker ipc_(ipc);
- ConnectionBlocker gamcsconn_(gamcsconn);
ConnectionBlocker tcurveconn_(tcurveconn);
ConnectionBlocker ltableconn_(ltableconn);
ConnectionBlocker beoconn_(beoconn);
ConnectionBlocker hsmconn_(hsmconn);
- ConnectionBlocker wnamesconn_(wnamesconn);
- ConnectionBlocker onamesconn_(onamesconn);
- ConnectionBlocker ointentconn_(ointentconn);
- ConnectionBlocker wgammaconn_(wgammaconn);
+ ConnectionBlocker wprofnamesconn_(wprofnamesconn);
+ ConnectionBlocker oprofnamesconn_(oprofnamesconn);
+ ConnectionBlocker orendintentconn_(orendintentconn);
ConnectionBlocker dcpillconn_(dcpillconn);
- if(pp->icm.input.substr(0, 5) != "file:" && !ipDialog->get_filename().empty()) {
- ipDialog->set_filename(pp->icm.input);
+ if (pp->icm.inputProfile.substr(0, 5) != "file:" && !ipDialog->get_filename().empty()) {
+ ipDialog->set_filename(pp->icm.inputProfile);
}
- if (pp->icm.input == "(none)") {
- inone->set_active (true);
+ if (pp->icm.inputProfile == "(none)") {
+ inone->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "");
- } else if (pp->icm.input == "(embedded)" || ((pp->icm.input == "(camera)" || pp->icm.input == "") && icamera->get_state() == Gtk::STATE_INSENSITIVE)) {
- iembedded->set_active (true);
+ } else if (pp->icm.inputProfile == "(embedded)" || ((pp->icm.inputProfile == "(camera)" || pp->icm.inputProfile == "") && icamera->get_state() == Gtk::STATE_INSENSITIVE)) {
+ iembedded->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "");
- } else if ((pp->icm.input == "(cameraICC)") && icameraICC->get_state() != Gtk::STATE_INSENSITIVE) {
- icameraICC->set_active (true);
+ } else if ((pp->icm.inputProfile == "(cameraICC)") && icameraICC->get_state() != Gtk::STATE_INSENSITIVE) {
+ icameraICC->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "(cameraICC)");
- } else if ((pp->icm.input == "(cameraICC)") && icamera->get_state() != Gtk::STATE_INSENSITIVE && icameraICC->get_state() == Gtk::STATE_INSENSITIVE) {
+ } else if ((pp->icm.inputProfile == "(cameraICC)") && icamera->get_state() != Gtk::STATE_INSENSITIVE && icameraICC->get_state() == Gtk::STATE_INSENSITIVE) {
// this is the case when (cameraICC) is instructed by packaged profiles, but ICC file is not found
// therefore falling back UI to explicitly reflect the (camera) option
- icamera->set_active (true);
+ icamera->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "");
- } else if ((pp->icm.input == "(cameraICC)") && icamera->get_state() == Gtk::STATE_INSENSITIVE && icameraICC->get_state() == Gtk::STATE_INSENSITIVE) {
+ } else if ((pp->icm.inputProfile == "(cameraICC)") && icamera->get_state() == Gtk::STATE_INSENSITIVE && icameraICC->get_state() == Gtk::STATE_INSENSITIVE) {
// If neither (camera) nor (cameraICC) are available, as is the case when loading a non-raw, activate (embedded).
- iembedded->set_active (true);
+ iembedded->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "(cameraICC)");
- } else if ((pp->icm.input == "(camera)" || pp->icm.input == "") && icamera->get_state() != Gtk::STATE_INSENSITIVE) {
- icamera->set_active (true);
+ } else if ((pp->icm.inputProfile == "(camera)" || pp->icm.inputProfile == "") && icamera->get_state() != Gtk::STATE_INSENSITIVE) {
+ icamera->set_active(true);
updateDCP(pp->icm.dcpIlluminant, "");
} else {
- ifromfile->set_active (true);
- oldip = pp->icm.input.substr(5); // cut of "file:"
- ipDialog->set_filename (pp->icm.input.substr(5));
- updateDCP(pp->icm.dcpIlluminant, pp->icm.input.substr(5));
+ ifromfile->set_active(true);
+ oldip = pp->icm.inputProfile.substr(5); // cut of "file:"
+ ipDialog->set_filename(pp->icm.inputProfile.substr(5));
+ updateDCP(pp->icm.dcpIlluminant, pp->icm.inputProfile.substr(5));
}
- wnames->set_active_text (pp->icm.working);
- wgamma->set_active_text (pp->icm.gamma);
+ wProfNames->set_active_text(pp->icm.workingProfile);
- if (pp->icm.output == ColorManagementParams::NoICMString) {
- onames->set_active_text (M("TP_ICM_NOICM"));
+ if (pp->icm.workingTRC == "none") {
+ wTRC->set_active(0);
+ } else if (pp->icm.workingTRC == "Custom") {
+ wTRC->set_active(1);
+ }
+
+ wtrcinChanged();
+
+ if (pp->icm.outputProfile == ColorManagementParams::NoICMString) {
+ oProfNames->set_active_text(M("TP_ICM_NOICM"));
} else {
- onames->set_active_text (pp->icm.output);
+ oProfNames->set_active_text(pp->icm.outputProfile);
}
- if (onames->get_active_row_number() == -1) {
- onames->set_active_text (M("TP_ICM_NOICM"));
+ if (oProfNames->get_active_row_number() == -1) {
+ oProfNames->set_active_text(M("TP_ICM_NOICM"));
}
- ointent->setSelected (pp->icm.outputIntent);
- obpc->set_active (pp->icm.outputBPC);
- ckbToneCurve->set_active (pp->icm.toneCurve);
+ oRendIntent->setSelected(pp->icm.outputIntent);
+
+ obpc->set_active(pp->icm.outputBPC);
+ ckbToneCurve->set_active(pp->icm.toneCurve);
lastToneCurve = pp->icm.toneCurve;
- ckbApplyLookTable->set_active (pp->icm.applyLookTable);
+ ckbApplyLookTable->set_active(pp->icm.applyLookTable);
lastApplyLookTable = pp->icm.applyLookTable;
- ckbApplyBaselineExposureOffset->set_active (pp->icm.applyBaselineExposureOffset);
+ ckbApplyBaselineExposureOffset->set_active(pp->icm.applyBaselineExposureOffset);
lastApplyBaselineExposureOffset = pp->icm.applyBaselineExposureOffset;
- ckbApplyHueSatMap->set_active (pp->icm.applyHueSatMap);
+ ckbApplyHueSatMap->set_active(pp->icm.applyHueSatMap);
lastApplyHueSatMap = pp->icm.applyHueSatMap;
- freegamma->set_active (pp->icm.freegamma);
- lastgamfree = pp->icm.freegamma;
-
- if (!batchMode) {
- onames->set_sensitive(wgamma->get_active_row_number() == 0 && !pp->icm.freegamma); //"default"
- wgamma->set_sensitive(!pp->icm.freegamma);
- gampos->set_sensitive(pp->icm.freegamma);
- slpos->set_sensitive(pp->icm.freegamma);
- updateRenderingIntent(pp->icm.output);
- }
-
- gampos->setValue (pp->icm.gampos);
- slpos->setValue (pp->icm.slpos);
+ wGamma->setValue(pp->icm.workingTRCGamma);
+ wSlope->setValue(pp->icm.workingTRCSlope);
if (pedited) {
- iunchanged->set_active (!pedited->icm.input);
+ iunchanged->set_active(!pedited->icm.inputProfile);
obpc->set_inconsistent(!pedited->icm.outputBPC);
ckbToneCurve->set_inconsistent(!pedited->icm.toneCurve);
ckbApplyLookTable->set_inconsistent(!pedited->icm.applyLookTable);
ckbApplyBaselineExposureOffset->set_inconsistent(!pedited->icm.applyBaselineExposureOffset);
ckbApplyHueSatMap->set_inconsistent(!pedited->icm.applyHueSatMap);
- freegamma->set_inconsistent (!pedited->icm.freegamma);
- if (!pedited->icm.working) {
- wnames->set_active_text(M("GENERAL_UNCHANGED"));
+ if (!pedited->icm.workingProfile) {
+ wProfNames->set_active_text(M("GENERAL_UNCHANGED"));
}
- if (!pedited->icm.output) {
- onames->set_active_text(M("GENERAL_UNCHANGED"));
+ if (!pedited->icm.outputProfile) {
+ oProfNames->set_active_text(M("GENERAL_UNCHANGED"));
}
if (!pedited->icm.outputIntent) {
- ointent->setSelected (4);
+ oRendIntent->setSelected(4);
}
if (!pedited->icm.dcpIlluminant) {
dcpIll->set_active_text(M("GENERAL_UNCHANGED"));
}
- if (!pedited->icm.gamma) {
- wgamma->set_active_text(M("GENERAL_UNCHANGED"));
- wgamma->set_active_text(M("GENERAL_UNCHANGED"));
+ if (!pedited->icm.workingTRC) {
+ wTRC->set_active_text(M("GENERAL_UNCHANGED"));
}
- gampos->setEditedState (pedited->icm.gampos ? Edited : UnEdited);
- slpos->setEditedState (pedited->icm.slpos ? Edited : UnEdited);
+ wGamma->setEditedState(pedited->icm.workingTRCGamma ? Edited : UnEdited);
+ wSlope->setEditedState(pedited->icm.workingTRCSlope ? Edited : UnEdited);
}
- enableListener ();
+ enableListener();
}
-void ICMPanel::write (ProcParams* pp, ParamsEdited* pedited)
+void ICMPanel::write(ProcParams* pp, ParamsEdited* pedited)
{
if (inone->get_active()) {
- pp->icm.input = "(none)";
- } else if (iembedded->get_active ()) {
- pp->icm.input = "(embedded)";
- } else if (icamera->get_active ()) {
- pp->icm.input = "(camera)";
- } else if (icameraICC->get_active ()) {
- pp->icm.input = "(cameraICC)";
+ pp->icm.inputProfile = "(none)";
+ } else if (iembedded->get_active()) {
+ pp->icm.inputProfile = "(embedded)";
+ } else if (icamera->get_active()) {
+ pp->icm.inputProfile = "(camera)";
+ } else if (icameraICC->get_active()) {
+ pp->icm.inputProfile = "(cameraICC)";
} else {
- if (Glib::file_test (ipDialog->get_filename (), Glib::FILE_TEST_EXISTS) && !Glib::file_test (ipDialog->get_filename (), Glib::FILE_TEST_IS_DIR)) {
- pp->icm.input = "file:" + ipDialog->get_filename ();
+ if (Glib::file_test(ipDialog->get_filename(), Glib::FILE_TEST_EXISTS) && !Glib::file_test(ipDialog->get_filename(), Glib::FILE_TEST_IS_DIR)) {
+ pp->icm.inputProfile = "file:" + ipDialog->get_filename();
} else {
- pp->icm.input = ""; // just a directory
+ pp->icm.inputProfile = ""; // just a directory
}
- Glib::ustring p = Glib::path_get_dirname(ipDialog->get_filename ());
+ Glib::ustring p = Glib::path_get_dirname(ipDialog->get_filename());
}
- pp->icm.working = wnames->get_active_text ();
- pp->icm.gamma = wgamma->get_active_text ();
+ pp->icm.workingProfile = wProfNames->get_active_text();
pp->icm.dcpIlluminant = rtengine::max(dcpIll->get_active_row_number(), 0);
+ pp->icm.workingTRC = wTRC->get_active_text();
- if (onames->get_active_text() == M("TP_ICM_NOICM")) {
- pp->icm.output = ColorManagementParams::NoICMString;
+ if (oProfNames->get_active_text() == M("TP_ICM_NOICM")) {
+ pp->icm.outputProfile = ColorManagementParams::NoICMString;
} else {
- pp->icm.output = onames->get_active_text();
+ pp->icm.outputProfile = oProfNames->get_active_text();
}
- int ointentVal = ointent->getSelected ();
+ int ointentVal = oRendIntent->getSelected();
+
if (ointentVal >= 0 && ointentVal < RI__COUNT) {
pp->icm.outputIntent = static_cast(ointentVal);
} else {
pp->icm.outputIntent = rtengine::RI_RELATIVE;
}
- pp->icm.freegamma = freegamma->get_active();
- pp->icm.toneCurve = ckbToneCurve->get_active ();
- pp->icm.applyLookTable = ckbApplyLookTable->get_active ();
- pp->icm.applyBaselineExposureOffset = ckbApplyBaselineExposureOffset->get_active ();
- pp->icm.applyHueSatMap = ckbApplyHueSatMap->get_active ();
- pp->icm.gampos = (double) gampos->getValue();
- pp->icm.slpos = (double) slpos->getValue();
- pp->icm.outputBPC = obpc->get_active ();
+ if (wTRC->get_active_row_number() == 0) {
+ pp->icm.workingTRC = "none";
+ } else if (wTRC->get_active_row_number() == 1) {
+ pp->icm.workingTRC = "Custom";
+ }
+
+ pp->icm.toneCurve = ckbToneCurve->get_active();
+ pp->icm.applyLookTable = ckbApplyLookTable->get_active();
+ pp->icm.applyBaselineExposureOffset = ckbApplyBaselineExposureOffset->get_active();
+ pp->icm.applyHueSatMap = ckbApplyHueSatMap->get_active();
+ pp->icm.outputBPC = obpc->get_active();
+ pp->icm.workingTRCGamma = (double) wGamma->getValue();
+ pp->icm.workingTRCSlope = (double) wSlope->getValue();
pp->toneCurve.fromHistMatching = false;
if (pedited) {
- pedited->icm.input = !iunchanged->get_active ();
- pedited->icm.working = wnames->get_active_text() != M("GENERAL_UNCHANGED");
- pedited->icm.output = onames->get_active_text() != M("GENERAL_UNCHANGED");
- pedited->icm.outputIntent = ointent->getSelected () < 4;
- pedited->icm.outputBPC = !obpc->get_inconsistent ();
+ pedited->icm.inputProfile = !iunchanged->get_active();
+ pedited->icm.workingProfile = wProfNames->get_active_text() != M("GENERAL_UNCHANGED");
+ pedited->icm.outputProfile = oProfNames->get_active_text() != M("GENERAL_UNCHANGED");
+ pedited->icm.outputIntent = oRendIntent->getSelected() < 4;
+ pedited->icm.outputBPC = !obpc->get_inconsistent();
pedited->icm.dcpIlluminant = dcpIll->get_active_text() != M("GENERAL_UNCHANGED");
- pedited->icm.toneCurve = !ckbToneCurve->get_inconsistent ();
- pedited->icm.applyLookTable = !ckbApplyLookTable->get_inconsistent ();
- pedited->icm.applyBaselineExposureOffset = !ckbApplyBaselineExposureOffset->get_inconsistent ();
- pedited->icm.applyHueSatMap = !ckbApplyHueSatMap->get_inconsistent ();
- pedited->icm.gamma = wgamma->get_active_text() != M("GENERAL_UNCHANGED");
- pedited->icm.freegamma = !freegamma->get_inconsistent();
- pedited->icm.gampos = gampos->getEditedState ();
- pedited->icm.slpos = slpos->getEditedState ();
+ pedited->icm.toneCurve = !ckbToneCurve->get_inconsistent();
+ pedited->icm.applyLookTable = !ckbApplyLookTable->get_inconsistent();
+ pedited->icm.applyBaselineExposureOffset = !ckbApplyBaselineExposureOffset->get_inconsistent();
+ pedited->icm.applyHueSatMap = !ckbApplyHueSatMap->get_inconsistent();
+ pedited->icm.workingTRCGamma = wGamma->getEditedState();
+ pedited->icm.workingTRCSlope = wSlope->getEditedState();
+ pedited->icm.workingTRC = wTRC->get_active_text() != M("GENERAL_UNCHANGED");
}
}
-void ICMPanel::setDefaults (const ProcParams* defParams, const ParamsEdited* pedited)
+void ICMPanel::setDefaults(const ProcParams* defParams, const ParamsEdited* pedited)
{
- gampos->setDefault (defParams->icm.gampos);
- slpos->setDefault (defParams->icm.slpos);
+ wGamma->setDefault(defParams->icm.workingTRCGamma);
+ wSlope->setDefault(defParams->icm.workingTRCSlope);
if (pedited) {
- gampos->setDefaultEditedState (pedited->icm.gampos ? Edited : UnEdited);
- slpos->setDefaultEditedState (pedited->icm.slpos ? Edited : UnEdited);
+ wGamma->setDefaultEditedState(pedited->icm.workingTRCGamma ? Edited : UnEdited);
+ wSlope->setDefaultEditedState(pedited->icm.workingTRCSlope ? Edited : UnEdited);
+
} else {
- gampos->setDefaultEditedState (Irrelevant);
- slpos->setDefaultEditedState (Irrelevant);
+ wGamma->setDefaultEditedState(Irrelevant);
+ wSlope->setDefaultEditedState(Irrelevant);
+
}
}
-void ICMPanel::setAdjusterBehavior (bool gammaadd, bool slopeadd)
+void ICMPanel::adjusterChanged(Adjuster* a, double newval)
{
- gampos->setAddMode (gammaadd);
- slpos->setAddMode (slopeadd);
-}
+ if (listener || batchMode) {
+ Glib::ustring costr2 = Glib::ustring::format(std::setw(3), std::fixed, std::setprecision(2), newval);
-void ICMPanel::adjusterChanged (Adjuster* a, double newval)
-{
-
- if (listener && (freegamma->get_active() || batchMode)) {
-
- Glib::ustring costr = Glib::ustring::format (std::setw(3), std::fixed, std::setprecision(2), newval);
-
- if (a == gampos) {
- listener->panelChanged (EvGAMPOS, costr);
- } else if (a == slpos) {
- listener->panelChanged (EvSLPOS, costr);
+ if (a == wGamma) {
+ listener->panelChanged(EvICMgamm, costr2);
+ } else if (a == wSlope) {
+ listener->panelChanged(EvICMslop, costr2);
}
+
}
}
-void ICMPanel::wpChanged ()
+void ICMPanel::wpChanged()
{
-
if (listener) {
- listener->panelChanged (EvWProfile, wnames->get_active_text ());
+ listener->panelChanged(EvWProfile, wProfNames->get_active_text());
}
}
-void ICMPanel::gpChanged ()
+void ICMPanel::wtrcinChanged()
{
+ if (wTRC->get_active_row_number() == 0) {
+ wGamma->set_sensitive(false);
+ wSlope->set_sensitive(false);
+
+ } else {
+ wGamma->set_sensitive(true);
+ wSlope->set_sensitive(true);
+ }
if (listener) {
- listener->panelChanged (EvGAMMA, wgamma->get_active_text ());
- onames->set_sensitive(wgamma->get_active_row_number() == 0); //"default"
+ listener->panelChanged(EvICMtrcinMethod, wTRC->get_active_text());
}
}
void ICMPanel::dcpIlluminantChanged()
{
if (listener) {
- listener->panelChanged (EvDCPIlluminant, dcpIll->get_active_text ());
+ listener->panelChanged(EvDCPIlluminant, dcpIll->get_active_text());
}
}
@@ -734,24 +732,24 @@ void ICMPanel::toneCurveChanged()
{
if (multiImage) {
if (ckbToneCurve->get_inconsistent()) {
- ckbToneCurve->set_inconsistent (false);
- tcurveconn.block (true);
- ckbToneCurve->set_active (false);
- tcurveconn.block (false);
+ ckbToneCurve->set_inconsistent(false);
+ tcurveconn.block(true);
+ ckbToneCurve->set_active(false);
+ tcurveconn.block(false);
} else if (lastToneCurve) {
- ckbToneCurve->set_inconsistent (true);
+ ckbToneCurve->set_inconsistent(true);
}
- lastToneCurve = ckbToneCurve->get_active ();
+ lastToneCurve = ckbToneCurve->get_active();
}
if (listener) {
if (ckbToneCurve->get_inconsistent()) {
- listener->panelChanged (EvDCPToneCurve, M("GENERAL_UNCHANGED"));
+ listener->panelChanged(EvDCPToneCurve, M("GENERAL_UNCHANGED"));
} else if (ckbToneCurve->get_active()) {
- listener->panelChanged (EvDCPToneCurve, M("GENERAL_ENABLED"));
+ listener->panelChanged(EvDCPToneCurve, M("GENERAL_ENABLED"));
} else {
- listener->panelChanged (EvDCPToneCurve, M("GENERAL_DISABLED"));
+ listener->panelChanged(EvDCPToneCurve, M("GENERAL_DISABLED"));
}
}
}
@@ -760,24 +758,24 @@ void ICMPanel::applyLookTableChanged()
{
if (multiImage) {
if (ckbApplyLookTable->get_inconsistent()) {
- ckbApplyLookTable->set_inconsistent (false);
- ltableconn.block (true);
- ckbApplyLookTable->set_active (false);
- ltableconn.block (false);
+ ckbApplyLookTable->set_inconsistent(false);
+ ltableconn.block(true);
+ ckbApplyLookTable->set_active(false);
+ ltableconn.block(false);
} else if (lastApplyLookTable) {
- ckbApplyLookTable->set_inconsistent (true);
+ ckbApplyLookTable->set_inconsistent(true);
}
- lastApplyLookTable = ckbApplyLookTable->get_active ();
+ lastApplyLookTable = ckbApplyLookTable->get_active();
}
if (listener) {
if (ckbApplyLookTable->get_inconsistent()) {
- listener->panelChanged (EvDCPApplyLookTable, M("GENERAL_UNCHANGED"));
+ listener->panelChanged(EvDCPApplyLookTable, M("GENERAL_UNCHANGED"));
} else if (ckbApplyLookTable->get_active()) {
- listener->panelChanged (EvDCPApplyLookTable, M("GENERAL_ENABLED"));
+ listener->panelChanged(EvDCPApplyLookTable, M("GENERAL_ENABLED"));
} else {
- listener->panelChanged (EvDCPApplyLookTable, M("GENERAL_DISABLED"));
+ listener->panelChanged(EvDCPApplyLookTable, M("GENERAL_DISABLED"));
}
}
}
@@ -786,24 +784,24 @@ void ICMPanel::applyBaselineExposureOffsetChanged()
{
if (multiImage) {
if (ckbApplyBaselineExposureOffset->get_inconsistent()) {
- ckbApplyBaselineExposureOffset->set_inconsistent (false);
- beoconn.block (true);
- ckbApplyBaselineExposureOffset->set_active (false);
- beoconn.block (false);
+ ckbApplyBaselineExposureOffset->set_inconsistent(false);
+ beoconn.block(true);
+ ckbApplyBaselineExposureOffset->set_active(false);
+ beoconn.block(false);
} else if (lastApplyBaselineExposureOffset) {
- ckbApplyBaselineExposureOffset->set_inconsistent (true);
+ ckbApplyBaselineExposureOffset->set_inconsistent(true);
}
- lastApplyBaselineExposureOffset = ckbApplyBaselineExposureOffset->get_active ();
+ lastApplyBaselineExposureOffset = ckbApplyBaselineExposureOffset->get_active();
}
if (listener) {
if (ckbApplyBaselineExposureOffset->get_inconsistent()) {
- listener->panelChanged (EvDCPApplyBaselineExposureOffset, M("GENERAL_UNCHANGED"));
+ listener->panelChanged(EvDCPApplyBaselineExposureOffset, M("GENERAL_UNCHANGED"));
} else if (ckbApplyBaselineExposureOffset->get_active()) {
- listener->panelChanged (EvDCPApplyBaselineExposureOffset, M("GENERAL_ENABLED"));
+ listener->panelChanged(EvDCPApplyBaselineExposureOffset, M("GENERAL_ENABLED"));
} else {
- listener->panelChanged (EvDCPApplyBaselineExposureOffset, M("GENERAL_DISABLED"));
+ listener->panelChanged(EvDCPApplyBaselineExposureOffset, M("GENERAL_DISABLED"));
}
}
}
@@ -812,170 +810,137 @@ void ICMPanel::applyHueSatMapChanged()
{
if (multiImage) {
if (ckbApplyHueSatMap->get_inconsistent()) {
- ckbApplyHueSatMap->set_inconsistent (false);
- hsmconn.block (true);
- ckbApplyHueSatMap->set_active (false);
- hsmconn.block (false);
+ ckbApplyHueSatMap->set_inconsistent(false);
+ hsmconn.block(true);
+ ckbApplyHueSatMap->set_active(false);
+ hsmconn.block(false);
} else if (lastApplyHueSatMap) {
- ckbApplyHueSatMap->set_inconsistent (true);
+ ckbApplyHueSatMap->set_inconsistent(true);
}
- lastApplyHueSatMap = ckbApplyHueSatMap->get_active ();
+ lastApplyHueSatMap = ckbApplyHueSatMap->get_active();
}
if (listener) {
if (ckbApplyHueSatMap->get_inconsistent()) {
- listener->panelChanged (EvDCPApplyHueSatMap, M("GENERAL_UNCHANGED"));
+ listener->panelChanged(EvDCPApplyHueSatMap, M("GENERAL_UNCHANGED"));
} else if (ckbApplyHueSatMap->get_active()) {
- listener->panelChanged (EvDCPApplyHueSatMap, M("GENERAL_ENABLED"));
+ listener->panelChanged(EvDCPApplyHueSatMap, M("GENERAL_ENABLED"));
} else {
- listener->panelChanged (EvDCPApplyHueSatMap, M("GENERAL_DISABLED"));
+ listener->panelChanged(EvDCPApplyHueSatMap, M("GENERAL_DISABLED"));
}
}
}
-void ICMPanel::ipChanged ()
+void ICMPanel::ipChanged()
{
Glib::ustring profname;
if (inone->get_active()) {
profname = "(none)";
- } else if (iembedded->get_active ()) {
+ } else if (iembedded->get_active()) {
profname = "(embedded)";
- } else if (icamera->get_active ()) {
+ } else if (icamera->get_active()) {
profname = "(camera)";
- } else if (icameraICC->get_active ()) {
+ } else if (icameraICC->get_active()) {
profname = "(cameraICC)";
} else {
- profname = ipDialog->get_filename ();
+ profname = ipDialog->get_filename();
}
updateDCP(-1, profname);
if (listener && profname != oldip) {
- listener->panelChanged (EvIProfile, profname);
+ listener->panelChanged(EvIProfile, profname);
}
oldip = profname;
}
-void ICMPanel::GamChanged()
-{
- if (multiImage) {
- if (freegamma->get_inconsistent()) {
- freegamma->set_inconsistent (false);
- gamcsconn.block (true);
- freegamma->set_active (false);
- gamcsconn.block (false);
- } else if (lastgamfree) {
- freegamma->set_inconsistent (true);
- }
-
- lastgamfree = freegamma->get_active ();
- }
-
- if (listener) {
- if (freegamma->get_inconsistent()) {
- listener->panelChanged (EvGAMFREE, M("GENERAL_UNCHANGED"));
- }
- else if (freegamma->get_active()) {
- listener->panelChanged (EvGAMFREE, M("GENERAL_ENABLED"));
- if (!batchMode) {
- onames->set_sensitive(false);//disabled choice
- wgamma->set_sensitive(false);
- gampos->set_sensitive(true);
- slpos->set_sensitive(true);
- }
- } else {
- listener->panelChanged (EvGAMFREE, M("GENERAL_DISABLED"));
- if (!batchMode) {
- onames->set_sensitive(wgamma->get_active_row_number() == 0);
- wgamma->set_sensitive(true);
- gampos->set_sensitive(false);
- slpos->set_sensitive(false);
- }
- }
- }
-}
-
-void ICMPanel::opChanged ()
+void ICMPanel::opChanged()
{
if (!batchMode) {
- updateRenderingIntent(onames->get_active_text());
+ updateRenderingIntent(oProfNames->get_active_text());
}
if (listener) {
- listener->panelChanged (EvOProfile, onames->get_active_text());
+ listener->panelChanged(EvOProfile, oProfNames->get_active_text());
}
}
-void ICMPanel::oiChanged (int n)
+void ICMPanel::oiChanged(int n)
{
if (listener) {
Glib::ustring str;
+
switch (n) {
- case 0:
- str = M("PREFERENCES_INTENT_PERCEPTUAL");
- break;
- case 1:
- str = M("PREFERENCES_INTENT_RELATIVE");
- break;
- case 2:
- str = M("PREFERENCES_INTENT_SATURATION");
- break;
- case 3:
- str = M("PREFERENCES_INTENT_ABSOLUTE");
- break;
- case 4:
- default:
- str = M("GENERAL_UNCHANGED");
- break;
+ case 0:
+ str = M("PREFERENCES_INTENT_PERCEPTUAL");
+ break;
+
+ case 1:
+ str = M("PREFERENCES_INTENT_RELATIVE");
+ break;
+
+ case 2:
+ str = M("PREFERENCES_INTENT_SATURATION");
+ break;
+
+ case 3:
+ str = M("PREFERENCES_INTENT_ABSOLUTE");
+ break;
+
+ case 4:
+ default:
+ str = M("GENERAL_UNCHANGED");
+ break;
}
- listener->panelChanged (EvOIntent, str);
+
+ listener->panelChanged(EvOIntent, str);
}
}
-void ICMPanel::oBPCChanged ()
+void ICMPanel::oBPCChanged()
{
if (multiImage) {
if (obpc->get_inconsistent()) {
- obpc->set_inconsistent (false);
- obpcconn.block (true);
- obpc->set_active (false);
- obpcconn.block (false);
+ obpc->set_inconsistent(false);
+ obpcconn.block(true);
+ obpc->set_active(false);
+ obpcconn.block(false);
} else if (lastobpc) {
- obpc->set_inconsistent (true);
+ obpc->set_inconsistent(true);
}
- lastobpc = obpc->get_active ();
+ lastobpc = obpc->get_active();
}
if (listener) {
if (obpc->get_inconsistent()) {
- listener->panelChanged (EvOBPCompens, M("GENERAL_UNCHANGED"));
+ listener->panelChanged(EvOBPCompens, M("GENERAL_UNCHANGED"));
} else if (obpc->get_active()) {
- listener->panelChanged (EvOBPCompens, M("GENERAL_ENABLED"));
+ listener->panelChanged(EvOBPCompens, M("GENERAL_ENABLED"));
} else {
- listener->panelChanged (EvOBPCompens, M("GENERAL_DISABLED"));
+ listener->panelChanged(EvOBPCompens, M("GENERAL_DISABLED"));
}
}
}
-void ICMPanel::setRawMeta (bool raw, const rtengine::FramesData* pMeta)
+void ICMPanel::setRawMeta(bool raw, const rtengine::FramesData* pMeta)
{
- disableListener ();
+ disableListener();
- icamera->set_active (raw);
- iembedded->set_active (!raw);
- icamera->set_sensitive (raw);
+ icamera->set_active(raw);
+ iembedded->set_active(!raw);
+ icamera->set_sensitive(raw);
camName = pMeta->getCamera();
- icameraICC->set_sensitive (raw && (ICCStore::getInstance()->getStdProfile(pMeta->getCamera()) != nullptr || DCPStore::getInstance()->getStdProfile(pMeta->getCamera()) != nullptr));
- iembedded->set_sensitive (!raw);
+ icameraICC->set_sensitive(raw && (ICCStore::getInstance()->getStdProfile(pMeta->getCamera()) != nullptr || DCPStore::getInstance()->getStdProfile(pMeta->getCamera()) != nullptr));
+ iembedded->set_sensitive(!raw);
- enableListener ();
+ enableListener();
}
void ICMPanel::ipSelectionChanged()
@@ -988,23 +953,23 @@ void ICMPanel::ipSelectionChanged()
ipChanged();
}
-void ICMPanel::saveReferencePressed ()
+void ICMPanel::saveReferencePressed()
{
if (!icmplistener) {
return;
}
- Gtk::FileChooserDialog dialog (getToplevelWindow (this), M("TP_ICM_SAVEREFERENCE"), Gtk::FILE_CHOOSER_ACTION_SAVE);
- bindCurrentFolder (dialog, options.lastProfilingReferenceDir);
- dialog.set_current_name (lastRefFilename);
+ Gtk::FileChooserDialog dialog(getToplevelWindow(this), M("TP_ICM_SAVEREFERENCE"), Gtk::FILE_CHOOSER_ACTION_SAVE);
+ bindCurrentFolder(dialog, options.lastProfilingReferenceDir);
+ dialog.set_current_name(lastRefFilename);
dialog.add_button(M("GENERAL_CANCEL"), Gtk::RESPONSE_CANCEL);
dialog.add_button(M("GENERAL_SAVE"), Gtk::RESPONSE_OK);
Gtk::CheckButton applyWB(M("TP_ICM_SAVEREFERENCE_APPLYWB"));
- applyWB.set_tooltip_text (M("TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP"));
- Gtk::HBox* hbox = Gtk::manage( new Gtk::HBox() );
+ applyWB.set_tooltip_text(M("TP_ICM_SAVEREFERENCE_APPLYWB_TOOLTIP"));
+ Gtk::HBox* hbox = Gtk::manage(new Gtk::HBox());
hbox->pack_end(applyWB, Gtk::PACK_SHRINK, 2);
Gtk::Box *box = dialog.get_content_area();
box->pack_end(*hbox, Gtk::PACK_SHRINK, 2);
@@ -1039,8 +1004,8 @@ void ICMPanel::saveReferencePressed ()
}
if (confirmOverwrite(dialog, fname)) {
- icmplistener->saveInputICCReference (fname, applyWB.get_active());
- lastRefFilename = Glib::path_get_basename (fname);
+ icmplistener->saveInputICCReference(fname, applyWB.get_active());
+ lastRefFilename = Glib::path_get_basename(fname);
done = true;
}
}
@@ -1049,23 +1014,23 @@ void ICMPanel::saveReferencePressed ()
return;
}
-void ICMPanel::setBatchMode (bool batchMode)
+void ICMPanel::setBatchMode(bool batchMode)
{
isBatchMode = true;
- ToolPanel::setBatchMode (batchMode);
- iunchanged = Gtk::manage (new Gtk::RadioButton (M("GENERAL_UNCHANGED")));
- iunchanged->set_group (opts);
- iVBox->pack_start (*iunchanged, Gtk::PACK_SHRINK, 4);
- iVBox->reorder_child (*iunchanged, 5);
- removeIfThere (this, saveRef);
- onames->append (M("GENERAL_UNCHANGED"));
- ointent->addEntry("template-24.png", M("GENERAL_UNCHANGED"));
- ointent->show();
- wnames->append (M("GENERAL_UNCHANGED"));
- wgamma->append (M("GENERAL_UNCHANGED"));
- dcpIll->append (M("GENERAL_UNCHANGED"));
- gampos->showEditedCB ();
- slpos->showEditedCB ();
+ ToolPanel::setBatchMode(batchMode);
+ iunchanged = Gtk::manage(new Gtk::RadioButton(M("GENERAL_UNCHANGED")));
+ iunchanged->set_group(opts);
+ iVBox->pack_start(*iunchanged, Gtk::PACK_SHRINK, 4);
+ iVBox->reorder_child(*iunchanged, 5);
+ removeIfThere(this, saveRef);
+ oProfNames->append(M("GENERAL_UNCHANGED"));
+ oRendIntent->addEntry("template-24.png", M("GENERAL_UNCHANGED"));
+ oRendIntent->show();
+ wProfNames->append(M("GENERAL_UNCHANGED"));
+ wTRC->append(M("GENERAL_UNCHANGED"));
+ dcpIll->append(M("GENERAL_UNCHANGED"));
+ wGamma->showEditedCB();
+ wSlope->showEditedCB();
}
diff --git a/rtgui/icmpanel.h b/rtgui/icmpanel.h
index f8c762b0e..e04a4397e 100644
--- a/rtgui/icmpanel.h
+++ b/rtgui/icmpanel.h
@@ -33,18 +33,26 @@ class ICMPanelListener
public:
virtual ~ICMPanelListener() {}
- virtual void saveInputICCReference (Glib::ustring fname, bool apply_wb) {}
+ virtual void saveInputICCReference(Glib::ustring fname, bool apply_wb) {}
};
-class ICMPanel : public ToolParamBlock, public AdjusterListener, public FoldableToolPanel
+class ICMPanel :
+ public ToolParamBlock,
+ public AdjusterListener,
+ public FoldableToolPanel
{
protected:
- Gtk::Frame* dcpFrame;
- Adjuster* gampos;
- Adjuster* slpos;
- bool lastgamfree;
- sigc::connection gamcsconn;
+ Gtk::Frame* dcpFrame;
+ Gtk::Frame* coipFrame;
+
+ Adjuster* wGamma;
+ Adjuster* wSlope;
+
+ Gtk::Label* labmga;
+ Gtk::HBox* gabox;
+
+
//bool freegamma;
bool lastToneCurve;
sigc::connection tcurveconn;
@@ -59,73 +67,84 @@ protected:
bool isBatchMode;
private:
- Gtk::VBox * iVBox;
+ rtengine::ProcEvent EvICMprimariMethod;
+ rtengine::ProcEvent EvICMprofileMethod;
+ rtengine::ProcEvent EvICMtempMethod;
+ rtengine::ProcEvent EvICMpredx;
+ rtengine::ProcEvent EvICMpredy;
+ rtengine::ProcEvent EvICMpgrex;
+ rtengine::ProcEvent EvICMpgrey;
+ rtengine::ProcEvent EvICMpblux;
+ rtengine::ProcEvent EvICMpbluy;
+ rtengine::ProcEvent EvICMgamm;
+ rtengine::ProcEvent EvICMslop;
+ rtengine::ProcEvent EvICMtrcinMethod;
- Gtk::CheckButton* obpc;
- Gtk::CheckButton* freegamma;
- Gtk::RadioButton* inone;
+ Gtk::VBox* iVBox;
+ Gtk::HBox* wTRCHBox;
- Gtk::RadioButton* iembedded;
- Gtk::RadioButton* icamera;
- Gtk::RadioButton* icameraICC;
- Gtk::RadioButton* ifromfile;
- Gtk::Label* dcpIllLabel;
- MyComboBoxText* dcpIll;
- sigc::connection dcpillconn;
- Gtk::CheckButton* ckbToneCurve;
- Gtk::CheckButton* ckbApplyLookTable;
- Gtk::CheckButton* ckbApplyBaselineExposureOffset;
- Gtk::CheckButton* ckbApplyHueSatMap;
- MyComboBoxText* wnames;
- sigc::connection wnamesconn;
- MyComboBoxText* wgamma;
- sigc::connection wgammaconn;
+ Gtk::CheckButton* obpc;
+ Gtk::RadioButton* inone;
- MyComboBoxText* onames;
- sigc::connection onamesconn;
- std::unique_ptr ointent;
- sigc::connection ointentconn;
- Gtk::RadioButton* iunchanged;
+ Gtk::RadioButton* iembedded;
+ Gtk::RadioButton* icamera;
+ Gtk::RadioButton* icameraICC;
+ Gtk::RadioButton* ifromfile;
+ Gtk::Label* dcpIllLabel;
+ MyComboBoxText* dcpIll;
+ sigc::connection dcpillconn;
+ Gtk::CheckButton* ckbToneCurve;
+ Gtk::CheckButton* ckbApplyLookTable;
+ Gtk::CheckButton* ckbApplyBaselineExposureOffset;
+ Gtk::CheckButton* ckbApplyHueSatMap;
+ MyComboBoxText* wProfNames;
+ sigc::connection wprofnamesconn;
+ MyComboBoxText* wTRC;
+ sigc::connection wtrcconn;
+
+ MyComboBoxText* oProfNames;
+ sigc::connection oprofnamesconn;
+ std::unique_ptr oRendIntent;
+ sigc::connection orendintentconn;
+ Gtk::RadioButton* iunchanged;
MyFileChooserButton* ipDialog;
Gtk::RadioButton::Group opts;
- Gtk::Button* saveRef;
- sigc::connection ipc;
- Glib::ustring oldip;
- ICMPanelListener* icmplistener;
+ Gtk::Button* saveRef;
+ sigc::connection ipc;
+ Glib::ustring oldip;
+ ICMPanelListener* icmplistener;
double dcpTemperatures[2];
Glib::ustring lastRefFilename;
Glib::ustring camName;
void updateDCP(int dcpIlluminant, Glib::ustring dcp_name);
- void updateRenderingIntent (const Glib::ustring &profile);
+ void updateRenderingIntent(const Glib::ustring &profile);
public:
- ICMPanel ();
+ ICMPanel();
- void read (const rtengine::procparams::ProcParams* pp, const ParamsEdited* pedited = nullptr);
- void write (rtengine::procparams::ProcParams* pp, ParamsEdited* pedited = nullptr);
- void setBatchMode (bool batchMode);
- void setDefaults (const rtengine::procparams::ProcParams* defParams, const ParamsEdited* pedited = nullptr);
- void adjusterChanged (Adjuster* a, double newval);
- void setAdjusterBehavior (bool gammaadd, bool slopeadd);
+ void read(const rtengine::procparams::ProcParams* pp, const ParamsEdited* pedited = nullptr);
+ void write(rtengine::procparams::ProcParams* pp, ParamsEdited* pedited = nullptr);
+ void setBatchMode(bool batchMode);
+ void setDefaults(const rtengine::procparams::ProcParams* defParams, const ParamsEdited* pedited = nullptr);
+ void adjusterChanged(Adjuster* a, double newval);
- void wpChanged ();
- void opChanged ();
- void oiChanged (int n);
- void oBPCChanged ();
- void ipChanged ();
- void gpChanged ();
- void GamChanged ();
- void ipSelectionChanged ();
+ void wpChanged();
+ void wtrcinChanged();
+ void opChanged();
+ void oiChanged(int n);
+ void oBPCChanged();
+ void ipChanged();
+ void ipSelectionChanged();
void dcpIlluminantChanged();
void toneCurveChanged();
void applyLookTableChanged();
void applyBaselineExposureOffsetChanged();
void applyHueSatMapChanged();
- void setRawMeta (bool raw, const rtengine::FramesData* pMeta);
- void saveReferencePressed ();
+ void setRawMeta(bool raw, const rtengine::FramesData* pMeta);
+ void saveReferencePressed();
- void setICMPanelListener (ICMPanelListener* ipl)
+ void setICMPanelListener(ICMPanelListener* ipl)
{
icmplistener = ipl;
}
diff --git a/rtgui/options.cc b/rtgui/options.cc
index 1dbaa574e..ea82c80e0 100644
--- a/rtgui/options.cc
+++ b/rtgui/options.cc
@@ -49,16 +49,16 @@ Options options;
Glib::ustring versionString = RTVERSION;
Glib::ustring paramFileExtension = ".pp3";
-Options::Options ()
+Options::Options()
{
defProfError = 0;
- setDefaults ();
+ setDefaults();
}
const char *DefaultLanguage = "English (US)";
-inline bool Options::checkProfilePath (Glib::ustring &path)
+inline bool Options::checkProfilePath(Glib::ustring &path)
{
if (path.empty()) {
return false;
@@ -66,18 +66,18 @@ inline bool Options::checkProfilePath (Glib::ustring &path)
Glib::ustring p = getUserProfilePath();
- if (!p.empty() && Glib::file_test (path + paramFileExtension, Glib::FILE_TEST_EXISTS)) {
+ if (!p.empty() && Glib::file_test(path + paramFileExtension, Glib::FILE_TEST_EXISTS)) {
return true;
}
p = getGlobalProfilePath();
- return !p.empty() && Glib::file_test (path + paramFileExtension, Glib::FILE_TEST_EXISTS);
+ return !p.empty() && Glib::file_test(path + paramFileExtension, Glib::FILE_TEST_EXISTS);
}
-bool Options::checkDirPath (Glib::ustring &path, Glib::ustring errString)
+bool Options::checkDirPath(Glib::ustring &path, Glib::ustring errString)
{
- if (Glib::file_test (path, Glib::FILE_TEST_EXISTS) && Glib::file_test (path, Glib::FILE_TEST_IS_DIR)) {
+ if (Glib::file_test(path, Glib::FILE_TEST_EXISTS) && Glib::file_test(path, Glib::FILE_TEST_IS_DIR)) {
return true;
} else {
if (!errString.empty()) {
@@ -96,53 +96,53 @@ void Options::updatePaths()
userProfilePath = "";
globalProfilePath = "";
- if (Glib::path_is_absolute (profilePath)) {
+ if (Glib::path_is_absolute(profilePath)) {
// absolute path
- if (!checkDirPath (profilePath, "")) {
- g_mkdir_with_parents (profilePath.c_str (), 511);
+ if (!checkDirPath(profilePath, "")) {
+ g_mkdir_with_parents(profilePath.c_str(), 511);
- if (!checkDirPath (profilePath, "")) { // had problems with mkdir_with_parents return value on OS X, just check dir again
- Glib::ustring msg = Glib::ustring::compose ("Creation of the user's processing profile directory \"%1\" failed!\n", profilePath);
- throw Error (msg);
+ if (!checkDirPath(profilePath, "")) { // had problems with mkdir_with_parents return value on OS X, just check dir again
+ Glib::ustring msg = Glib::ustring::compose("Creation of the user's processing profile directory \"%1\" failed!\n", profilePath);
+ throw Error(msg);
}
}
- if (checkDirPath (profilePath, "Error: the user's processing profile path doesn't point to a directory or doesn't exist!\n")) {
+ if (checkDirPath(profilePath, "Error: the user's processing profile path doesn't point to a directory or doesn't exist!\n")) {
userProfilePath = profilePath;
- tmpPath = Glib::build_filename (argv0, "profiles");
+ tmpPath = Glib::build_filename(argv0, "profiles");
- if (checkDirPath (tmpPath, "Error: the global's processing profile path doesn't point to a directory or doesn't exist!\n")) {
+ if (checkDirPath(tmpPath, "Error: the global's processing profile path doesn't point to a directory or doesn't exist!\n")) {
if (userProfilePath != tmpPath) {
globalProfilePath = tmpPath;
}
}
} else {
- tmpPath = Glib::build_filename (argv0, "profiles");
+ tmpPath = Glib::build_filename(argv0, "profiles");
- if (checkDirPath (tmpPath, "Error: the global's processing profile path doesn't point to a directory or doesn't exist!\n")) {
+ if (checkDirPath(tmpPath, "Error: the global's processing profile path doesn't point to a directory or doesn't exist!\n")) {
globalProfilePath = tmpPath;
}
}
} else {
// relative paths
- tmpPath = Glib::build_filename (rtdir, profilePath);
+ tmpPath = Glib::build_filename(rtdir, profilePath);
- if (!checkDirPath (tmpPath, "")) {
- g_mkdir_with_parents (tmpPath.c_str (), 511);
+ if (!checkDirPath(tmpPath, "")) {
+ g_mkdir_with_parents(tmpPath.c_str(), 511);
- if (!checkDirPath (tmpPath, "")) {
- Glib::ustring msg = Glib::ustring::compose ("Creation of the user's processing profile directory \"%1\" failed!\n", tmpPath.c_str());
- throw Error (msg);
+ if (!checkDirPath(tmpPath, "")) {
+ Glib::ustring msg = Glib::ustring::compose("Creation of the user's processing profile directory \"%1\" failed!\n", tmpPath.c_str());
+ throw Error(msg);
}
}
- if (checkDirPath (tmpPath, "Error: the user's processing profile path doesn't point to a directory!\n")) {
+ if (checkDirPath(tmpPath, "Error: the user's processing profile path doesn't point to a directory!\n")) {
userProfilePath = tmpPath;
}
- tmpPath = Glib::build_filename (argv0, "profiles");
+ tmpPath = Glib::build_filename(argv0, "profiles");
- if (checkDirPath (tmpPath, "Error: the user's processing profile path doesn't point to a directory or doesn't exist!\n")) {
+ if (checkDirPath(tmpPath, "Error: the user's processing profile path doesn't point to a directory or doesn't exist!\n")) {
globalProfilePath = tmpPath;
}
}
@@ -150,54 +150,57 @@ void Options::updatePaths()
Glib::ustring preferredPath = getPreferredProfilePath();
// Paths are updated only if the user or global profile path is set
- if (lastRgbCurvesDir.empty() || !Glib::file_test (lastRgbCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastRgbCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastRgbCurvesDir.empty() || !Glib::file_test(lastRgbCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastRgbCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastRgbCurvesDir = preferredPath;
}
- if (lastLabCurvesDir.empty() || !Glib::file_test (lastLabCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastLabCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastLabCurvesDir.empty() || !Glib::file_test(lastLabCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastLabCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastLabCurvesDir = preferredPath;
}
- if (lastRetinexDir.empty() || !Glib::file_test (lastRetinexDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastLabCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastRetinexDir.empty() || !Glib::file_test(lastRetinexDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastLabCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastRetinexDir = preferredPath;
}
- if (lastDenoiseCurvesDir.empty() || !Glib::file_test (lastDenoiseCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastDenoiseCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastDenoiseCurvesDir.empty() || !Glib::file_test(lastDenoiseCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastDenoiseCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastDenoiseCurvesDir = preferredPath;
}
- if (lastWaveletCurvesDir.empty() || !Glib::file_test (lastWaveletCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastWaveletCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastWaveletCurvesDir.empty() || !Glib::file_test(lastWaveletCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastWaveletCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastWaveletCurvesDir = preferredPath;
}
- if (lastPFCurvesDir.empty() || !Glib::file_test (lastPFCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastPFCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastPFCurvesDir.empty() || !Glib::file_test(lastPFCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastPFCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastPFCurvesDir = preferredPath;
}
- if (lastHsvCurvesDir.empty() || !Glib::file_test (lastHsvCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastHsvCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastHsvCurvesDir.empty() || !Glib::file_test(lastHsvCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastHsvCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastHsvCurvesDir = preferredPath;
}
- if (lastToneCurvesDir.empty() || !Glib::file_test (lastToneCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastToneCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastToneCurvesDir.empty() || !Glib::file_test(lastToneCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastToneCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastToneCurvesDir = preferredPath;
}
- if (lastProfilingReferenceDir.empty() || !Glib::file_test (lastProfilingReferenceDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastProfilingReferenceDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastProfilingReferenceDir.empty() || !Glib::file_test(lastProfilingReferenceDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastProfilingReferenceDir, Glib::FILE_TEST_IS_DIR)) {
lastProfilingReferenceDir = preferredPath;
}
- if (lastVibranceCurvesDir.empty() || !Glib::file_test (lastVibranceCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastVibranceCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastVibranceCurvesDir.empty() || !Glib::file_test(lastVibranceCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastVibranceCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastVibranceCurvesDir = preferredPath;
}
- if (loadSaveProfilePath.empty() || !Glib::file_test (loadSaveProfilePath, Glib::FILE_TEST_EXISTS) || !Glib::file_test (loadSaveProfilePath, Glib::FILE_TEST_IS_DIR)) {
+ if (loadSaveProfilePath.empty() || !Glib::file_test(loadSaveProfilePath, Glib::FILE_TEST_EXISTS) || !Glib::file_test(loadSaveProfilePath, Glib::FILE_TEST_IS_DIR)) {
loadSaveProfilePath = preferredPath;
}
- if (lastBWCurvesDir.empty() || !Glib::file_test (lastBWCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test (lastBWCurvesDir, Glib::FILE_TEST_IS_DIR)) {
+ if (lastBWCurvesDir.empty() || !Glib::file_test(lastBWCurvesDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastBWCurvesDir, Glib::FILE_TEST_IS_DIR)) {
lastBWCurvesDir = preferredPath;
}
+ if (lastICCProfCreatorDir.empty() || !Glib::file_test(lastICCProfCreatorDir, Glib::FILE_TEST_EXISTS) || !Glib::file_test(lastICCProfCreatorDir, Glib::FILE_TEST_IS_DIR)) {
+ lastICCProfCreatorDir = preferredPath;
+ }
}
Glib::ustring Options::getPreferredProfilePath()
@@ -218,7 +221,7 @@ Glib::ustring Options::getPreferredProfilePath()
*@return Send back the absolute path of the given filename or "Neutral" if "Neutral" has been set to profName. Implementor will have
* to test for this particular value. If the absolute path is invalid (e.g. the file doesn't exist), it will return an empty string.
*/
-Glib::ustring Options::findProfilePath (Glib::ustring &profName)
+Glib::ustring Options::findProfilePath(Glib::ustring &profName)
{
if (profName.empty()) {
return "";
@@ -232,41 +235,41 @@ Glib::ustring Options::findProfilePath (Glib::ustring &profName)
return profName;
}
- Glib::ustring p = profName.substr (0, 4);
+ Glib::ustring p = profName.substr(0, 4);
if (p == "${U}") {
// the path starts by the User virtual path
p = getUserProfilePath();
- Glib::ustring fullPath = Glib::build_filename (p, profName.substr (5) + paramFileExtension);
+ Glib::ustring fullPath = Glib::build_filename(p, profName.substr(5) + paramFileExtension);
- if (!p.empty() && Glib::file_test (fullPath, Glib::FILE_TEST_EXISTS)) {
- return Glib::path_get_dirname (fullPath);
+ if (!p.empty() && Glib::file_test(fullPath, Glib::FILE_TEST_EXISTS)) {
+ return Glib::path_get_dirname(fullPath);
}
} else if (p == "${G}") {
// the path starts by the User virtual path
p = getGlobalProfilePath();
- Glib::ustring fullPath = Glib::build_filename (p, profName.substr (5) + paramFileExtension);
+ Glib::ustring fullPath = Glib::build_filename(p, profName.substr(5) + paramFileExtension);
- if (!p.empty() && Glib::file_test (fullPath, Glib::FILE_TEST_EXISTS)) {
- return Glib::path_get_dirname (fullPath);
+ if (!p.empty() && Glib::file_test(fullPath, Glib::FILE_TEST_EXISTS)) {
+ return Glib::path_get_dirname(fullPath);
}
} else {
// compatibility case -> convert the path to the new format
p = getUserProfilePath();
- Glib::ustring fullPath = Glib::build_filename (p, profName + paramFileExtension);
+ Glib::ustring fullPath = Glib::build_filename(p, profName + paramFileExtension);
- if (!p.empty() && Glib::file_test (fullPath, Glib::FILE_TEST_EXISTS)) {
+ if (!p.empty() && Glib::file_test(fullPath, Glib::FILE_TEST_EXISTS)) {
// update the profile path
- profName = Glib::build_filename ("${U}", profName);
- return Glib::path_get_dirname (fullPath);
+ profName = Glib::build_filename("${U}", profName);
+ return Glib::path_get_dirname(fullPath);
}
p = getGlobalProfilePath();
- fullPath = Glib::build_filename (p, profName + paramFileExtension);
+ fullPath = Glib::build_filename(p, profName + paramFileExtension);
- if (!p.empty() && Glib::file_test (fullPath, Glib::FILE_TEST_EXISTS)) {
- profName = Glib::build_filename ("${G}", profName);
- return Glib::path_get_dirname (fullPath);
+ if (!p.empty() && Glib::file_test(fullPath, Glib::FILE_TEST_EXISTS)) {
+ profName = Glib::build_filename("${G}", profName);
+ return Glib::path_get_dirname(fullPath);
}
}
@@ -274,7 +277,7 @@ Glib::ustring Options::findProfilePath (Glib::ustring &profName)
}
-void Options::setDefaults ()
+void Options::setDefaults()
{
windowWidth = 1200;
@@ -390,21 +393,21 @@ void Options::setDefaults ()
CPBKeys = CPBKT_TID;
editorToSendTo = 1;
favoriteDirs.clear();
- tpOpen.clear ();
+ tpOpen.clear();
autoSaveTpOpen = true;
//crvOpen.clear ();
- parseExtensions.clear ();
- parseExtensionsEnabled.clear ();
- parsedExtensions.clear ();
+ parseExtensions.clear();
+ parseExtensionsEnabled.clear();
+ parsedExtensions.clear();
renameUseTemplates = false;
- renameTemplates.clear ();
- thumbnailZoomRatios.clear ();
- thumbnailZoomRatios.push_back (0.2);
- thumbnailZoomRatios.push_back (0.3);
- thumbnailZoomRatios.push_back (0.45);
- thumbnailZoomRatios.push_back (0.6);
- thumbnailZoomRatios.push_back (0.8);
- thumbnailZoomRatios.push_back (1.0);
+ renameTemplates.clear();
+ thumbnailZoomRatios.clear();
+ thumbnailZoomRatios.push_back(0.2);
+ thumbnailZoomRatios.push_back(0.3);
+ thumbnailZoomRatios.push_back(0.45);
+ thumbnailZoomRatios.push_back(0.6);
+ thumbnailZoomRatios.push_back(0.8);
+ thumbnailZoomRatios.push_back(1.0);
overlayedFileNames = false;
filmStripOverlayedFileNames = false;
internalThumbIfUntouched = true; // if TRUE, only fast, internal preview images are taken if the image is not edited yet
@@ -440,6 +443,22 @@ void Options::setDefaults ()
menuGroupProfileOperations = true;
menuGroupExtProg = true;
+ ICCPC_primariesPreset = "sRGB",
+ ICCPC_redPrimaryX = 0.6400;
+ ICCPC_redPrimaryY = 0.3300;
+ ICCPC_greenPrimaryX = 0.3000;
+ ICCPC_greenPrimaryY = 0.6000;
+ ICCPC_bluePrimaryX = 0.1500;
+ ICCPC_bluePrimaryY = 0.0600;
+ ICCPC_gammaPreset = "Custom";
+ ICCPC_gamma = 2.4;
+ ICCPC_slope = 12.92;
+ ICCPC_profileVersion = "v4";
+ ICCPC_illuminant = "DEF";
+ ICCPC_description = "";
+ ICCPC_copyright = Options::getICCProfileCopyright();
+ ICCPC_appendParamsToDesc = false;
+
fastexport_bypass_sharpening = true;
fastexport_bypass_sharpenEdge = true;
fastexport_bypass_sharpenMicro = true;
@@ -461,12 +480,11 @@ void Options::setDefaults ()
fastexport_bypass_raw_ca = true;
fastexport_bypass_raw_df = true;
fastexport_bypass_raw_ff = true;
- fastexport_icm_input = "(camera)";
- fastexport_icm_working = "ProPhoto";
- fastexport_icm_output = "RT_sRGB";
+ fastexport_icm_input_profile = "(camera)";
+ fastexport_icm_working_profile = "ProPhoto";
+ fastexport_icm_output_profile = options.rtSettings.srgb;
fastexport_icm_outputIntent = rtengine::RI_RELATIVE;
fastexport_icm_outputBPC = true;
- fastexport_icm_gamma = "default";
fastexport_resize_enabled = true;
fastexport_resize_scale = 1;
fastexport_resize_appliesTo = "Cropped area";
@@ -501,10 +519,10 @@ void Options::setDefaults ()
rtSettings.darkFramesPath = "";
rtSettings.flatFieldsPath = "";
#ifdef WIN32
- const gchar* sysRoot = g_getenv ("SystemRoot"); // Returns e.g. "c:\Windows"
+ const gchar* sysRoot = g_getenv("SystemRoot"); // Returns e.g. "c:\Windows"
if (sysRoot != NULL) {
- rtSettings.iccDirectory = Glib::ustring (sysRoot) + Glib::ustring ("\\System32\\spool\\drivers\\color");
+ rtSettings.iccDirectory = Glib::ustring(sysRoot) + Glib::ustring("\\System32\\spool\\drivers\\color");
} else {
rtSettings.iccDirectory = "C:\\WINDOWS\\System32\\spool\\drivers\\color";
}
@@ -530,16 +548,16 @@ void Options::setDefaults ()
rtSettings.monitorIntent = rtengine::RI_RELATIVE;
rtSettings.monitorBPC = true;
rtSettings.autoMonitorProfile = false;
- rtSettings.adobe = "RT_Medium_gsRGB"; // put the name of yours profiles (here windows)
- rtSettings.prophoto = "RT_Large_gBT709"; // these names appear in the menu "output profile"
- rtSettings.prophoto10 = "RT_Large_g10"; // these names appear in the menu "output profile"
- rtSettings.srgb10 = "RT_sRGB_g10";
- rtSettings.widegamut = "WideGamutRGB";
- rtSettings.srgb = "RT_sRGB";
- rtSettings.bruce = "Bruce";
- rtSettings.beta = "BetaRGB";
- rtSettings.best = "BestRGB";
- rtSettings.rec2020 = "Rec2020";
+ rtSettings.adobe = "RTv4_Medium"; // put the name of yours profiles (here windows)
+ rtSettings.prophoto = "RTv4_Large"; // these names appear in the menu "output profile"
+ rtSettings.widegamut = "RTv4_Wide";
+ rtSettings.srgb = "RTv4_sRGB";
+ rtSettings.bruce = "RTv4_Bruce";
+ rtSettings.beta = "RTv4_Beta";
+ rtSettings.best = "RTv4_Best";
+ rtSettings.rec2020 = "RTv4_Rec2020";
+ rtSettings.ACESp0 = "RTv4_ACES-AP0";
+ rtSettings.ACESp1 = "RTv4_ACES-AP1";
rtSettings.verbose = false;
rtSettings.gamutICC = true;
rtSettings.gamutLch = true;
@@ -586,6 +604,7 @@ void Options::setDefaults ()
lastProfilingReferenceDir = "";
lastBWCurvesDir = "";
lastLensProfileDir = "";
+ lastICCProfCreatorDir = "";
gimpPluginShowInfoDialog = true;
maxRecentFolders = 15;
rtSettings.lensfunDbDirectory = ""; // set also in main.cc and main-cli.cc
@@ -595,480 +614,480 @@ void Options::setDefaults ()
rtSettings.thumbnail_inspector_mode = rtengine::Settings::ThumbnailInspectorMode::JPEG;
}
-Options* Options::copyFrom (Options* other)
+Options* Options::copyFrom(Options* other)
{
*this = *other;
return this;
}
-void Options::filterOutParsedExtensions ()
+void Options::filterOutParsedExtensions()
{
parsedExtensions.clear();
for (unsigned int i = 0; i < parseExtensions.size(); i++)
if (parseExtensionsEnabled[i]) {
- parsedExtensions.push_back (parseExtensions[i].lowercase());
+ parsedExtensions.push_back(parseExtensions[i].lowercase());
}
}
-void Options::readFromFile (Glib::ustring fname)
+void Options::readFromFile(Glib::ustring fname)
{
- setlocale (LC_NUMERIC, "C"); // to set decimal point to "."
+ setlocale(LC_NUMERIC, "C"); // to set decimal point to "."
Glib::KeyFile keyFile;
- if ( !Glib::file_test (fname, Glib::FILE_TEST_EXISTS)) {
- Glib::ustring msg = Glib::ustring::compose ("Options file %1 does not exist", fname);
- throw Error (msg);
+ if (!Glib::file_test(fname, Glib::FILE_TEST_EXISTS)) {
+ Glib::ustring msg = Glib::ustring::compose("Options file %1 does not exist", fname);
+ throw Error(msg);
}
try {
- if (keyFile.load_from_file (fname)) {
+ if (keyFile.load_from_file(fname)) {
// --------------------------------------------------------------------------------------------------------
- if (keyFile.has_group ("General")) {
- if (keyFile.has_key ("General", "TabbedEditor")) {
- tabbedUI = keyFile.get_boolean ("General", "TabbedEditor");
+ if (keyFile.has_group("General")) {
+ if (keyFile.has_key("General", "TabbedEditor")) {
+ tabbedUI = keyFile.get_boolean("General", "TabbedEditor");
}
- if (keyFile.has_key ("General", "StartupDirectory")) {
- if ( keyFile.get_string ("General", "StartupDirectory") == "home") {
+ if (keyFile.has_key("General", "StartupDirectory")) {
+ if (keyFile.get_string("General", "StartupDirectory") == "home") {
startupDir = STARTUPDIR_HOME;
- } else if ( keyFile.get_string ("General", "StartupDirectory") == "current") {
+ } else if (keyFile.get_string("General", "StartupDirectory") == "current") {
startupDir = STARTUPDIR_CURRENT;
- } else if ( keyFile.get_string ("General", "StartupDirectory") == "last") {
+ } else if (keyFile.get_string("General", "StartupDirectory") == "last") {
startupDir = STARTUPDIR_LAST;
- } else if ( keyFile.get_string ("General", "StartupDirectory") == "custom") {
+ } else if (keyFile.get_string("General", "StartupDirectory") == "custom") {
startupDir = STARTUPDIR_CUSTOM;
}
}
- if (keyFile.has_key ("General", "StartupPath")) {
- startupPath = keyFile.get_string ("General", "StartupPath");
+ if (keyFile.has_key("General", "StartupPath")) {
+ startupPath = keyFile.get_string("General", "StartupPath");
}
- if (keyFile.has_key ("General", "DateFormat")) {
- dateFormat = keyFile.get_string ("General", "DateFormat");
+ if (keyFile.has_key("General", "DateFormat")) {
+ dateFormat = keyFile.get_string("General", "DateFormat");
}
- if (keyFile.has_key ("General", "AdjusterMinDelay")) {
- adjusterMinDelay = keyFile.get_integer ("General", "AdjusterMinDelay");
+ if (keyFile.has_key("General", "AdjusterMinDelay")) {
+ adjusterMinDelay = keyFile.get_integer("General", "AdjusterMinDelay");
}
- if (keyFile.has_key ("General", "AdjusterMaxDelay")) {
- adjusterMaxDelay = keyFile.get_integer ("General", "AdjusterMaxDelay");
+ if (keyFile.has_key("General", "AdjusterMaxDelay")) {
+ adjusterMaxDelay = keyFile.get_integer("General", "AdjusterMaxDelay");
}
- if (keyFile.has_key ("General", "StoreLastProfile")) {
- savesParamsAtExit = keyFile.get_boolean ("General", "StoreLastProfile");
+ if (keyFile.has_key("General", "StoreLastProfile")) {
+ savesParamsAtExit = keyFile.get_boolean("General", "StoreLastProfile");
}
- if (keyFile.has_key ("General", "MultiUser")) {
- multiUser = keyFile.get_boolean ("General", "MultiUser");
+ if (keyFile.has_key("General", "MultiUser")) {
+ multiUser = keyFile.get_boolean("General", "MultiUser");
}
- if (keyFile.has_key ("General", "Version")) {
- version = keyFile.get_string ("General", "Version");
+ if (keyFile.has_key("General", "Version")) {
+ version = keyFile.get_string("General", "Version");
}
- if (keyFile.has_key ("General", "Language")) {
- language = keyFile.get_string ("General", "Language");
+ if (keyFile.has_key("General", "Language")) {
+ language = keyFile.get_string("General", "Language");
}
- if (keyFile.has_key ("General", "LanguageAutoDetect")) {
- languageAutoDetect = keyFile.get_boolean ("General", "LanguageAutoDetect");
+ if (keyFile.has_key("General", "LanguageAutoDetect")) {
+ languageAutoDetect = keyFile.get_boolean("General", "LanguageAutoDetect");
}
- if (keyFile.has_key ("General", "Theme")) {
- theme = keyFile.get_string ("General", "Theme");
+ if (keyFile.has_key("General", "Theme")) {
+ theme = keyFile.get_string("General", "Theme");
}
- if ( keyFile.has_key ("General", "DarkFramesPath")) {
- rtSettings.darkFramesPath = keyFile.get_string ("General", "DarkFramesPath");
+ if (keyFile.has_key("General", "DarkFramesPath")) {
+ rtSettings.darkFramesPath = keyFile.get_string("General", "DarkFramesPath");
}
- if ( keyFile.has_key ("General", "FlatFieldsPath")) {
- rtSettings.flatFieldsPath = keyFile.get_string ("General", "FlatFieldsPath");
+ if (keyFile.has_key("General", "FlatFieldsPath")) {
+ rtSettings.flatFieldsPath = keyFile.get_string("General", "FlatFieldsPath");
}
- if ( keyFile.has_key ("General", "Verbose")) {
- rtSettings.verbose = keyFile.get_boolean ( "General", "Verbose");
+ if (keyFile.has_key("General", "Verbose")) {
+ rtSettings.verbose = keyFile.get_boolean("General", "Verbose");
}
}
- if (keyFile.has_group ("External Editor")) {
- if (keyFile.has_key ("External Editor", "EditorKind")) {
- editorToSendTo = keyFile.get_integer ("External Editor", "EditorKind");
+ if (keyFile.has_group("External Editor")) {
+ if (keyFile.has_key("External Editor", "EditorKind")) {
+ editorToSendTo = keyFile.get_integer("External Editor", "EditorKind");
}
- if (keyFile.has_key ("External Editor", "GimpDir")) {
- gimpDir = keyFile.get_string ("External Editor", "GimpDir");
+ if (keyFile.has_key("External Editor", "GimpDir")) {
+ gimpDir = keyFile.get_string("External Editor", "GimpDir");
}
- if (keyFile.has_key ("External Editor", "PhotoshopDir")) {
- psDir = keyFile.get_string ("External Editor", "PhotoshopDir");
+ if (keyFile.has_key("External Editor", "PhotoshopDir")) {
+ psDir = keyFile.get_string("External Editor", "PhotoshopDir");
}
- if (keyFile.has_key ("External Editor", "CustomEditor")) {
- customEditorProg = keyFile.get_string ("External Editor", "CustomEditor");
+ if (keyFile.has_key("External Editor", "CustomEditor")) {
+ customEditorProg = keyFile.get_string("External Editor", "CustomEditor");
}
}
- if (keyFile.has_group ("Output")) {
- if (keyFile.has_key ("Output", "Format")) {
- saveFormat.format = keyFile.get_string ("Output", "Format");
+ if (keyFile.has_group("Output")) {
+ if (keyFile.has_key("Output", "Format")) {
+ saveFormat.format = keyFile.get_string("Output", "Format");
}
- if (keyFile.has_key ("Output", "JpegQuality")) {
- saveFormat.jpegQuality = keyFile.get_integer ("Output", "JpegQuality");
+ if (keyFile.has_key("Output", "JpegQuality")) {
+ saveFormat.jpegQuality = keyFile.get_integer("Output", "JpegQuality");
}
- if (keyFile.has_key ("Output", "JpegSubSamp")) {
- saveFormat.jpegSubSamp = keyFile.get_integer ("Output", "JpegSubSamp");
+ if (keyFile.has_key("Output", "JpegSubSamp")) {
+ saveFormat.jpegSubSamp = keyFile.get_integer("Output", "JpegSubSamp");
}
- if (keyFile.has_key ("Output", "PngBps")) {
- saveFormat.pngBits = keyFile.get_integer ("Output", "PngBps");
+ if (keyFile.has_key("Output", "PngBps")) {
+ saveFormat.pngBits = keyFile.get_integer("Output", "PngBps");
}
- if (keyFile.has_key ("Output", "TiffBps")) {
- saveFormat.tiffBits = keyFile.get_integer ("Output", "TiffBps");
+ if (keyFile.has_key("Output", "TiffBps")) {
+ saveFormat.tiffBits = keyFile.get_integer("Output", "TiffBps");
}
- if (keyFile.has_key ("Output", "TiffUncompressed")) {
- saveFormat.tiffUncompressed = keyFile.get_boolean ("Output", "TiffUncompressed");
+ if (keyFile.has_key("Output", "TiffUncompressed")) {
+ saveFormat.tiffUncompressed = keyFile.get_boolean("Output", "TiffUncompressed");
}
- if (keyFile.has_key ("Output", "SaveProcParams")) {
- saveFormat.saveParams = keyFile.get_boolean ("Output", "SaveProcParams");
+ if (keyFile.has_key("Output", "SaveProcParams")) {
+ saveFormat.saveParams = keyFile.get_boolean("Output", "SaveProcParams");
}
- if (keyFile.has_key ("Output", "FormatBatch")) {
- saveFormatBatch.format = keyFile.get_string ("Output", "FormatBatch");
+ if (keyFile.has_key("Output", "FormatBatch")) {
+ saveFormatBatch.format = keyFile.get_string("Output", "FormatBatch");
}
- if (keyFile.has_key ("Output", "JpegQualityBatch")) {
- saveFormatBatch.jpegQuality = keyFile.get_integer ("Output", "JpegQualityBatch");
+ if (keyFile.has_key("Output", "JpegQualityBatch")) {
+ saveFormatBatch.jpegQuality = keyFile.get_integer("Output", "JpegQualityBatch");
}
- if (keyFile.has_key ("Output", "JpegSubSampBatch")) {
- saveFormatBatch.jpegSubSamp = keyFile.get_integer ("Output", "JpegSubSampBatch");
+ if (keyFile.has_key("Output", "JpegSubSampBatch")) {
+ saveFormatBatch.jpegSubSamp = keyFile.get_integer("Output", "JpegSubSampBatch");
}
- if (keyFile.has_key ("Output", "PngBpsBatch")) {
- saveFormatBatch.pngBits = keyFile.get_integer ("Output", "PngBpsBatch");
+ if (keyFile.has_key("Output", "PngBpsBatch")) {
+ saveFormatBatch.pngBits = keyFile.get_integer("Output", "PngBpsBatch");
}
- if (keyFile.has_key ("Output", "TiffBpsBatch")) {
- saveFormatBatch.tiffBits = keyFile.get_integer ("Output", "TiffBpsBatch");
+ if (keyFile.has_key("Output", "TiffBpsBatch")) {
+ saveFormatBatch.tiffBits = keyFile.get_integer("Output", "TiffBpsBatch");
}
- if (keyFile.has_key ("Output", "TiffUncompressedBatch")) {
- saveFormatBatch.tiffUncompressed = keyFile.get_boolean ("Output", "TiffUncompressedBatch");
+ if (keyFile.has_key("Output", "TiffUncompressedBatch")) {
+ saveFormatBatch.tiffUncompressed = keyFile.get_boolean("Output", "TiffUncompressedBatch");
}
- if (keyFile.has_key ("Output", "SaveProcParamsBatch")) {
- saveFormatBatch.saveParams = keyFile.get_boolean ("Output", "SaveProcParamsBatch");
+ if (keyFile.has_key("Output", "SaveProcParamsBatch")) {
+ saveFormatBatch.saveParams = keyFile.get_boolean("Output", "SaveProcParamsBatch");
}
- if (keyFile.has_key ("Output", "Path")) {
- savePathTemplate = keyFile.get_string ("Output", "Path");
+ if (keyFile.has_key("Output", "Path")) {
+ savePathTemplate = keyFile.get_string("Output", "Path");
}
- if (keyFile.has_key ("Output", "PathTemplate")) {
- savePathTemplate = keyFile.get_string ("Output", "PathTemplate");
+ if (keyFile.has_key("Output", "PathTemplate")) {
+ savePathTemplate = keyFile.get_string("Output", "PathTemplate");
}
- if (keyFile.has_key ("Output", "PathFolder")) {
- savePathFolder = keyFile.get_string ("Output", "PathFolder");
+ if (keyFile.has_key("Output", "PathFolder")) {
+ savePathFolder = keyFile.get_string("Output", "PathFolder");
}
- if (keyFile.has_key ("Output", "AutoSuffix")) {
- autoSuffix = keyFile.get_boolean ("Output", "AutoSuffix");
+ if (keyFile.has_key("Output", "AutoSuffix")) {
+ autoSuffix = keyFile.get_boolean("Output", "AutoSuffix");
}
- if (keyFile.has_key ("Output", "ForceFormatOpts")) {
- forceFormatOpts = keyFile.get_boolean ("Output", "ForceFormatOpts");
+ if (keyFile.has_key("Output", "ForceFormatOpts")) {
+ forceFormatOpts = keyFile.get_boolean("Output", "ForceFormatOpts");
}
- if (keyFile.has_key ("Output", "SaveMethodNum")) {
- saveMethodNum = keyFile.get_integer ("Output", "SaveMethodNum");
+ if (keyFile.has_key("Output", "SaveMethodNum")) {
+ saveMethodNum = keyFile.get_integer("Output", "SaveMethodNum");
}
- if (keyFile.has_key ("Output", "UsePathTemplate")) {
- saveUsePathTemplate = keyFile.get_boolean ("Output", "UsePathTemplate");
+ if (keyFile.has_key("Output", "UsePathTemplate")) {
+ saveUsePathTemplate = keyFile.get_boolean("Output", "UsePathTemplate");
}
- if (keyFile.has_key ("Output", "LastSaveAsPath")) {
- lastSaveAsPath = keyFile.get_string ("Output", "LastSaveAsPath");
+ if (keyFile.has_key("Output", "LastSaveAsPath")) {
+ lastSaveAsPath = keyFile.get_string("Output", "LastSaveAsPath");
}
- if (keyFile.has_key ("Output", "OverwriteOutputFile")) {
- overwriteOutputFile = keyFile.get_boolean ("Output", "OverwriteOutputFile");
+ if (keyFile.has_key("Output", "OverwriteOutputFile")) {
+ overwriteOutputFile = keyFile.get_boolean("Output", "OverwriteOutputFile");
}
}
- if (keyFile.has_group ("Profiles")) {
- if (keyFile.has_key ("Profiles", "Directory")) {
- profilePath = keyFile.get_string ("Profiles", "Directory");
+ if (keyFile.has_group("Profiles")) {
+ if (keyFile.has_key("Profiles", "Directory")) {
+ profilePath = keyFile.get_string("Profiles", "Directory");
}
- if (keyFile.has_key ("Profiles", "UseBundledProfiles")) {
- useBundledProfiles = keyFile.get_boolean ("Profiles", "UseBundledProfiles");
+ if (keyFile.has_key("Profiles", "UseBundledProfiles")) {
+ useBundledProfiles = keyFile.get_boolean("Profiles", "UseBundledProfiles");
}
- if (keyFile.has_key ("Profiles", "LoadSaveProfilePath")) {
- loadSaveProfilePath = keyFile.get_string ("Profiles", "LoadSaveProfilePath");
+ if (keyFile.has_key("Profiles", "LoadSaveProfilePath")) {
+ loadSaveProfilePath = keyFile.get_string("Profiles", "LoadSaveProfilePath");
}
- if (keyFile.has_key ("Profiles", "RawDefault")) {
- defProfRaw = keyFile.get_string ("Profiles", "RawDefault");
+ if (keyFile.has_key("Profiles", "RawDefault")) {
+ defProfRaw = keyFile.get_string("Profiles", "RawDefault");
}
- if (keyFile.has_key ("Profiles", "ImgDefault")) {
- defProfImg = keyFile.get_string ("Profiles", "ImgDefault");
+ if (keyFile.has_key("Profiles", "ImgDefault")) {
+ defProfImg = keyFile.get_string("Profiles", "ImgDefault");
}
- if (keyFile.has_key ("Profiles", "FilledProfile")) {
- filledProfile = keyFile.get_boolean ("Profiles", "FilledProfile");
+ if (keyFile.has_key("Profiles", "FilledProfile")) {
+ filledProfile = keyFile.get_boolean("Profiles", "FilledProfile");
}
- if (keyFile.has_key ("Profiles", "SaveParamsWithFile")) {
- saveParamsFile = keyFile.get_boolean ("Profiles", "SaveParamsWithFile");
+ if (keyFile.has_key("Profiles", "SaveParamsWithFile")) {
+ saveParamsFile = keyFile.get_boolean("Profiles", "SaveParamsWithFile");
}
- if (keyFile.has_key ("Profiles", "SaveParamsToCache")) {
- saveParamsCache = keyFile.get_boolean ("Profiles", "SaveParamsToCache");
+ if (keyFile.has_key("Profiles", "SaveParamsToCache")) {
+ saveParamsCache = keyFile.get_boolean("Profiles", "SaveParamsToCache");
}
- if (keyFile.has_key ("Profiles", "LoadParamsFromLocation")) {
- paramsLoadLocation = (PPLoadLocation)keyFile.get_integer ("Profiles", "LoadParamsFromLocation");
+ if (keyFile.has_key("Profiles", "LoadParamsFromLocation")) {
+ paramsLoadLocation = (PPLoadLocation)keyFile.get_integer("Profiles", "LoadParamsFromLocation");
}
- if (keyFile.has_key ("Profiles", "CustomProfileBuilder")) {
- CPBPath = keyFile.get_string ("Profiles", "CustomProfileBuilder"); // for backward compatibility only
+ if (keyFile.has_key("Profiles", "CustomProfileBuilder")) {
+ CPBPath = keyFile.get_string("Profiles", "CustomProfileBuilder"); // for backward compatibility only
}
- if (keyFile.has_key ("Profiles", "CustomProfileBuilderPath")) {
- CPBPath = keyFile.get_string ("Profiles", "CustomProfileBuilderPath");
+ if (keyFile.has_key("Profiles", "CustomProfileBuilderPath")) {
+ CPBPath = keyFile.get_string("Profiles", "CustomProfileBuilderPath");
}
- if (keyFile.has_key ("Profiles", "CustomProfileBuilderKeys")) {
- CPBKeys = (CPBKeyType)keyFile.get_integer ("Profiles", "CustomProfileBuilderKeys");
+ if (keyFile.has_key("Profiles", "CustomProfileBuilderKeys")) {
+ CPBKeys = (CPBKeyType)keyFile.get_integer("Profiles", "CustomProfileBuilderKeys");
}
}
- if (keyFile.has_group ("File Browser")) {
- if (keyFile.has_key ("File Browser", "ThumbnailSize")) {
- thumbSize = keyFile.get_integer ("File Browser", "ThumbnailSize");
+ if (keyFile.has_group("File Browser")) {
+ if (keyFile.has_key("File Browser", "ThumbnailSize")) {
+ thumbSize = keyFile.get_integer("File Browser", "ThumbnailSize");
}
- if (keyFile.has_key ("File Browser", "ThumbnailSizeTab")) {
- thumbSizeTab = keyFile.get_integer ("File Browser", "ThumbnailSizeTab");
+ if (keyFile.has_key("File Browser", "ThumbnailSizeTab")) {
+ thumbSizeTab = keyFile.get_integer("File Browser", "ThumbnailSizeTab");
}
- if (keyFile.has_key ("File Browser", "ThumbnailSizeQueue")) {
- thumbSizeQueue = keyFile.get_integer ("File Browser", "ThumbnailSizeQueue");
+ if (keyFile.has_key("File Browser", "ThumbnailSizeQueue")) {
+ thumbSizeQueue = keyFile.get_integer("File Browser", "ThumbnailSizeQueue");
}
- if (keyFile.has_key ("File Browser", "SameThumbSize")) {
- sameThumbSize = keyFile.get_integer ("File Browser", "SameThumbSize");
+ if (keyFile.has_key("File Browser", "SameThumbSize")) {
+ sameThumbSize = keyFile.get_integer("File Browser", "SameThumbSize");
}
- if (keyFile.has_key ("File Browser", "BrowseOnlyRaw")) {
- fbOnlyRaw = keyFile.get_boolean ("File Browser", "BrowseOnlyRaw");
+ if (keyFile.has_key("File Browser", "BrowseOnlyRaw")) {
+ fbOnlyRaw = keyFile.get_boolean("File Browser", "BrowseOnlyRaw");
}
- if (keyFile.has_key ("File Browser", "BrowserShowsDate")) {
- fbShowDateTime = keyFile.get_boolean ("File Browser", "BrowserShowsDate");
+ if (keyFile.has_key("File Browser", "BrowserShowsDate")) {
+ fbShowDateTime = keyFile.get_boolean("File Browser", "BrowserShowsDate");
}
- if (keyFile.has_key ("File Browser", "BrowserShowsExif")) {
- fbShowBasicExif = keyFile.get_boolean ("File Browser", "BrowserShowsExif");
+ if (keyFile.has_key("File Browser", "BrowserShowsExif")) {
+ fbShowBasicExif = keyFile.get_boolean("File Browser", "BrowserShowsExif");
}
- if (keyFile.has_key ("File Browser", "BrowserShowsExpComp")) {
- fbShowExpComp = keyFile.get_boolean ("File Browser", "BrowserShowsExpComp");
+ if (keyFile.has_key("File Browser", "BrowserShowsExpComp")) {
+ fbShowExpComp = keyFile.get_boolean("File Browser", "BrowserShowsExpComp");
}
- if (keyFile.has_key ("File Browser", "BrowserShowsHidden")) {
- fbShowHidden = keyFile.get_boolean ("File Browser", "BrowserShowsHidden");
+ if (keyFile.has_key("File Browser", "BrowserShowsHidden")) {
+ fbShowHidden = keyFile.get_boolean("File Browser", "BrowserShowsHidden");
}
- if (keyFile.has_key ("File Browser", "MaxPreviewHeight")) {
- maxThumbnailHeight = keyFile.get_integer ("File Browser", "MaxPreviewHeight");
+ if (keyFile.has_key("File Browser", "MaxPreviewHeight")) {
+ maxThumbnailHeight = keyFile.get_integer("File Browser", "MaxPreviewHeight");
}
- if (keyFile.has_key ("File Browser", "MaxCacheEntries")) {
- maxCacheEntries = keyFile.get_integer ("File Browser", "MaxCacheEntries");
+ if (keyFile.has_key("File Browser", "MaxCacheEntries")) {
+ maxCacheEntries = keyFile.get_integer("File Browser", "MaxCacheEntries");
}
- if (keyFile.has_key ("File Browser", "ParseExtensions")) {
- parseExtensions = keyFile.get_string_list ("File Browser", "ParseExtensions");
+ if (keyFile.has_key("File Browser", "ParseExtensions")) {
+ parseExtensions = keyFile.get_string_list("File Browser", "ParseExtensions");
}
- if (keyFile.has_key ("File Browser", "ParseExtensionsEnabled")) {
- parseExtensionsEnabled = keyFile.get_integer_list ("File Browser", "ParseExtensionsEnabled");
+ if (keyFile.has_key("File Browser", "ParseExtensionsEnabled")) {
+ parseExtensionsEnabled = keyFile.get_integer_list("File Browser", "ParseExtensionsEnabled");
}
- if (keyFile.has_key ("File Browser", "ThumbnailArrangement")) {
- fbArrangement = keyFile.get_integer ("File Browser", "ThumbnailArrangement");
+ if (keyFile.has_key("File Browser", "ThumbnailArrangement")) {
+ fbArrangement = keyFile.get_integer("File Browser", "ThumbnailArrangement");
}
- if (keyFile.has_key ("File Browser", "ThumbnailInterpolation")) {
- thumbInterp = keyFile.get_integer ("File Browser", "ThumbnailInterpolation");
+ if (keyFile.has_key("File Browser", "ThumbnailInterpolation")) {
+ thumbInterp = keyFile.get_integer("File Browser", "ThumbnailInterpolation");
}
- if (keyFile.has_key ("File Browser", "FavoriteDirs")) {
- favoriteDirs = keyFile.get_string_list ("File Browser", "FavoriteDirs");
+ if (keyFile.has_key("File Browser", "FavoriteDirs")) {
+ favoriteDirs = keyFile.get_string_list("File Browser", "FavoriteDirs");
}
- if (keyFile.has_key ("File Browser", "RenameTemplates")) {
- renameTemplates = keyFile.get_string_list ("File Browser", "RenameTemplates");
+ if (keyFile.has_key("File Browser", "RenameTemplates")) {
+ renameTemplates = keyFile.get_string_list("File Browser", "RenameTemplates");
}
- if (keyFile.has_key ("File Browser", "RenameUseTemplates")) {
- renameUseTemplates = keyFile.get_boolean ("File Browser", "RenameUseTemplates");
+ if (keyFile.has_key("File Browser", "RenameUseTemplates")) {
+ renameUseTemplates = keyFile.get_boolean("File Browser", "RenameUseTemplates");
}
- if (keyFile.has_key ("File Browser", "ThumbnailZoomRatios")) {
- thumbnailZoomRatios = keyFile.get_double_list ("File Browser", "ThumbnailZoomRatios");
+ if (keyFile.has_key("File Browser", "ThumbnailZoomRatios")) {
+ thumbnailZoomRatios = keyFile.get_double_list("File Browser", "ThumbnailZoomRatios");
}
- if (keyFile.has_key ("File Browser", "OverlayedFileNames")) {
- overlayedFileNames = keyFile.get_boolean ("File Browser", "OverlayedFileNames");
+ if (keyFile.has_key("File Browser", "OverlayedFileNames")) {
+ overlayedFileNames = keyFile.get_boolean("File Browser", "OverlayedFileNames");
}
- if (keyFile.has_key ("File Browser", "FilmStripOverlayedFileNames")) {
- filmStripOverlayedFileNames = keyFile.get_boolean ("File Browser", "FilmStripOverlayedFileNames");
+ if (keyFile.has_key("File Browser", "FilmStripOverlayedFileNames")) {
+ filmStripOverlayedFileNames = keyFile.get_boolean("File Browser", "FilmStripOverlayedFileNames");
}
- if (keyFile.has_key ("File Browser", "ShowFileNames")) {
- showFileNames = keyFile.get_boolean ("File Browser", "ShowFileNames");
+ if (keyFile.has_key("File Browser", "ShowFileNames")) {
+ showFileNames = keyFile.get_boolean("File Browser", "ShowFileNames");
}
- if (keyFile.has_key ("File Browser", "FilmStripShowFileNames")) {
- filmStripShowFileNames = keyFile.get_boolean ("File Browser", "FilmStripShowFileNames");
+ if (keyFile.has_key("File Browser", "FilmStripShowFileNames")) {
+ filmStripShowFileNames = keyFile.get_boolean("File Browser", "FilmStripShowFileNames");
}
- if (keyFile.has_key ("File Browser", "InternalThumbIfUntouched")) {
- internalThumbIfUntouched = keyFile.get_boolean ("File Browser", "InternalThumbIfUntouched");
+ if (keyFile.has_key("File Browser", "InternalThumbIfUntouched")) {
+ internalThumbIfUntouched = keyFile.get_boolean("File Browser", "InternalThumbIfUntouched");
}
- if (keyFile.has_key ("File Browser", "menuGroupRank")) {
- menuGroupRank = keyFile.get_boolean ("File Browser", "menuGroupRank");
+ if (keyFile.has_key("File Browser", "menuGroupRank")) {
+ menuGroupRank = keyFile.get_boolean("File Browser", "menuGroupRank");
}
- if (keyFile.has_key ("File Browser", "menuGroupLabel")) {
- menuGroupLabel = keyFile.get_boolean ("File Browser", "menuGroupLabel");
+ if (keyFile.has_key("File Browser", "menuGroupLabel")) {
+ menuGroupLabel = keyFile.get_boolean("File Browser", "menuGroupLabel");
}
- if (keyFile.has_key ("File Browser", "menuGroupFileOperations")) {
- menuGroupFileOperations = keyFile.get_boolean ("File Browser", "menuGroupFileOperations");
+ if (keyFile.has_key("File Browser", "menuGroupFileOperations")) {
+ menuGroupFileOperations = keyFile.get_boolean("File Browser", "menuGroupFileOperations");
}
- if (keyFile.has_key ("File Browser", "menuGroupProfileOperations")) {
- menuGroupProfileOperations = keyFile.get_boolean ("File Browser", "menuGroupProfileOperations");
+ if (keyFile.has_key("File Browser", "menuGroupProfileOperations")) {
+ menuGroupProfileOperations = keyFile.get_boolean("File Browser", "menuGroupProfileOperations");
}
- if (keyFile.has_key ("File Browser", "menuGroupExtProg")) {
- menuGroupExtProg = keyFile.get_boolean ("File Browser", "menuGroupExtProg");
+ if (keyFile.has_key("File Browser", "menuGroupExtProg")) {
+ menuGroupExtProg = keyFile.get_boolean("File Browser", "menuGroupExtProg");
}
- if (keyFile.has_key ("File Browser", "MaxRecentFolders")) {
- maxRecentFolders = keyFile.get_integer ("File Browser", "MaxRecentFolders");
+ if (keyFile.has_key("File Browser", "MaxRecentFolders")) {
+ maxRecentFolders = keyFile.get_integer("File Browser", "MaxRecentFolders");
}
- recentFolders.reserve (maxRecentFolders + 10); // reserve some more than maxRecentFolders, because at runtime it stores more than that
+ recentFolders.reserve(maxRecentFolders + 10); // reserve some more than maxRecentFolders, because at runtime it stores more than that
- if (keyFile.has_key ("File Browser", "RecentFolders")) {
- recentFolders = keyFile.get_string_list ("File Browser", "RecentFolders");
+ if (keyFile.has_key("File Browser", "RecentFolders")) {
+ recentFolders = keyFile.get_string_list("File Browser", "RecentFolders");
}
}
- if (keyFile.has_group ("Clipping Indication")) {
- if (keyFile.has_key ("Clipping Indication", "HighlightThreshold")) {
- highlightThreshold = keyFile.get_integer ("Clipping Indication", "HighlightThreshold");
+ if (keyFile.has_group("Clipping Indication")) {
+ if (keyFile.has_key("Clipping Indication", "HighlightThreshold")) {
+ highlightThreshold = keyFile.get_integer("Clipping Indication", "HighlightThreshold");
}
- if (keyFile.has_key ("Clipping Indication", "ShadowThreshold")) {
- shadowThreshold = keyFile.get_integer ("Clipping Indication", "ShadowThreshold");
+ if (keyFile.has_key("Clipping Indication", "ShadowThreshold")) {
+ shadowThreshold = keyFile.get_integer("Clipping Indication", "ShadowThreshold");
}
- if (keyFile.has_key ("Clipping Indication", "BlinkClipped")) {
- blinkClipped = keyFile.get_boolean ("Clipping Indication", "BlinkClipped");
+ if (keyFile.has_key("Clipping Indication", "BlinkClipped")) {
+ blinkClipped = keyFile.get_boolean("Clipping Indication", "BlinkClipped");
}
}
- if (keyFile.has_group ("Performance")) {
- if (keyFile.has_key ("Performance", "RgbDenoiseThreadLimit")) {
- rgbDenoiseThreadLimit = keyFile.get_integer ("Performance", "RgbDenoiseThreadLimit");
+ if (keyFile.has_group("Performance")) {
+ if (keyFile.has_key("Performance", "RgbDenoiseThreadLimit")) {
+ rgbDenoiseThreadLimit = keyFile.get_integer("Performance", "RgbDenoiseThreadLimit");
}
- if ( keyFile.has_key ("Performance", "NRauto")) {
- rtSettings.nrauto = keyFile.get_double ("Performance", "NRauto");
+ if (keyFile.has_key("Performance", "NRauto")) {
+ rtSettings.nrauto = keyFile.get_double("Performance", "NRauto");
}
- if ( keyFile.has_key ("Performance", "NRautomax")) {
- rtSettings.nrautomax = keyFile.get_double ("Performance", "NRautomax");
+ if (keyFile.has_key("Performance", "NRautomax")) {
+ rtSettings.nrautomax = keyFile.get_double("Performance", "NRautomax");
}
- if ( keyFile.has_key ("Performance", "NRhigh")) {
- rtSettings.nrhigh = keyFile.get_double ("Performance", "NRhigh");
+ if (keyFile.has_key("Performance", "NRhigh")) {
+ rtSettings.nrhigh = keyFile.get_double("Performance", "NRhigh");
}
if (rtSettings.nrhigh == 0.0) { //avoid crash by division by zero in noise reduction
rtSettings.nrhigh = 0.45;
}
- if ( keyFile.has_key ("Performance", "NRWavlevel")) {
- rtSettings.nrwavlevel = keyFile.get_integer ("Performance", "NRWavlevel");
+ if (keyFile.has_key("Performance", "NRWavlevel")) {
+ rtSettings.nrwavlevel = keyFile.get_integer("Performance", "NRWavlevel");
}
- if (keyFile.has_key ("Performance", "LevNR")) {
- rtSettings.leveldnv = keyFile.get_integer ("Performance", "LevNR");
+ if (keyFile.has_key("Performance", "LevNR")) {
+ rtSettings.leveldnv = keyFile.get_integer("Performance", "LevNR");
}
- if (keyFile.has_key ("Performance", "LevNRTI")) {
- rtSettings.leveldnti = keyFile.get_integer ("Performance", "LevNRTI");
+ if (keyFile.has_key("Performance", "LevNRTI")) {
+ rtSettings.leveldnti = keyFile.get_integer("Performance", "LevNRTI");
}
- if (keyFile.has_key ("Performance", "LevNRAUT")) {
- rtSettings.leveldnaut = keyFile.get_integer ("Performance", "LevNRAUT");
+ if (keyFile.has_key("Performance", "LevNRAUT")) {
+ rtSettings.leveldnaut = keyFile.get_integer("Performance", "LevNRAUT");
}
- if (keyFile.has_key ("Performance", "LevNRLISS")) {
- rtSettings.leveldnliss = keyFile.get_integer ("Performance", "LevNRLISS");
+ if (keyFile.has_key("Performance", "LevNRLISS")) {
+ rtSettings.leveldnliss = keyFile.get_integer("Performance", "LevNRLISS");
}
- if (keyFile.has_key ("Performance", "SIMPLNRAUT")) {
- rtSettings.leveldnautsimpl = keyFile.get_integer ("Performance", "SIMPLNRAUT");
+ if (keyFile.has_key("Performance", "SIMPLNRAUT")) {
+ rtSettings.leveldnautsimpl = keyFile.get_integer("Performance", "SIMPLNRAUT");
}
- if (keyFile.has_key ("Performance", "ClutCacheSize")) {
- clutCacheSize = keyFile.get_integer ("Performance", "ClutCacheSize");
+ if (keyFile.has_key("Performance", "ClutCacheSize")) {
+ clutCacheSize = keyFile.get_integer("Performance", "ClutCacheSize");
}
- if (keyFile.has_key ("Performance", "MaxInspectorBuffers")) {
- maxInspectorBuffers = keyFile.get_integer ("Performance", "MaxInspectorBuffers");
+ if (keyFile.has_key("Performance", "MaxInspectorBuffers")) {
+ maxInspectorBuffers = keyFile.get_integer("Performance", "MaxInspectorBuffers");
}
- if (keyFile.has_key ("Performance", "InspectorDelay")) {
+ if (keyFile.has_key("Performance", "InspectorDelay")) {
inspectorDelay = keyFile.get_integer("Performance", "InspectorDelay");
}
- if (keyFile.has_key ("Performance", "PreviewDemosaicFromSidecar")) {
- prevdemo = (prevdemo_t)keyFile.get_integer ("Performance", "PreviewDemosaicFromSidecar");
+ if (keyFile.has_key("Performance", "PreviewDemosaicFromSidecar")) {
+ prevdemo = (prevdemo_t)keyFile.get_integer("Performance", "PreviewDemosaicFromSidecar");
}
- if (keyFile.has_key ("Performance", "Daubechies")) {
- rtSettings.daubech = keyFile.get_boolean ("Performance", "Daubechies");
+ if (keyFile.has_key("Performance", "Daubechies")) {
+ rtSettings.daubech = keyFile.get_boolean("Performance", "Daubechies");
}
- if (keyFile.has_key ("Performance", "SerializeTiffRead")) {
- serializeTiffRead = keyFile.get_boolean ("Performance", "SerializeTiffRead");
+ if (keyFile.has_key("Performance", "SerializeTiffRead")) {
+ serializeTiffRead = keyFile.get_boolean("Performance", "SerializeTiffRead");
}
if (keyFile.has_key("Performance", "ThumbnailInspectorMode")) {
@@ -1076,320 +1095,325 @@ void Options::readFromFile (Glib::ustring fname)
}
}
- if (keyFile.has_group ("GUI")) {
- if (keyFile.has_key ("GUI", "WindowWidth")) {
- windowWidth = keyFile.get_integer ("GUI", "WindowWidth");
+ if (keyFile.has_group("GUI")) {
+ if (keyFile.has_key("GUI", "WindowWidth")) {
+ windowWidth = keyFile.get_integer("GUI", "WindowWidth");
}
- if (keyFile.has_key ("GUI", "WindowHeight")) {
- windowHeight = keyFile.get_integer ("GUI", "WindowHeight");
+ if (keyFile.has_key("GUI", "WindowHeight")) {
+ windowHeight = keyFile.get_integer("GUI", "WindowHeight");
}
- if (keyFile.has_key ("GUI", "WindowX")) {
- windowX = keyFile.get_integer ("GUI", "WindowX");
+ if (keyFile.has_key("GUI", "WindowX")) {
+ windowX = keyFile.get_integer("GUI", "WindowX");
}
- if (keyFile.has_key ("GUI", "WindowY")) {
- windowY = keyFile.get_integer ("GUI", "WindowY");
+ if (keyFile.has_key("GUI", "WindowY")) {
+ windowY = keyFile.get_integer("GUI", "WindowY");
}
- if (keyFile.has_key ("GUI", "WindowMonitor")) {
- windowMonitor = keyFile.get_integer ("GUI", "WindowMonitor");
+ if (keyFile.has_key("GUI", "WindowMonitor")) {
+ windowMonitor = keyFile.get_integer("GUI", "WindowMonitor");
}
- if (keyFile.has_key ("GUI", "MeowMonitor")) {
- meowMonitor = keyFile.get_integer ("GUI", "MeowMonitor");
+ if (keyFile.has_key("GUI", "MeowMonitor")) {
+ meowMonitor = keyFile.get_integer("GUI", "MeowMonitor");
}
- if (keyFile.has_key ("GUI", "MeowFullScreen")) {
- meowFullScreen = keyFile.get_boolean ("GUI", "MeowFullScreen");
+ if (keyFile.has_key("GUI", "MeowFullScreen")) {
+ meowFullScreen = keyFile.get_boolean("GUI", "MeowFullScreen");
}
- if (keyFile.has_key ("GUI", "MeowMaximized")) {
- meowMaximized = keyFile.get_boolean ("GUI", "MeowMaximized");
+ if (keyFile.has_key("GUI", "MeowMaximized")) {
+ meowMaximized = keyFile.get_boolean("GUI", "MeowMaximized");
}
- if (keyFile.has_key ("GUI", "MeowWidth")) {
- meowWidth = keyFile.get_integer ("GUI", "MeowWidth");
+ if (keyFile.has_key("GUI", "MeowWidth")) {
+ meowWidth = keyFile.get_integer("GUI", "MeowWidth");
}
- if (keyFile.has_key ("GUI", "MeowHeight")) {
- meowHeight = keyFile.get_integer ("GUI", "MeowHeight");
+ if (keyFile.has_key("GUI", "MeowHeight")) {
+ meowHeight = keyFile.get_integer("GUI", "MeowHeight");
}
- if (keyFile.has_key ("GUI", "MeowX")) {
- meowX = keyFile.get_integer ("GUI", "MeowX");
+ if (keyFile.has_key("GUI", "MeowX")) {
+ meowX = keyFile.get_integer("GUI", "MeowX");
}
- if (keyFile.has_key ("GUI", "MeowY")) {
- meowY = keyFile.get_integer ("GUI", "MeowY");
+ if (keyFile.has_key("GUI", "MeowY")) {
+ meowY = keyFile.get_integer("GUI", "MeowY");
}
- if (keyFile.has_key ("GUI", "WindowMaximized")) {
- windowMaximized = keyFile.get_boolean ("GUI", "WindowMaximized");
+ if (keyFile.has_key("GUI", "WindowMaximized")) {
+ windowMaximized = keyFile.get_boolean("GUI", "WindowMaximized");
}
- if (keyFile.has_key ("GUI", "DetailWindowWidth")) {
- detailWindowWidth = keyFile.get_integer ("GUI", "DetailWindowWidth");
+ if (keyFile.has_key("GUI", "DetailWindowWidth")) {
+ detailWindowWidth = keyFile.get_integer("GUI", "DetailWindowWidth");
}
- if (keyFile.has_key ("GUI", "DetailWindowHeight")) {
- detailWindowHeight = keyFile.get_integer ("GUI", "DetailWindowHeight");
+ if (keyFile.has_key("GUI", "DetailWindowHeight")) {
+ detailWindowHeight = keyFile.get_integer("GUI", "DetailWindowHeight");
}
- if (keyFile.has_key ("GUI", "DirBrowserWidth")) {
- dirBrowserWidth = keyFile.get_integer ("GUI", "DirBrowserWidth");
+ if (keyFile.has_key("GUI", "DirBrowserWidth")) {
+ dirBrowserWidth = keyFile.get_integer("GUI", "DirBrowserWidth");
}
- if (keyFile.has_key ("GUI", "DirBrowserHeight")) {
- dirBrowserHeight = keyFile.get_integer ("GUI", "DirBrowserHeight");
+ if (keyFile.has_key("GUI", "DirBrowserHeight")) {
+ dirBrowserHeight = keyFile.get_integer("GUI", "DirBrowserHeight");
}
- if (keyFile.has_key ("GUI", "SortType")) {
- dirBrowserSortType = static_cast (keyFile.get_integer ("GUI", "SortType"));
+ if (keyFile.has_key("GUI", "SortType")) {
+ dirBrowserSortType = static_cast(keyFile.get_integer("GUI", "SortType"));
}
- if (keyFile.has_key ("GUI", "PreferencesWidth")) {
- preferencesWidth = keyFile.get_integer ("GUI", "PreferencesWidth");
+ if (keyFile.has_key("GUI", "PreferencesWidth")) {
+ preferencesWidth = keyFile.get_integer("GUI", "PreferencesWidth");
}
- if (keyFile.has_key ("GUI", "PreferencesHeight")) {
- preferencesHeight = keyFile.get_integer ("GUI", "PreferencesHeight");
+ if (keyFile.has_key("GUI", "PreferencesHeight")) {
+ preferencesHeight = keyFile.get_integer("GUI", "PreferencesHeight");
}
- if (keyFile.has_key ("GUI", "SaveAsDialogWidth")) {
- saveAsDialogWidth = keyFile.get_integer ("GUI", "SaveAsDialogWidth");
+ if (keyFile.has_key("GUI", "SaveAsDialogWidth")) {
+ saveAsDialogWidth = keyFile.get_integer("GUI", "SaveAsDialogWidth");
}
- if (keyFile.has_key ("GUI", "SaveAsDialogHeight")) {
- saveAsDialogHeight = keyFile.get_integer ("GUI", "SaveAsDialogHeight");
+ if (keyFile.has_key("GUI", "SaveAsDialogHeight")) {
+ saveAsDialogHeight = keyFile.get_integer("GUI", "SaveAsDialogHeight");
}
- if (keyFile.has_key ("GUI", "ToolPanelWidth")) {
- toolPanelWidth = keyFile.get_integer ("GUI", "ToolPanelWidth");
+ if (keyFile.has_key("GUI", "ToolPanelWidth")) {
+ toolPanelWidth = keyFile.get_integer("GUI", "ToolPanelWidth");
}
- if (keyFile.has_key ("GUI", "BrowserToolPanelWidth")) {
- browserToolPanelWidth = keyFile.get_integer ("GUI", "BrowserToolPanelWidth");
+ if (keyFile.has_key("GUI", "BrowserToolPanelWidth")) {
+ browserToolPanelWidth = keyFile.get_integer("GUI", "BrowserToolPanelWidth");
}
- if (keyFile.has_key ("GUI", "BrowserToolPanelHeight")) {
- browserToolPanelHeight = keyFile.get_integer ("GUI", "BrowserToolPanelHeight");
+ if (keyFile.has_key("GUI", "BrowserToolPanelHeight")) {
+ browserToolPanelHeight = keyFile.get_integer("GUI", "BrowserToolPanelHeight");
}
- if (keyFile.has_key ("GUI", "BrowserToolPanelOpened")) {
- browserToolPanelOpened = keyFile.get_boolean ("GUI", "BrowserToolPanelOpened");
+ if (keyFile.has_key("GUI", "BrowserToolPanelOpened")) {
+ browserToolPanelOpened = keyFile.get_boolean("GUI", "BrowserToolPanelOpened");
}
- if (keyFile.has_key ("GUI", "BrowserDirPanelOpened")) {
- browserDirPanelOpened = keyFile.get_boolean ("GUI", "BrowserDirPanelOpened");
+ if (keyFile.has_key("GUI", "BrowserDirPanelOpened")) {
+ browserDirPanelOpened = keyFile.get_boolean("GUI", "BrowserDirPanelOpened");
}
- if (keyFile.has_key ("GUI", "EditorFilmStripOpened")) {
- editorFilmStripOpened = keyFile.get_boolean ("GUI", "EditorFilmStripOpened");
+ if (keyFile.has_key("GUI", "EditorFilmStripOpened")) {
+ editorFilmStripOpened = keyFile.get_boolean("GUI", "EditorFilmStripOpened");
}
- if (keyFile.has_key ("GUI", "HistoryPanelWidth")) {
- historyPanelWidth = keyFile.get_integer ("GUI", "HistoryPanelWidth");
+ if (keyFile.has_key("GUI", "HistoryPanelWidth")) {
+ historyPanelWidth = keyFile.get_integer("GUI", "HistoryPanelWidth");
}
- if (keyFile.has_key ("GUI", "FontFamily")) {
- fontFamily = keyFile.get_string ("GUI", "FontFamily");
+ if (keyFile.has_key("GUI", "FontFamily")) {
+ fontFamily = keyFile.get_string("GUI", "FontFamily");
}
- if (keyFile.has_key ("GUI", "FontSize")) {
- fontSize = keyFile.get_integer ("GUI", "FontSize");
+ if (keyFile.has_key("GUI", "FontSize")) {
+ fontSize = keyFile.get_integer("GUI", "FontSize");
}
- if (keyFile.has_key ("GUI", "CPFontFamily")) {
- CPFontFamily = keyFile.get_string ("GUI", "CPFontFamily");
+ if (keyFile.has_key("GUI", "CPFontFamily")) {
+ CPFontFamily = keyFile.get_string("GUI", "CPFontFamily");
}
- if (keyFile.has_key ("GUI", "CPFontSize")) {
- CPFontSize = keyFile.get_integer ("GUI", "CPFontSize");
+ if (keyFile.has_key("GUI", "CPFontSize")) {
+ CPFontSize = keyFile.get_integer("GUI", "CPFontSize");
}
- if (keyFile.has_key ("GUI", "LastPreviewScale")) {
- lastScale = keyFile.get_integer ("GUI", "LastPreviewScale");
+ if (keyFile.has_key("GUI", "LastPreviewScale")) {
+ lastScale = keyFile.get_integer("GUI", "LastPreviewScale");
}
- if (keyFile.has_key ("GUI", "LastShowAllExif")) {
- lastShowAllExif = keyFile.get_boolean ("GUI", "LastShowAllExif");
+ if (keyFile.has_key("GUI", "LastShowAllExif")) {
+ lastShowAllExif = keyFile.get_boolean("GUI", "LastShowAllExif");
}
- if (keyFile.has_key ("GUI", "PanAccelFactor")) {
- panAccelFactor = keyFile.get_integer ("GUI", "PanAccelFactor");
+ if (keyFile.has_key("GUI", "PanAccelFactor")) {
+ panAccelFactor = keyFile.get_integer("GUI", "PanAccelFactor");
}
- if (keyFile.has_key ("GUI", "RememberZoomAndPan")) {
- rememberZoomAndPan = keyFile.get_boolean ("GUI", "RememberZoomAndPan");
+ if (keyFile.has_key("GUI", "RememberZoomAndPan")) {
+ rememberZoomAndPan = keyFile.get_boolean("GUI", "RememberZoomAndPan");
}
- if (keyFile.has_key ("GUI", "LastCropSize")) {
- lastCropSize = keyFile.get_integer ("GUI", "LastCropSize");
+ if (keyFile.has_key("GUI", "LastCropSize")) {
+ lastCropSize = keyFile.get_integer("GUI", "LastCropSize");
}
- if (keyFile.has_key ("GUI", "ShowHistory")) {
- showHistory = keyFile.get_boolean ("GUI", "ShowHistory");
+ if (keyFile.has_key("GUI", "ShowHistory")) {
+ showHistory = keyFile.get_boolean("GUI", "ShowHistory");
}
- if (keyFile.has_key ("GUI", "ShowFilePanelState")) {
- showFilePanelState = keyFile.get_integer ("GUI", "ShowFilePanelState");
+ if (keyFile.has_key("GUI", "ShowFilePanelState")) {
+ showFilePanelState = keyFile.get_integer("GUI", "ShowFilePanelState");
}
- if (keyFile.has_key ("GUI", "ShowInfo")) {
- showInfo = keyFile.get_boolean ("GUI", "ShowInfo");
+ if (keyFile.has_key("GUI", "ShowInfo")) {
+ showInfo = keyFile.get_boolean("GUI", "ShowInfo");
}
- if (keyFile.has_key ("GUI", "MainNBVertical")) {
- mainNBVertical = keyFile.get_boolean ("GUI", "MainNBVertical");
+ if (keyFile.has_key("GUI", "MainNBVertical")) {
+ mainNBVertical = keyFile.get_boolean("GUI", "MainNBVertical");
}
- if (keyFile.has_key ("GUI", "ShowClippedHighlights")) {
- showClippedHighlights = keyFile.get_boolean ("GUI", "ShowClippedHighlights");
+ if (keyFile.has_key("GUI", "ShowClippedHighlights")) {
+ showClippedHighlights = keyFile.get_boolean("GUI", "ShowClippedHighlights");
}
- if (keyFile.has_key ("GUI", "ShowClippedShadows")) {
- showClippedShadows = keyFile.get_boolean ("GUI", "ShowClippedShadows");
+ if (keyFile.has_key("GUI", "ShowClippedShadows")) {
+ showClippedShadows = keyFile.get_boolean("GUI", "ShowClippedShadows");
}
- if (keyFile.has_key ("GUI", "FrameColor")) {
- bgcolor = keyFile.get_integer ("GUI", "FrameColor");
+ if (keyFile.has_key("GUI", "FrameColor")) {
+ bgcolor = keyFile.get_integer("GUI", "FrameColor");
}
- if (keyFile.has_key ("GUI", "ProcessingQueueEnbled")) {
- procQueueEnabled = keyFile.get_boolean ("GUI", "ProcessingQueueEnbled");
+ if (keyFile.has_key("GUI", "ProcessingQueueEnbled")) {
+ procQueueEnabled = keyFile.get_boolean("GUI", "ProcessingQueueEnbled");
}
- if (keyFile.has_key ("GUI", "ToolPanelsExpanded")) {
- tpOpen = keyFile.get_integer_list ("GUI", "ToolPanelsExpanded");
+ if (keyFile.has_key("GUI", "ToolPanelsExpanded")) {
+ tpOpen = keyFile.get_integer_list("GUI", "ToolPanelsExpanded");
}
- if (keyFile.has_key ("GUI", "ToolPanelsExpandedAutoSave")) {
- autoSaveTpOpen = keyFile.get_boolean ("GUI", "ToolPanelsExpandedAutoSave");
+ if (keyFile.has_key("GUI", "ToolPanelsExpandedAutoSave")) {
+ autoSaveTpOpen = keyFile.get_boolean("GUI", "ToolPanelsExpandedAutoSave");
}
- if (keyFile.has_key ("GUI", "MultiDisplayMode")) {
- multiDisplayMode = keyFile.get_integer ("GUI", "MultiDisplayMode");
+ if (keyFile.has_key("GUI", "MultiDisplayMode")) {
+ multiDisplayMode = keyFile.get_integer("GUI", "MultiDisplayMode");
}
//if (keyFile.has_key ("GUI", "CurvePanelsExpanded")) crvOpen = keyFile.get_integer_list ("GUI", "CurvePanelsExpanded");
- if (keyFile.has_key ("GUI", "CutOverlayBrush")) {
- cutOverlayBrush = keyFile.get_double_list ("GUI", "CutOverlayBrush");
+ if (keyFile.has_key("GUI", "CutOverlayBrush")) {
+ cutOverlayBrush = keyFile.get_double_list("GUI", "CutOverlayBrush");
}
- if (keyFile.has_key ("GUI", "NavGuideBrush")) {
- navGuideBrush = keyFile.get_double_list ("GUI", "NavGuideBrush");
+ if (keyFile.has_key("GUI", "NavGuideBrush")) {
+ navGuideBrush = keyFile.get_double_list("GUI", "NavGuideBrush");
}
- if (keyFile.has_key ("GUI", "HistogramPosition")) {
- histogramPosition = keyFile.get_integer ("GUI", "HistogramPosition");
+ if (keyFile.has_key("GUI", "HistogramPosition")) {
+ histogramPosition = keyFile.get_integer("GUI", "HistogramPosition");
}
- if (keyFile.has_key ("GUI", "HistogramBar")) {
- histogramBar = keyFile.get_boolean ("GUI", "HistogramBar");
+ if (keyFile.has_key("GUI", "HistogramBar")) {
+ histogramBar = keyFile.get_boolean("GUI", "HistogramBar");
}
- if (keyFile.has_key ("GUI", "HistogramFullMode")) {
- histogramFullMode = keyFile.get_boolean ("GUI", "HistogramFullMode");
+ if (keyFile.has_key("GUI", "HistogramFullMode")) {
+ histogramFullMode = keyFile.get_boolean("GUI", "HistogramFullMode");
}
- if (keyFile.has_key ("GUI", "NavigatorRGBUnit")) {
- navRGBUnit = (NavigatorUnit)keyFile.get_integer ("GUI", "NavigatorRGBUnit");
+ if (keyFile.has_key("GUI", "NavigatorRGBUnit")) {
+ navRGBUnit = (NavigatorUnit)keyFile.get_integer("GUI", "NavigatorRGBUnit");
}
- if (keyFile.has_key ("GUI", "NavigatorHSVUnit")) {
- navHSVUnit = (NavigatorUnit)keyFile.get_integer ("GUI", "NavigatorHSVUnit");
+ if (keyFile.has_key("GUI", "NavigatorHSVUnit")) {
+ navHSVUnit = (NavigatorUnit)keyFile.get_integer("GUI", "NavigatorHSVUnit");
}
- if (keyFile.has_key ("GUI", "ShowFilmStripToolBar")) {
- showFilmStripToolBar = keyFile.get_boolean ("GUI", "ShowFilmStripToolBar");
+ if (keyFile.has_key("GUI", "ShowFilmStripToolBar")) {
+ showFilmStripToolBar = keyFile.get_boolean("GUI", "ShowFilmStripToolBar");
}
- if (keyFile.has_key ("GUI", "FileBrowserToolbarSingleRow")) {
- FileBrowserToolbarSingleRow = keyFile.get_boolean ("GUI", "FileBrowserToolbarSingleRow");
+ if (keyFile.has_key("GUI", "FileBrowserToolbarSingleRow")) {
+ FileBrowserToolbarSingleRow = keyFile.get_boolean("GUI", "FileBrowserToolbarSingleRow");
}
#if defined(__linux__) && ((GTK_MAJOR_VERSION == 3 && GTK_MINOR_VERSION > 18) || GTK_MAJOR_VERSION > 3)
// Cannot scroll toolbox with mousewheel when HideTPVScrollbar=true #3413
hideTPVScrollbar = false;
#else
- if (keyFile.has_key ("GUI", "HideTPVScrollbar")) {
- hideTPVScrollbar = keyFile.get_boolean ("GUI", "HideTPVScrollbar");
+
+ if (keyFile.has_key("GUI", "HideTPVScrollbar")) {
+ hideTPVScrollbar = keyFile.get_boolean("GUI", "HideTPVScrollbar");
}
+
#endif
- if (keyFile.has_key ("GUI", "UseIconNoText")) {
- UseIconNoText = keyFile.get_boolean ("GUI", "UseIconNoText");
+
+ if (keyFile.has_key("GUI", "UseIconNoText")) {
+ UseIconNoText = keyFile.get_boolean("GUI", "UseIconNoText");
}
- if (keyFile.has_key ("GUI", "HistogramWorking")) {
- rtSettings.HistogramWorking = keyFile.get_boolean ("GUI", "HistogramWorking");
+ if (keyFile.has_key("GUI", "HistogramWorking")) {
+ rtSettings.HistogramWorking = keyFile.get_boolean("GUI", "HistogramWorking");
}
- if (keyFile.has_key ("GUI", "CurveBBoxPosition")) {
- curvebboxpos = keyFile.get_integer ("GUI", "CurveBBoxPosition");
+ if (keyFile.has_key("GUI", "CurveBBoxPosition")) {
+ curvebboxpos = keyFile.get_integer("GUI", "CurveBBoxPosition");
}
}
- if (keyFile.has_group ("Crop Settings")) {
- if (keyFile.has_key ("Crop Settings", "PPI")) {
- cropPPI = keyFile.get_integer ("Crop Settings", "PPI");
+ if (keyFile.has_group("Crop Settings")) {
+ if (keyFile.has_key("Crop Settings", "PPI")) {
+ cropPPI = keyFile.get_integer("Crop Settings", "PPI");
}
+
if (keyFile.has_key("Crop Settings", "GuidesMode")) {
cropGuides = CropGuidesMode(std::max(int(CROP_GUIDE_NONE), std::min(keyFile.get_integer("Crop Settings", "GuidesMode"), int(CROP_GUIDE_FULL))));
}
+
if (keyFile.has_key("Crop Settings", "AutoFit")) {
cropAutoFit = keyFile.get_boolean("Crop Settings", "AutoFit");
}
}
- if (keyFile.has_group ("Color Management")) {
- if (keyFile.has_key ("Color Management", "ICCDirectory")) {
- rtSettings.iccDirectory = keyFile.get_string ("Color Management", "ICCDirectory");
+ if (keyFile.has_group("Color Management")) {
+ if (keyFile.has_key("Color Management", "ICCDirectory")) {
+ rtSettings.iccDirectory = keyFile.get_string("Color Management", "ICCDirectory");
}
- if (keyFile.has_key ("Color Management", "PrinterIntent")) {
- rtSettings.printerIntent = static_cast (keyFile.get_integer ("Color Management", "PrinterIntent"));
+ if (keyFile.has_key("Color Management", "PrinterIntent")) {
+ rtSettings.printerIntent = static_cast(keyFile.get_integer("Color Management", "PrinterIntent"));
}
- if (keyFile.has_key ("Color Management", "PrinterBPC")) {
- rtSettings.printerBPC = keyFile.get_boolean ("Color Management", "PrinterBPC");
+ if (keyFile.has_key("Color Management", "PrinterBPC")) {
+ rtSettings.printerBPC = keyFile.get_boolean("Color Management", "PrinterBPC");
}
- if (keyFile.has_key ("Color Management", "PrinterProfile")) {
- rtSettings.printerProfile = keyFile.get_string ("Color Management", "PrinterProfile");
+ if (keyFile.has_key("Color Management", "PrinterProfile")) {
+ rtSettings.printerProfile = keyFile.get_string("Color Management", "PrinterProfile");
}
- if (keyFile.has_key ("Color Management", "MonitorProfile")) {
- rtSettings.monitorProfile = keyFile.get_string ("Color Management", "MonitorProfile");
+ if (keyFile.has_key("Color Management", "MonitorProfile")) {
+ rtSettings.monitorProfile = keyFile.get_string("Color Management", "MonitorProfile");
}
- if (keyFile.has_key ("Color Management", "AutoMonitorProfile")) {
- rtSettings.autoMonitorProfile = keyFile.get_boolean ("Color Management", "AutoMonitorProfile");
+ if (keyFile.has_key("Color Management", "AutoMonitorProfile")) {
+ rtSettings.autoMonitorProfile = keyFile.get_boolean("Color Management", "AutoMonitorProfile");
}
- if (keyFile.has_key ("Color Management", "Autocielab")) {
- rtSettings.autocielab = keyFile.get_boolean ("Color Management", "Autocielab");
+ if (keyFile.has_key("Color Management", "Autocielab")) {
+ rtSettings.autocielab = keyFile.get_boolean("Color Management", "Autocielab");
}
- if (keyFile.has_key ("Color Management", "RGBcurvesLumamode_Gamut")) {
- rtSettings.rgbcurveslumamode_gamut = keyFile.get_boolean ("Color Management", "RGBcurvesLumamode_Gamut");
+ if (keyFile.has_key("Color Management", "RGBcurvesLumamode_Gamut")) {
+ rtSettings.rgbcurveslumamode_gamut = keyFile.get_boolean("Color Management", "RGBcurvesLumamode_Gamut");
}
- if (keyFile.has_key ("Color Management", "Intent")) {
- rtSettings.monitorIntent = static_cast (keyFile.get_integer ("Color Management", "Intent"));
+ if (keyFile.has_key("Color Management", "Intent")) {
+ rtSettings.monitorIntent = static_cast(keyFile.get_integer("Color Management", "Intent"));
}
- if (keyFile.has_key ("Color Management", "MonitorBPC")) {
- rtSettings.monitorBPC = keyFile.get_boolean ("Color Management", "MonitorBPC");
+ if (keyFile.has_key("Color Management", "MonitorBPC")) {
+ rtSettings.monitorBPC = keyFile.get_boolean("Color Management", "MonitorBPC");
}
- if (keyFile.has_key ("Color Management", "CRI")) {
- rtSettings.CRI_color = keyFile.get_integer ("Color Management", "CRI");
+ if (keyFile.has_key("Color Management", "CRI")) {
+ rtSettings.CRI_color = keyFile.get_integer("Color Management", "CRI");
}
- if (keyFile.has_key ("Color Management", "DenoiseLabgamma")) {
- rtSettings.denoiselabgamma = keyFile.get_integer ("Color Management", "DenoiseLabgamma");
+ if (keyFile.has_key("Color Management", "DenoiseLabgamma")) {
+ rtSettings.denoiselabgamma = keyFile.get_integer("Color Management", "DenoiseLabgamma");
}
/*
@@ -1407,332 +1431,401 @@ void Options::readFromFile (Glib::ustring fname)
}
*/
- if (keyFile.has_key ("Color Management", "CBDLlevel0")) {
- rtSettings.level0_cbdl = keyFile.get_double ("Color Management", "CBDLlevel0");
+ if (keyFile.has_key("Color Management", "CBDLlevel0")) {
+ rtSettings.level0_cbdl = keyFile.get_double("Color Management", "CBDLlevel0");
}
- if (keyFile.has_key ("Color Management", "CBDLlevel123")) {
- rtSettings.level123_cbdl = keyFile.get_double ("Color Management", "CBDLlevel123");
+ if (keyFile.has_key("Color Management", "CBDLlevel123")) {
+ rtSettings.level123_cbdl = keyFile.get_double("Color Management", "CBDLlevel123");
}
//if (keyFile.has_key ("Color Management", "Colortoningab")) rtSettings.colortoningab = keyFile.get_double("Color Management", "Colortoningab");
//if (keyFile.has_key ("Color Management", "Decaction")) rtSettings.decaction = keyFile.get_double("Color Management", "Decaction");
- if (keyFile.has_key ("Color Management", "WhiteBalanceSpotSize")) {
- whiteBalanceSpotSize = keyFile.get_integer ("Color Management", "WhiteBalanceSpotSize");
+ if (keyFile.has_key("Color Management", "WhiteBalanceSpotSize")) {
+ whiteBalanceSpotSize = keyFile.get_integer("Color Management", "WhiteBalanceSpotSize");
}
- if ( keyFile.has_key ("Color Management", "GamutICC")) {
- rtSettings.gamutICC = keyFile.get_boolean ("Color Management", "GamutICC");
+ if (keyFile.has_key("Color Management", "GamutICC")) {
+ rtSettings.gamutICC = keyFile.get_boolean("Color Management", "GamutICC");
}
- if ( keyFile.has_key ("Color Management", "AdobeRGB")) {
- rtSettings.adobe = keyFile.get_string ("Color Management", "AdobeRGB");
+ if (keyFile.has_key("Color Management", "AdobeRGB")) {
+ rtSettings.adobe = keyFile.get_string("Color Management", "AdobeRGB");
+ if (rtSettings.adobe == "RT_Medium_gsRGB") {
+ rtSettings.adobe = "RTv4_Medium";
+ }
}
- if ( keyFile.has_key ("Color Management", "ProPhoto")) {
- rtSettings.prophoto = keyFile.get_string ("Color Management", "ProPhoto");
+ if (keyFile.has_key("Color Management", "ProPhoto")) {
+ rtSettings.prophoto = keyFile.get_string("Color Management", "ProPhoto");
+ if (rtSettings.prophoto == "RT_Large_gBT709") {
+ rtSettings.prophoto = "RTv4_Large";
+ }
}
- if ( keyFile.has_key ("Color Management", "ProPhoto10")) {
- rtSettings.prophoto10 = keyFile.get_string ("Color Management", "ProPhoto10");
+ if (keyFile.has_key("Color Management", "WideGamut")) {
+ rtSettings.widegamut = keyFile.get_string("Color Management", "WideGamut");
+ if (rtSettings.widegamut == "WideGamutRGB") {
+ rtSettings.widegamut = "RTv4_Wide";
+ }
}
- if ( keyFile.has_key ("Color Management", "WideGamut")) {
- rtSettings.widegamut = keyFile.get_string ("Color Management", "WideGamut");
+ if (keyFile.has_key("Color Management", "sRGB")) {
+ rtSettings.srgb = keyFile.get_string("Color Management", "sRGB");
+ if (rtSettings.srgb == "RT_sRGB") {
+ rtSettings.srgb = "RTv4_sRGB";
+ }
}
- if ( keyFile.has_key ("Color Management", "sRGB")) {
- rtSettings.srgb = keyFile.get_string ("Color Management", "sRGB");
+ if (keyFile.has_key("Color Management", "Beta")) {
+ rtSettings.beta = keyFile.get_string("Color Management", "Beta");
+ if (rtSettings.beta == "BetaRGB") {
+ rtSettings.beta = "RTv4_Beta";
+ }
}
- if ( keyFile.has_key ("Color Management", "sRGB10")) {
- rtSettings.srgb10 = keyFile.get_string ("Color Management", "sRGB10");
+ if (keyFile.has_key("Color Management", "Best")) {
+ rtSettings.best = keyFile.get_string("Color Management", "Best");
+ if (rtSettings.best == "BestRGB") {
+ rtSettings.best = "RTv4_Best";
+ }
}
- if ( keyFile.has_key ("Color Management", "Beta")) {
- rtSettings.beta = keyFile.get_string ("Color Management", "Beta");
+ if (keyFile.has_key("Color Management", "Rec2020")) {
+ rtSettings.rec2020 = keyFile.get_string("Color Management", "Rec2020");
+ if (rtSettings.rec2020 == "Rec2020") {
+ rtSettings.rec2020 = "RTv4_Rec2020";
+ }
}
- if ( keyFile.has_key ("Color Management", "Best")) {
- rtSettings.best = keyFile.get_string ("Color Management", "Best");
+ if (keyFile.has_key("Color Management", "Bruce")) {
+ rtSettings.bruce = keyFile.get_string("Color Management", "Bruce");
+ if (rtSettings.bruce == "Bruce") {
+ rtSettings.bruce = "RTv4_Bruce";
+ }
}
- if ( keyFile.has_key ("Color Management", "Rec2020")) {
- rtSettings.rec2020 = keyFile.get_string ("Color Management", "Rec2020");
+ if (keyFile.has_key("Color Management", "ACES-AP0")) {
+ rtSettings.ACESp0 = keyFile.get_string("Color Management", "ACES-AP0");
}
- if ( keyFile.has_key ("Color Management", "Bruce")) {
- rtSettings.bruce = keyFile.get_string ("Color Management", "Bruce");
+ if (keyFile.has_key("Color Management", "ACES-AP1")) {
+ rtSettings.ACESp1 = keyFile.get_string("Color Management", "ACES-AP1");
}
- if ( keyFile.has_key ("Color Management", "GamutLch")) {
- rtSettings.gamutLch = keyFile.get_boolean ("Color Management", "GamutLch");
+ if (keyFile.has_key("Color Management", "GamutLch")) {
+ rtSettings.gamutLch = keyFile.get_boolean("Color Management", "GamutLch");
}
- if ( keyFile.has_key ("Color Management", "ProtectRed")) {
- rtSettings.protectred = keyFile.get_integer ("Color Management", "ProtectRed");
+ if (keyFile.has_key("Color Management", "ProtectRed")) {
+ rtSettings.protectred = keyFile.get_integer("Color Management", "ProtectRed");
}
- if ( keyFile.has_key ("Color Management", "ProtectRedH")) {
- rtSettings.protectredh = keyFile.get_double ("Color Management", "ProtectRedH");
+ if (keyFile.has_key("Color Management", "ProtectRedH")) {
+ rtSettings.protectredh = keyFile.get_double("Color Management", "ProtectRedH");
}
- if ( keyFile.has_key ("Color Management", "Amountchroma")) {
- rtSettings.amchroma = keyFile.get_integer ("Color Management", "Amountchroma");
+ if (keyFile.has_key("Color Management", "Amountchroma")) {
+ rtSettings.amchroma = keyFile.get_integer("Color Management", "Amountchroma");
}
- if ( keyFile.has_key ("Color Management", "ClutsDirectory")) {
- clutsDir = keyFile.get_string ("Color Management", "ClutsDirectory");
+ if (keyFile.has_key("Color Management", "ClutsDirectory")) {
+ clutsDir = keyFile.get_string("Color Management", "ClutsDirectory");
}
//if( keyFile.has_key ("Color Management", "Ciebadpixgauss")) rtSettings.ciebadpixgauss = keyFile.get_boolean("Color Management", "Ciebadpixgauss");
}
- if (keyFile.has_group ("Batch Processing")) {
- if (keyFile.has_key ("Batch Processing", "AdjusterBehavior")) {
- baBehav = keyFile.get_integer_list ("Batch Processing", "AdjusterBehavior");
+ if (keyFile.has_group("ICC Profile Creator")) {
+ if (keyFile.has_key("ICC Profile Creator", "PimariesPreset")) {
+ ICCPC_primariesPreset = keyFile.get_string("ICC Profile Creator", "PimariesPreset");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "RedPrimaryX")) {
+ ICCPC_redPrimaryX = keyFile.get_double("ICC Profile Creator", "RedPrimaryX");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "RedPrimaryY")) {
+ ICCPC_redPrimaryY = keyFile.get_double("ICC Profile Creator", "RedPrimaryY");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "GreenPrimaryX")) {
+ ICCPC_greenPrimaryX = keyFile.get_double("ICC Profile Creator", "GreenPrimaryX");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "GreenPrimaryY")) {
+ ICCPC_greenPrimaryY = keyFile.get_double("ICC Profile Creator", "GreenPrimaryY");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "BluePrimaryX")) {
+ ICCPC_bluePrimaryX = keyFile.get_double("ICC Profile Creator", "BluePrimaryX");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "BluePrimaryY")) {
+ ICCPC_bluePrimaryY = keyFile.get_double("ICC Profile Creator", "BluePrimaryY");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "GammaPreset")) {
+ ICCPC_gammaPreset = keyFile.get_string("ICC Profile Creator", "GammaPreset");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "Gamma")) {
+ ICCPC_gamma = keyFile.get_double("ICC Profile Creator", "Gamma");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "Slope")) {
+ ICCPC_slope = keyFile.get_double("ICC Profile Creator", "Slope");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "ProfileVersion")) {
+ ICCPC_profileVersion = keyFile.get_string("ICC Profile Creator", "ProfileVersion");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "Illuminant")) {
+ ICCPC_illuminant = keyFile.get_string("ICC Profile Creator", "Illuminant");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "Description")) {
+ ICCPC_description = keyFile.get_string("ICC Profile Creator", "Description");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "Copyright")) {
+ ICCPC_copyright = keyFile.get_string("ICC Profile Creator", "Copyright");
+ }
+ if (keyFile.has_key("ICC Profile Creator", "AppendParamsToDesc")) {
+ ICCPC_appendParamsToDesc = keyFile.get_boolean("ICC Profile Creator", "AppendParamsToDesc");
}
}
- if (keyFile.has_group ("Sounds")) {
- if (keyFile.has_key ("Sounds", "Enable")) {
- sndEnable = keyFile.get_boolean ("Sounds", "Enable");
- }
-
- if (keyFile.has_key ("Sounds", "BatchQueueDone")) {
- sndBatchQueueDone = keyFile.get_string ("Sounds", "BatchQueueDone");
- }
-
- if (keyFile.has_key ("Sounds", "LngEditProcDone")) {
- sndLngEditProcDone = keyFile.get_string ("Sounds", "LngEditProcDone");
- }
-
- if (keyFile.has_key ("Sounds", "LngEditProcDoneSecs")) {
- sndLngEditProcDoneSecs = keyFile.get_double ("Sounds", "LngEditProcDoneSecs");
+ if (keyFile.has_group("Batch Processing")) {
+ if (keyFile.has_key("Batch Processing", "AdjusterBehavior")) {
+ baBehav = keyFile.get_integer_list("Batch Processing", "AdjusterBehavior");
}
}
- if (keyFile.has_group ("Fast Export")) {
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_sharpening" )) {
- fastexport_bypass_sharpening = keyFile.get_boolean ("Fast Export", "fastexport_bypass_sharpening" );
+ if (keyFile.has_group("Sounds")) {
+ if (keyFile.has_key("Sounds", "Enable")) {
+ sndEnable = keyFile.get_boolean("Sounds", "Enable");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_sharpenEdge" )) {
- fastexport_bypass_sharpenEdge = keyFile.get_boolean ("Fast Export", "fastexport_bypass_sharpenEdge" );
+ if (keyFile.has_key("Sounds", "BatchQueueDone")) {
+ sndBatchQueueDone = keyFile.get_string("Sounds", "BatchQueueDone");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_sharpenMicro" )) {
- fastexport_bypass_sharpenMicro = keyFile.get_boolean ("Fast Export", "fastexport_bypass_sharpenMicro" );
+ if (keyFile.has_key("Sounds", "LngEditProcDone")) {
+ sndLngEditProcDone = keyFile.get_string("Sounds", "LngEditProcDone");
+ }
+
+ if (keyFile.has_key("Sounds", "LngEditProcDoneSecs")) {
+ sndLngEditProcDoneSecs = keyFile.get_double("Sounds", "LngEditProcDoneSecs");
+ }
+ }
+
+ if (keyFile.has_group("Fast Export")) {
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_sharpening")) {
+ fastexport_bypass_sharpening = keyFile.get_boolean("Fast Export", "fastexport_bypass_sharpening");
+ }
+
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_sharpenEdge")) {
+ fastexport_bypass_sharpenEdge = keyFile.get_boolean("Fast Export", "fastexport_bypass_sharpenEdge");
+ }
+
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_sharpenMicro")) {
+ fastexport_bypass_sharpenMicro = keyFile.get_boolean("Fast Export", "fastexport_bypass_sharpenMicro");
}
//if (keyFile.has_key ("Fast Export", "fastexport_bypass_lumaDenoise" )) fastexport_bypass_lumaDenoise = keyFile.get_boolean ("Fast Export", "fastexport_bypass_lumaDenoise" );
//if (keyFile.has_key ("Fast Export", "fastexport_bypass_colorDenoise" )) fastexport_bypass_colorDenoise = keyFile.get_boolean ("Fast Export", "fastexport_bypass_colorDenoise" );
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_defringe" )) {
- fastexport_bypass_defringe = keyFile.get_boolean ("Fast Export", "fastexport_bypass_defringe" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_defringe")) {
+ fastexport_bypass_defringe = keyFile.get_boolean("Fast Export", "fastexport_bypass_defringe");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_dirpyrDenoise" )) {
- fastexport_bypass_dirpyrDenoise = keyFile.get_boolean ("Fast Export", "fastexport_bypass_dirpyrDenoise" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_dirpyrDenoise")) {
+ fastexport_bypass_dirpyrDenoise = keyFile.get_boolean("Fast Export", "fastexport_bypass_dirpyrDenoise");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_dirpyrequalizer" )) {
- fastexport_bypass_dirpyrequalizer = keyFile.get_boolean ("Fast Export", "fastexport_bypass_dirpyrequalizer" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_dirpyrequalizer")) {
+ fastexport_bypass_dirpyrequalizer = keyFile.get_boolean("Fast Export", "fastexport_bypass_dirpyrequalizer");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_wavelet" )) {
- fastexport_bypass_wavelet = keyFile.get_boolean ("Fast Export", "fastexport_bypass_wavelet" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_wavelet")) {
+ fastexport_bypass_wavelet = keyFile.get_boolean("Fast Export", "fastexport_bypass_wavelet");
}
- if (keyFile.has_key ("Fast Export", "fastexport_raw_dmethod" )) {
- fastexport_raw_bayer_method = keyFile.get_string ("Fast Export", "fastexport_raw_dmethod" );
+ if (keyFile.has_key("Fast Export", "fastexport_raw_dmethod")) {
+ fastexport_raw_bayer_method = keyFile.get_string("Fast Export", "fastexport_raw_dmethod");
}
- if (keyFile.has_key ("Fast Export", "fastexport_raw_bayer_method" )) {
- fastexport_raw_bayer_method = keyFile.get_string ("Fast Export", "fastexport_raw_bayer_method" );
+ if (keyFile.has_key("Fast Export", "fastexport_raw_bayer_method")) {
+ fastexport_raw_bayer_method = keyFile.get_string("Fast Export", "fastexport_raw_bayer_method");
}
//if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_all_enhance" )) fastexport_bypass_raw_bayer_all_enhance = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_all_enhance" );
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_dcb_iterations" )) {
- fastexport_bypass_raw_bayer_dcb_iterations = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_dcb_iterations" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_dcb_iterations")) {
+ fastexport_bypass_raw_bayer_dcb_iterations = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_dcb_iterations");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations" )) {
- fastexport_bypass_raw_bayer_dcb_iterations = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations")) {
+ fastexport_bypass_raw_bayer_dcb_iterations = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_dcb_enhance" )) {
- fastexport_bypass_raw_bayer_dcb_enhance = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_dcb_enhance" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_dcb_enhance")) {
+ fastexport_bypass_raw_bayer_dcb_enhance = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_dcb_enhance");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance" )) {
- fastexport_bypass_raw_bayer_dcb_enhance = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance")) {
+ fastexport_bypass_raw_bayer_dcb_enhance = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_lmmse_iterations" )) {
- fastexport_bypass_raw_bayer_lmmse_iterations = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_lmmse_iterations" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_lmmse_iterations")) {
+ fastexport_bypass_raw_bayer_lmmse_iterations = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_lmmse_iterations");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations")) {
- fastexport_bypass_raw_bayer_lmmse_iterations = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations");
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations")) {
+ fastexport_bypass_raw_bayer_lmmse_iterations = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_linenoise" )) {
- fastexport_bypass_raw_bayer_linenoise = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_linenoise" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_linenoise")) {
+ fastexport_bypass_raw_bayer_linenoise = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_linenoise");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_linenoise" )) {
- fastexport_bypass_raw_bayer_linenoise = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_bayer_linenoise" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_bayer_linenoise")) {
+ fastexport_bypass_raw_bayer_linenoise = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_bayer_linenoise");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_greenthresh" )) {
- fastexport_bypass_raw_bayer_greenthresh = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_greenthresh" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_greenthresh")) {
+ fastexport_bypass_raw_bayer_greenthresh = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_greenthresh");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_bayer_greenthresh" )) {
- fastexport_bypass_raw_bayer_greenthresh = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_bayer_greenthresh" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_bayer_greenthresh")) {
+ fastexport_bypass_raw_bayer_greenthresh = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_bayer_greenthresh");
}
- if (keyFile.has_key ("Fast Export", "fastexport_raw_xtrans_method" )) {
- fastexport_raw_xtrans_method = keyFile.get_string ("Fast Export", "fastexport_raw_xtrans_method" );
+ if (keyFile.has_key("Fast Export", "fastexport_raw_xtrans_method")) {
+ fastexport_raw_xtrans_method = keyFile.get_string("Fast Export", "fastexport_raw_xtrans_method");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_ccSteps" )) {
- fastexport_bypass_raw_ccSteps = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_ccSteps" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_ccSteps")) {
+ fastexport_bypass_raw_ccSteps = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_ccSteps");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_ca" )) {
- fastexport_bypass_raw_ca = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_ca" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_ca")) {
+ fastexport_bypass_raw_ca = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_ca");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_df" )) {
- fastexport_bypass_raw_df = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_df" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_df")) {
+ fastexport_bypass_raw_df = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_df");
}
- if (keyFile.has_key ("Fast Export", "fastexport_bypass_raw_ff" )) {
- fastexport_bypass_raw_ff = keyFile.get_boolean ("Fast Export", "fastexport_bypass_raw_ff" );
+ if (keyFile.has_key("Fast Export", "fastexport_bypass_raw_ff")) {
+ fastexport_bypass_raw_ff = keyFile.get_boolean("Fast Export", "fastexport_bypass_raw_ff");
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_input" )) {
- fastexport_icm_input = keyFile.get_string ("Fast Export", "fastexport_icm_input" );
+ if (keyFile.has_key("Fast Export", "fastexport_icm_input")) {
+ fastexport_icm_input_profile = keyFile.get_string("Fast Export", "fastexport_icm_input");
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_working" )) {
- fastexport_icm_working = keyFile.get_string ("Fast Export", "fastexport_icm_working" );
+ if (keyFile.has_key("Fast Export", "fastexport_icm_working")) {
+ fastexport_icm_working_profile = keyFile.get_string("Fast Export", "fastexport_icm_working");
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_output" )) {
- fastexport_icm_output = keyFile.get_string ("Fast Export", "fastexport_icm_output" );
+ if (keyFile.has_key("Fast Export", "fastexport_icm_output")) {
+ fastexport_icm_output_profile = keyFile.get_string("Fast Export", "fastexport_icm_output");
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_output_intent" )) {
- fastexport_icm_outputIntent = static_cast (keyFile.get_integer ("Fast Export", "fastexport_icm_output_intent" ));
+ if (keyFile.has_key("Fast Export", "fastexport_icm_output_intent")) {
+ fastexport_icm_outputIntent = static_cast(keyFile.get_integer("Fast Export", "fastexport_icm_output_intent"));
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_output_bpc" )) {
- fastexport_icm_outputBPC = keyFile.get_boolean ("Fast Export", "fastexport_icm_output_bpc" );
+ if (keyFile.has_key("Fast Export", "fastexport_icm_output_bpc")) {
+ fastexport_icm_outputBPC = keyFile.get_boolean("Fast Export", "fastexport_icm_output_bpc");
}
- if (keyFile.has_key ("Fast Export", "fastexport_icm_gamma" )) {
- fastexport_icm_gamma = keyFile.get_string ("Fast Export", "fastexport_icm_gamma" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_enabled")) {
+ fastexport_resize_enabled = keyFile.get_boolean("Fast Export", "fastexport_resize_enabled");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_enabled" )) {
- fastexport_resize_enabled = keyFile.get_boolean ("Fast Export", "fastexport_resize_enabled" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_scale")) {
+ fastexport_resize_scale = keyFile.get_double("Fast Export", "fastexport_resize_scale");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_scale" )) {
- fastexport_resize_scale = keyFile.get_double ("Fast Export", "fastexport_resize_scale" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_appliesTo")) {
+ fastexport_resize_appliesTo = keyFile.get_string("Fast Export", "fastexport_resize_appliesTo");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_appliesTo" )) {
- fastexport_resize_appliesTo = keyFile.get_string ("Fast Export", "fastexport_resize_appliesTo" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_method")) {
+ fastexport_resize_method = keyFile.get_string("Fast Export", "fastexport_resize_method");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_method" )) {
- fastexport_resize_method = keyFile.get_string ("Fast Export", "fastexport_resize_method" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_dataspec")) {
+ fastexport_resize_dataspec = keyFile.get_integer("Fast Export", "fastexport_resize_dataspec");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_dataspec" )) {
- fastexport_resize_dataspec = keyFile.get_integer ("Fast Export", "fastexport_resize_dataspec" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_width")) {
+ fastexport_resize_width = keyFile.get_integer("Fast Export", "fastexport_resize_width");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_width" )) {
- fastexport_resize_width = keyFile.get_integer ("Fast Export", "fastexport_resize_width" );
+ if (keyFile.has_key("Fast Export", "fastexport_resize_height")) {
+ fastexport_resize_height = keyFile.get_integer("Fast Export", "fastexport_resize_height");
}
- if (keyFile.has_key ("Fast Export", "fastexport_resize_height" )) {
- fastexport_resize_height = keyFile.get_integer ("Fast Export", "fastexport_resize_height" );
- }
-
- if (keyFile.has_key ("Fast Export", "fastexport_use_fast_pipeline" )) {
- fastexport_use_fast_pipeline = keyFile.get_integer ("Fast Export", "fastexport_use_fast_pipeline" );
+ if (keyFile.has_key("Fast Export", "fastexport_use_fast_pipeline")) {
+ fastexport_use_fast_pipeline = keyFile.get_integer("Fast Export", "fastexport_use_fast_pipeline");
}
}
- if (keyFile.has_group ("Dialogs")) {
- safeDirGet (keyFile, "Dialogs", "LastIccDir", lastIccDir);
- safeDirGet (keyFile, "Dialogs", "LastDarkframeDir", lastDarkframeDir);
- safeDirGet (keyFile, "Dialogs", "LastFlatfieldDir", lastFlatfieldDir);
- safeDirGet (keyFile, "Dialogs", "LastRgbCurvesDir", lastRgbCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastLabCurvesDir", lastLabCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastRetinexDir", lastRetinexDir);
- safeDirGet (keyFile, "Dialogs", "LastDenoiseCurvesDir", lastDenoiseCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastWaveletCurvesDir", lastWaveletCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastPFCurvesDir", lastPFCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastHsvCurvesDir", lastHsvCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastBWCurvesDir", lastBWCurvesDir);
+ if (keyFile.has_group("Dialogs")) {
+ safeDirGet(keyFile, "Dialogs", "LastIccDir", lastIccDir);
+ safeDirGet(keyFile, "Dialogs", "LastDarkframeDir", lastDarkframeDir);
+ safeDirGet(keyFile, "Dialogs", "LastFlatfieldDir", lastFlatfieldDir);
+ safeDirGet(keyFile, "Dialogs", "LastRgbCurvesDir", lastRgbCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastLabCurvesDir", lastLabCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastRetinexDir", lastRetinexDir);
+ safeDirGet(keyFile, "Dialogs", "LastDenoiseCurvesDir", lastDenoiseCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastWaveletCurvesDir", lastWaveletCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastPFCurvesDir", lastPFCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastHsvCurvesDir", lastHsvCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastBWCurvesDir", lastBWCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastToneCurvesDir", lastToneCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastVibranceCurvesDir", lastVibranceCurvesDir);
- safeDirGet (keyFile, "Dialogs", "LastProfilingReferenceDir", lastProfilingReferenceDir);
- safeDirGet (keyFile, "Dialogs", "LastLensProfileDir", lastLensProfileDir);
+ safeDirGet(keyFile, "Dialogs", "LastToneCurvesDir", lastToneCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastVibranceCurvesDir", lastVibranceCurvesDir);
+ safeDirGet(keyFile, "Dialogs", "LastProfilingReferenceDir", lastProfilingReferenceDir);
+ safeDirGet(keyFile, "Dialogs", "LastLensProfileDir", lastLensProfileDir);
+ safeDirGet(keyFile, "Dialogs", "LastICCProfCreatorDir", lastICCProfCreatorDir);
- if (keyFile.has_key ("Dialogs", "GimpPluginShowInfoDialog")) {
- gimpPluginShowInfoDialog = keyFile.get_boolean ("Dialogs", "GimpPluginShowInfoDialog");
+ if (keyFile.has_key("Dialogs", "GimpPluginShowInfoDialog")) {
+ gimpPluginShowInfoDialog = keyFile.get_boolean("Dialogs", "GimpPluginShowInfoDialog");
}
}
- if (keyFile.has_group ("Lensfun")) {
- if (keyFile.has_key ("Lensfun", "DBDirectory")) {
- rtSettings.lensfunDbDirectory = keyFile.get_string ("Lensfun", "DBDirectory");
+ if (keyFile.has_group("Lensfun")) {
+ if (keyFile.has_key("Lensfun", "DBDirectory")) {
+ rtSettings.lensfunDbDirectory = keyFile.get_string("Lensfun", "DBDirectory");
}
}
// --------------------------------------------------------------------------------------------------------
- filterOutParsedExtensions ();
+ filterOutParsedExtensions();
return;
}
} catch (Glib::Error &err) {
- Glib::ustring msg = Glib::ustring::compose ("Options::readFromFile / Error code %1 while reading values from \"%2\":\n%3", err.code(), fname, err.what());
+ Glib::ustring msg = Glib::ustring::compose("Options::readFromFile / Error code %1 while reading values from \"%2\":\n%3", err.code(), fname, err.what());
if (options.rtSettings.verbose) {
- printf ("%s\n", msg.c_str());
+ printf("%s\n", msg.c_str());
}
- throw Error (msg);
+ throw Error(msg);
} catch (...) {
- Glib::ustring msg = Glib::ustring::compose ("Options::readFromFile / Unknown exception while trying to load \"%1\"!", fname);
+ Glib::ustring msg = Glib::ustring::compose("Options::readFromFile / Unknown exception while trying to load \"%1\"!", fname);
if (options.rtSettings.verbose) {
- printf ("%s\n", msg.c_str());
+ printf("%s\n", msg.c_str());
}
- throw Error (msg);
+ throw Error(msg);
}
}
-bool Options::safeDirGet (const Glib::KeyFile& keyFile, const Glib::ustring& section,
- const Glib::ustring& entryName, Glib::ustring& destination)
+bool Options::safeDirGet(const Glib::KeyFile& keyFile, const Glib::ustring& section,
+ const Glib::ustring& entryName, Glib::ustring& destination)
{
try {
- if (keyFile.has_key (section, entryName) && !keyFile.get_string (section, entryName).empty ()) {
- destination = keyFile.get_string (section, entryName);
+ if (keyFile.has_key(section, entryName) && !keyFile.get_string(section, entryName).empty()) {
+ destination = keyFile.get_string(section, entryName);
return true;
}
@@ -1741,7 +1834,7 @@ bool Options::safeDirGet (const Glib::KeyFile& keyFile, const Glib::ustring& sec
return false;
}
-void Options::saveToFile (Glib::ustring fname)
+void Options::saveToFile(Glib::ustring fname)
{
Glib::ustring keyData;
@@ -1750,335 +1843,351 @@ void Options::saveToFile (Glib::ustring fname)
Glib::KeyFile keyFile;
- keyFile.set_boolean ("General", "TabbedEditor", tabbedUI);
- keyFile.set_boolean ("General", "StoreLastProfile", savesParamsAtExit);
+ keyFile.set_boolean("General", "TabbedEditor", tabbedUI);
+ keyFile.set_boolean("General", "StoreLastProfile", savesParamsAtExit);
if (startupDir == STARTUPDIR_HOME) {
- keyFile.set_string ("General", "StartupDirectory", "home");
+ keyFile.set_string("General", "StartupDirectory", "home");
} else if (startupDir == STARTUPDIR_CURRENT) {
- keyFile.set_string ("General", "StartupDirectory", "current");
+ keyFile.set_string("General", "StartupDirectory", "current");
} else if (startupDir == STARTUPDIR_CUSTOM) {
- keyFile.set_string ("General", "StartupDirectory", "custom");
+ keyFile.set_string("General", "StartupDirectory", "custom");
} else if (startupDir == STARTUPDIR_LAST) {
- keyFile.set_string ("General", "StartupDirectory", "last");
+ keyFile.set_string("General", "StartupDirectory", "last");
}
- keyFile.set_string ("General", "StartupPath", startupPath);
- keyFile.set_string ("General", "DateFormat", dateFormat);
- keyFile.set_integer ("General", "AdjusterMinDelay", adjusterMinDelay);
- keyFile.set_integer ("General", "AdjusterMaxDelay", adjusterMaxDelay);
- keyFile.set_boolean ("General", "MultiUser", multiUser);
- keyFile.set_string ("General", "Language", language);
- keyFile.set_boolean ("General", "LanguageAutoDetect", languageAutoDetect);
- keyFile.set_string ("General", "Theme", theme);
- keyFile.set_string ("General", "Version", RTVERSION);
- keyFile.set_string ("General", "DarkFramesPath", rtSettings.darkFramesPath);
- keyFile.set_string ("General", "FlatFieldsPath", rtSettings.flatFieldsPath);
- keyFile.set_boolean ("General", "Verbose", rtSettings.verbose);
- keyFile.set_integer ("External Editor", "EditorKind", editorToSendTo);
- keyFile.set_string ("External Editor", "GimpDir", gimpDir);
- keyFile.set_string ("External Editor", "PhotoshopDir", psDir);
- keyFile.set_string ("External Editor", "CustomEditor", customEditorProg);
+ keyFile.set_string("General", "StartupPath", startupPath);
+ keyFile.set_string("General", "DateFormat", dateFormat);
+ keyFile.set_integer("General", "AdjusterMinDelay", adjusterMinDelay);
+ keyFile.set_integer("General", "AdjusterMaxDelay", adjusterMaxDelay);
+ keyFile.set_boolean("General", "MultiUser", multiUser);
+ keyFile.set_string("General", "Language", language);
+ keyFile.set_boolean("General", "LanguageAutoDetect", languageAutoDetect);
+ keyFile.set_string("General", "Theme", theme);
+ keyFile.set_string("General", "Version", RTVERSION);
+ keyFile.set_string("General", "DarkFramesPath", rtSettings.darkFramesPath);
+ keyFile.set_string("General", "FlatFieldsPath", rtSettings.flatFieldsPath);
+ keyFile.set_boolean("General", "Verbose", rtSettings.verbose);
+ keyFile.set_integer("External Editor", "EditorKind", editorToSendTo);
+ keyFile.set_string("External Editor", "GimpDir", gimpDir);
+ keyFile.set_string("External Editor", "PhotoshopDir", psDir);
+ keyFile.set_string("External Editor", "CustomEditor", customEditorProg);
- keyFile.set_boolean ("File Browser", "BrowseOnlyRaw", fbOnlyRaw);
- keyFile.set_boolean ("File Browser", "BrowserShowsDate", fbShowDateTime);
- keyFile.set_boolean ("File Browser", "BrowserShowsExif", fbShowBasicExif);
- keyFile.set_boolean ("File Browser", "BrowserShowsExpComp", fbShowExpComp);
- keyFile.set_boolean ("File Browser", "BrowserShowsHidden", fbShowHidden);
- keyFile.set_integer ("File Browser", "ThumbnailSize", thumbSize);
- keyFile.set_integer ("File Browser", "ThumbnailSizeTab", thumbSizeTab);
- keyFile.set_integer ("File Browser", "ThumbnailSizeQueue", thumbSizeQueue);
- keyFile.set_integer ("File Browser", "SameThumbSize", sameThumbSize);
- keyFile.set_integer ("File Browser", "MaxPreviewHeight", maxThumbnailHeight);
- keyFile.set_integer ("File Browser", "MaxCacheEntries", maxCacheEntries);
+ keyFile.set_boolean("File Browser", "BrowseOnlyRaw", fbOnlyRaw);
+ keyFile.set_boolean("File Browser", "BrowserShowsDate", fbShowDateTime);
+ keyFile.set_boolean("File Browser", "BrowserShowsExif", fbShowBasicExif);
+ keyFile.set_boolean("File Browser", "BrowserShowsExpComp", fbShowExpComp);
+ keyFile.set_boolean("File Browser", "BrowserShowsHidden", fbShowHidden);
+ keyFile.set_integer("File Browser", "ThumbnailSize", thumbSize);
+ keyFile.set_integer("File Browser", "ThumbnailSizeTab", thumbSizeTab);
+ keyFile.set_integer("File Browser", "ThumbnailSizeQueue", thumbSizeQueue);
+ keyFile.set_integer("File Browser", "SameThumbSize", sameThumbSize);
+ keyFile.set_integer("File Browser", "MaxPreviewHeight", maxThumbnailHeight);
+ keyFile.set_integer("File Browser", "MaxCacheEntries", maxCacheEntries);
Glib::ArrayHandle pext = parseExtensions;
- keyFile.set_string_list ("File Browser", "ParseExtensions", pext);
+ keyFile.set_string_list("File Browser", "ParseExtensions", pext);
Glib::ArrayHandle pextena = parseExtensionsEnabled;
- keyFile.set_integer_list ("File Browser", "ParseExtensionsEnabled", pextena);
- keyFile.set_integer ("File Browser", "ThumbnailArrangement", fbArrangement);
- keyFile.set_integer ("File Browser", "ThumbnailInterpolation", thumbInterp);
+ keyFile.set_integer_list("File Browser", "ParseExtensionsEnabled", pextena);
+ keyFile.set_integer("File Browser", "ThumbnailArrangement", fbArrangement);
+ keyFile.set_integer("File Browser", "ThumbnailInterpolation", thumbInterp);
Glib::ArrayHandle pfav = favoriteDirs;
- keyFile.set_string_list ("File Browser", "FavoriteDirs", pfav);
+ keyFile.set_string_list("File Browser", "FavoriteDirs", pfav);
Glib::ArrayHandle pren = renameTemplates;
- keyFile.set_string_list ("File Browser", "RenameTemplates", pren);
- keyFile.set_boolean ("File Browser", "RenameUseTemplates", renameUseTemplates);
+ keyFile.set_string_list("File Browser", "RenameTemplates", pren);
+ keyFile.set_boolean("File Browser", "RenameUseTemplates", renameUseTemplates);
Glib::ArrayHandle ptzoom = thumbnailZoomRatios;
- keyFile.set_double_list ("File Browser", "ThumbnailZoomRatios", ptzoom);
- keyFile.set_boolean ("File Browser", "OverlayedFileNames", overlayedFileNames);
- keyFile.set_boolean ("File Browser", "FilmStripOverlayedFileNames", filmStripOverlayedFileNames);
- keyFile.set_boolean ("File Browser", "ShowFileNames", showFileNames );
- keyFile.set_boolean ("File Browser", "FilmStripShowFileNames", filmStripShowFileNames );
- keyFile.set_boolean ("File Browser", "InternalThumbIfUntouched", internalThumbIfUntouched );
- keyFile.set_boolean ("File Browser", "menuGroupRank", menuGroupRank);
- keyFile.set_boolean ("File Browser", "menuGroupLabel", menuGroupLabel);
- keyFile.set_boolean ("File Browser", "menuGroupFileOperations", menuGroupFileOperations);
- keyFile.set_boolean ("File Browser", "menuGroupProfileOperations", menuGroupProfileOperations);
- keyFile.set_boolean ("File Browser", "menuGroupExtProg", menuGroupExtProg);
- keyFile.set_integer ("File Browser", "MaxRecentFolders", maxRecentFolders);
+ keyFile.set_double_list("File Browser", "ThumbnailZoomRatios", ptzoom);
+ keyFile.set_boolean("File Browser", "OverlayedFileNames", overlayedFileNames);
+ keyFile.set_boolean("File Browser", "FilmStripOverlayedFileNames", filmStripOverlayedFileNames);
+ keyFile.set_boolean("File Browser", "ShowFileNames", showFileNames);
+ keyFile.set_boolean("File Browser", "FilmStripShowFileNames", filmStripShowFileNames);
+ keyFile.set_boolean("File Browser", "InternalThumbIfUntouched", internalThumbIfUntouched);
+ keyFile.set_boolean("File Browser", "menuGroupRank", menuGroupRank);
+ keyFile.set_boolean("File Browser", "menuGroupLabel", menuGroupLabel);
+ keyFile.set_boolean("File Browser", "menuGroupFileOperations", menuGroupFileOperations);
+ keyFile.set_boolean("File Browser", "menuGroupProfileOperations", menuGroupProfileOperations);
+ keyFile.set_boolean("File Browser", "menuGroupExtProg", menuGroupExtProg);
+ keyFile.set_integer("File Browser", "MaxRecentFolders", maxRecentFolders);
{
std::vector temp;
- temp.reserve (maxRecentFolders);
+ temp.reserve(maxRecentFolders);
- for (unsigned int i = 0; i < std::min (recentFolders.size(), maxRecentFolders); i++) {
- temp.push_back (recentFolders[i]);
+ for (unsigned int i = 0; i < std::min(recentFolders.size(), maxRecentFolders); i++) {
+ temp.push_back(recentFolders[i]);
}
- keyFile.set_string_list ("File Browser", "RecentFolders", temp);
+ keyFile.set_string_list("File Browser", "RecentFolders", temp);
}
- keyFile.set_integer ("Clipping Indication", "HighlightThreshold", highlightThreshold);
- keyFile.set_integer ("Clipping Indication", "ShadowThreshold", shadowThreshold);
- keyFile.set_boolean ("Clipping Indication", "BlinkClipped", blinkClipped);
+ keyFile.set_integer("Clipping Indication", "HighlightThreshold", highlightThreshold);
+ keyFile.set_integer("Clipping Indication", "ShadowThreshold", shadowThreshold);
+ keyFile.set_boolean("Clipping Indication", "BlinkClipped", blinkClipped);
- keyFile.set_integer ("Performance", "RgbDenoiseThreadLimit", rgbDenoiseThreadLimit);
- keyFile.set_double ("Performance", "NRauto", rtSettings.nrauto);
- keyFile.set_double ("Performance", "NRautomax", rtSettings.nrautomax);
- keyFile.set_double ("Performance", "NRhigh", rtSettings.nrhigh);
- keyFile.set_integer ("Performance", "NRWavlevel", rtSettings.nrwavlevel);
- keyFile.set_integer ("Performance", "LevNR", rtSettings.leveldnv);
- keyFile.set_integer ("Performance", "LevNRTI", rtSettings.leveldnti);
- keyFile.set_integer ("Performance", "LevNRAUT", rtSettings.leveldnaut);
- keyFile.set_integer ("Performance", "LevNRLISS", rtSettings.leveldnliss);
- keyFile.set_integer ("Performance", "SIMPLNRAUT", rtSettings.leveldnautsimpl);
- keyFile.set_integer ("Performance", "ClutCacheSize", clutCacheSize);
- keyFile.set_integer ("Performance", "MaxInspectorBuffers", maxInspectorBuffers);
- keyFile.set_integer ("Performance", "InspectorDelay", inspectorDelay);
- keyFile.set_integer ("Performance", "PreviewDemosaicFromSidecar", prevdemo);
- keyFile.set_boolean ("Performance", "Daubechies", rtSettings.daubech);
- keyFile.set_boolean ("Performance", "SerializeTiffRead", serializeTiffRead);
+ keyFile.set_integer("Performance", "RgbDenoiseThreadLimit", rgbDenoiseThreadLimit);
+ keyFile.set_double("Performance", "NRauto", rtSettings.nrauto);
+ keyFile.set_double("Performance", "NRautomax", rtSettings.nrautomax);
+ keyFile.set_double("Performance", "NRhigh", rtSettings.nrhigh);
+ keyFile.set_integer("Performance", "NRWavlevel", rtSettings.nrwavlevel);
+ keyFile.set_integer("Performance", "LevNR", rtSettings.leveldnv);
+ keyFile.set_integer("Performance", "LevNRTI", rtSettings.leveldnti);
+ keyFile.set_integer("Performance", "LevNRAUT", rtSettings.leveldnaut);
+ keyFile.set_integer("Performance", "LevNRLISS", rtSettings.leveldnliss);
+ keyFile.set_integer("Performance", "SIMPLNRAUT", rtSettings.leveldnautsimpl);
+ keyFile.set_integer("Performance", "ClutCacheSize", clutCacheSize);
+ keyFile.set_integer("Performance", "MaxInspectorBuffers", maxInspectorBuffers);
+ keyFile.set_integer("Performance", "InspectorDelay", inspectorDelay);
+ keyFile.set_integer("Performance", "PreviewDemosaicFromSidecar", prevdemo);
+ keyFile.set_boolean("Performance", "Daubechies", rtSettings.daubech);
+ keyFile.set_boolean("Performance", "SerializeTiffRead", serializeTiffRead);
keyFile.set_integer("Performance", "ThumbnailInspectorMode", int(rtSettings.thumbnail_inspector_mode));
- keyFile.set_string ("Output", "Format", saveFormat.format);
- keyFile.set_integer ("Output", "JpegQuality", saveFormat.jpegQuality);
- keyFile.set_integer ("Output", "JpegSubSamp", saveFormat.jpegSubSamp);
- keyFile.set_integer ("Output", "PngBps", saveFormat.pngBits);
- keyFile.set_integer ("Output", "TiffBps", saveFormat.tiffBits);
- keyFile.set_boolean ("Output", "TiffUncompressed", saveFormat.tiffUncompressed);
- keyFile.set_boolean ("Output", "SaveProcParams", saveFormat.saveParams);
+ keyFile.set_string("Output", "Format", saveFormat.format);
+ keyFile.set_integer("Output", "JpegQuality", saveFormat.jpegQuality);
+ keyFile.set_integer("Output", "JpegSubSamp", saveFormat.jpegSubSamp);
+ keyFile.set_integer("Output", "PngBps", saveFormat.pngBits);
+ keyFile.set_integer("Output", "TiffBps", saveFormat.tiffBits);
+ keyFile.set_boolean("Output", "TiffUncompressed", saveFormat.tiffUncompressed);
+ keyFile.set_boolean("Output", "SaveProcParams", saveFormat.saveParams);
- keyFile.set_string ("Output", "FormatBatch", saveFormatBatch.format);
- keyFile.set_integer ("Output", "JpegQualityBatch", saveFormatBatch.jpegQuality);
- keyFile.set_integer ("Output", "JpegSubSampBatch", saveFormatBatch.jpegSubSamp);
- keyFile.set_integer ("Output", "PngBpsBatch", saveFormatBatch.pngBits);
- keyFile.set_integer ("Output", "TiffBpsBatch", saveFormatBatch.tiffBits);
- keyFile.set_boolean ("Output", "TiffUncompressedBatch", saveFormatBatch.tiffUncompressed);
- keyFile.set_boolean ("Output", "SaveProcParamsBatch", saveFormatBatch.saveParams);
+ keyFile.set_string("Output", "FormatBatch", saveFormatBatch.format);
+ keyFile.set_integer("Output", "JpegQualityBatch", saveFormatBatch.jpegQuality);
+ keyFile.set_integer("Output", "JpegSubSampBatch", saveFormatBatch.jpegSubSamp);
+ keyFile.set_integer("Output", "PngBpsBatch", saveFormatBatch.pngBits);
+ keyFile.set_integer("Output", "TiffBpsBatch", saveFormatBatch.tiffBits);
+ keyFile.set_boolean("Output", "TiffUncompressedBatch", saveFormatBatch.tiffUncompressed);
+ keyFile.set_boolean("Output", "SaveProcParamsBatch", saveFormatBatch.saveParams);
- keyFile.set_string ("Output", "PathTemplate", savePathTemplate);
- keyFile.set_string ("Output", "PathFolder", savePathFolder);
- keyFile.set_boolean ("Output", "AutoSuffix", autoSuffix);
- keyFile.set_boolean ("Output", "ForceFormatOpts", forceFormatOpts);
- keyFile.set_integer ("Output", "SaveMethodNum", saveMethodNum);
- keyFile.set_boolean ("Output", "UsePathTemplate", saveUsePathTemplate);
- keyFile.set_string ("Output", "LastSaveAsPath", lastSaveAsPath);
- keyFile.set_boolean ("Output", "OverwriteOutputFile", overwriteOutputFile);
+ keyFile.set_string("Output", "PathTemplate", savePathTemplate);
+ keyFile.set_string("Output", "PathFolder", savePathFolder);
+ keyFile.set_boolean("Output", "AutoSuffix", autoSuffix);
+ keyFile.set_boolean("Output", "ForceFormatOpts", forceFormatOpts);
+ keyFile.set_integer("Output", "SaveMethodNum", saveMethodNum);
+ keyFile.set_boolean("Output", "UsePathTemplate", saveUsePathTemplate);
+ keyFile.set_string("Output", "LastSaveAsPath", lastSaveAsPath);
+ keyFile.set_boolean("Output", "OverwriteOutputFile", overwriteOutputFile);
- keyFile.set_string ("Profiles", "Directory", profilePath);
- keyFile.set_boolean ("Profiles", "UseBundledProfiles", useBundledProfiles);
- keyFile.set_string ("Profiles", "LoadSaveProfilePath", loadSaveProfilePath);
- keyFile.set_string ("Profiles", "RawDefault", defProfRaw);
- keyFile.set_string ("Profiles", "ImgDefault", defProfImg);
- keyFile.set_boolean ("Profiles", "FilledProfile", filledProfile);
- keyFile.set_boolean ("Profiles", "SaveParamsWithFile", saveParamsFile);
- keyFile.set_boolean ("Profiles", "SaveParamsToCache", saveParamsCache);
- keyFile.set_integer ("Profiles", "LoadParamsFromLocation", paramsLoadLocation);
- keyFile.set_string ("Profiles", "CustomProfileBuilderPath", CPBPath);
- keyFile.set_integer ("Profiles", "CustomProfileBuilderKeys", CPBKeys);
+ keyFile.set_string("Profiles", "Directory", profilePath);
+ keyFile.set_boolean("Profiles", "UseBundledProfiles", useBundledProfiles);
+ keyFile.set_string("Profiles", "LoadSaveProfilePath", loadSaveProfilePath);
+ keyFile.set_string("Profiles", "RawDefault", defProfRaw);
+ keyFile.set_string("Profiles", "ImgDefault", defProfImg);
+ keyFile.set_boolean("Profiles", "FilledProfile", filledProfile);
+ keyFile.set_boolean("Profiles", "SaveParamsWithFile", saveParamsFile);
+ keyFile.set_boolean("Profiles", "SaveParamsToCache", saveParamsCache);
+ keyFile.set_integer("Profiles", "LoadParamsFromLocation", paramsLoadLocation);
+ keyFile.set_string("Profiles", "CustomProfileBuilderPath", CPBPath);
+ keyFile.set_integer("Profiles", "CustomProfileBuilderKeys", CPBKeys);
- keyFile.set_integer ("GUI", "WindowWidth", windowWidth);
- keyFile.set_integer ("GUI", "WindowHeight", windowHeight);
- keyFile.set_integer ("GUI", "WindowX", windowX);
- keyFile.set_integer ("GUI", "WindowY", windowY);
- keyFile.set_integer ("GUI", "WindowMonitor", windowMonitor);
- keyFile.set_integer ("GUI", "MeowMonitor", meowMonitor);
- keyFile.set_boolean ("GUI", "MeowFullScreen", meowFullScreen);
- keyFile.set_boolean ("GUI", "MeowMaximized", meowMaximized);
- keyFile.set_integer ("GUI", "MeowWidth", meowWidth);
- keyFile.set_integer ("GUI", "MeowHeight", meowHeight);
- keyFile.set_integer ("GUI", "MeowX", meowX);
- keyFile.set_integer ("GUI", "MeowY", meowY);
- keyFile.set_boolean ("GUI", "WindowMaximized", windowMaximized);
- keyFile.set_integer ("GUI", "DetailWindowWidth", detailWindowWidth);
- keyFile.set_integer ("GUI", "DetailWindowHeight", detailWindowHeight);
- keyFile.set_integer ("GUI", "DirBrowserWidth", dirBrowserWidth);
- keyFile.set_integer ("GUI", "DirBrowserHeight", dirBrowserHeight);
- keyFile.set_integer ("GUI", "SortType", dirBrowserSortType);
- keyFile.set_integer ("GUI", "PreferencesWidth", preferencesWidth);
- keyFile.set_integer ("GUI", "PreferencesHeight", preferencesHeight);
- keyFile.set_integer ("GUI", "SaveAsDialogWidth", saveAsDialogWidth);
- keyFile.set_integer ("GUI", "SaveAsDialogHeight", saveAsDialogHeight);
- keyFile.set_integer ("GUI", "ToolPanelWidth", toolPanelWidth);
- keyFile.set_integer ("GUI", "BrowserToolPanelWidth", browserToolPanelWidth);
- keyFile.set_integer ("GUI", "BrowserToolPanelHeight", browserToolPanelHeight);
- keyFile.set_boolean ("GUI", "BrowserToolPanelOpened", browserToolPanelOpened);
- keyFile.set_boolean ("GUI", "EditorFilmStripOpened", editorFilmStripOpened);
- keyFile.set_boolean ("GUI", "BrowserDirPanelOpened", browserDirPanelOpened);
- keyFile.set_integer ("GUI", "HistoryPanelWidth", historyPanelWidth);
- keyFile.set_string ("GUI", "FontFamily", fontFamily);
- keyFile.set_integer ("GUI", "FontSize", fontSize);
- keyFile.set_string ("GUI", "CPFontFamily", CPFontFamily);
- keyFile.set_integer ("GUI", "CPFontSize", CPFontSize);
- keyFile.set_integer ("GUI", "LastPreviewScale", lastScale);
- keyFile.set_boolean ("GUI", "LastShowAllExif", lastShowAllExif);
- keyFile.set_integer ("GUI", "PanAccelFactor", panAccelFactor);
- keyFile.set_boolean ("GUI", "RememberZoomAndPan", rememberZoomAndPan);
- keyFile.set_integer ("GUI", "LastCropSize", lastCropSize);
- keyFile.set_boolean ("GUI", "ShowHistory", showHistory);
- keyFile.set_integer ("GUI", "ShowFilePanelState", showFilePanelState);
- keyFile.set_boolean ("GUI", "ShowInfo", showInfo);
- keyFile.set_boolean ("GUI", "MainNBVertical", mainNBVertical);
- keyFile.set_boolean ("GUI", "ShowClippedHighlights", showClippedHighlights);
- keyFile.set_boolean ("GUI", "ShowClippedShadows", showClippedShadows);
- keyFile.set_integer ("GUI", "FrameColor", bgcolor);
- keyFile.set_boolean ("GUI", "ProcessingQueueEnbled", procQueueEnabled);
+ keyFile.set_integer("GUI", "WindowWidth", windowWidth);
+ keyFile.set_integer("GUI", "WindowHeight", windowHeight);
+ keyFile.set_integer("GUI", "WindowX", windowX);
+ keyFile.set_integer("GUI", "WindowY", windowY);
+ keyFile.set_integer("GUI", "WindowMonitor", windowMonitor);
+ keyFile.set_integer("GUI", "MeowMonitor", meowMonitor);
+ keyFile.set_boolean("GUI", "MeowFullScreen", meowFullScreen);
+ keyFile.set_boolean("GUI", "MeowMaximized", meowMaximized);
+ keyFile.set_integer("GUI", "MeowWidth", meowWidth);
+ keyFile.set_integer("GUI", "MeowHeight", meowHeight);
+ keyFile.set_integer("GUI", "MeowX", meowX);
+ keyFile.set_integer("GUI", "MeowY", meowY);
+ keyFile.set_boolean("GUI", "WindowMaximized", windowMaximized);
+ keyFile.set_integer("GUI", "DetailWindowWidth", detailWindowWidth);
+ keyFile.set_integer("GUI", "DetailWindowHeight", detailWindowHeight);
+ keyFile.set_integer("GUI", "DirBrowserWidth", dirBrowserWidth);
+ keyFile.set_integer("GUI", "DirBrowserHeight", dirBrowserHeight);
+ keyFile.set_integer("GUI", "SortType", dirBrowserSortType);
+ keyFile.set_integer("GUI", "PreferencesWidth", preferencesWidth);
+ keyFile.set_integer("GUI", "PreferencesHeight", preferencesHeight);
+ keyFile.set_integer("GUI", "SaveAsDialogWidth", saveAsDialogWidth);
+ keyFile.set_integer("GUI", "SaveAsDialogHeight", saveAsDialogHeight);
+ keyFile.set_integer("GUI", "ToolPanelWidth", toolPanelWidth);
+ keyFile.set_integer("GUI", "BrowserToolPanelWidth", browserToolPanelWidth);
+ keyFile.set_integer("GUI", "BrowserToolPanelHeight", browserToolPanelHeight);
+ keyFile.set_boolean("GUI", "BrowserToolPanelOpened", browserToolPanelOpened);
+ keyFile.set_boolean("GUI", "EditorFilmStripOpened", editorFilmStripOpened);
+ keyFile.set_boolean("GUI", "BrowserDirPanelOpened", browserDirPanelOpened);
+ keyFile.set_integer("GUI", "HistoryPanelWidth", historyPanelWidth);
+ keyFile.set_string("GUI", "FontFamily", fontFamily);
+ keyFile.set_integer("GUI", "FontSize", fontSize);
+ keyFile.set_string("GUI", "CPFontFamily", CPFontFamily);
+ keyFile.set_integer("GUI", "CPFontSize", CPFontSize);
+ keyFile.set_integer("GUI", "LastPreviewScale", lastScale);
+ keyFile.set_boolean("GUI", "LastShowAllExif", lastShowAllExif);
+ keyFile.set_integer("GUI", "PanAccelFactor", panAccelFactor);
+ keyFile.set_boolean("GUI", "RememberZoomAndPan", rememberZoomAndPan);
+ keyFile.set_integer("GUI", "LastCropSize", lastCropSize);
+ keyFile.set_boolean("GUI", "ShowHistory", showHistory);
+ keyFile.set_integer("GUI", "ShowFilePanelState", showFilePanelState);
+ keyFile.set_boolean("GUI", "ShowInfo", showInfo);
+ keyFile.set_boolean("GUI", "MainNBVertical", mainNBVertical);
+ keyFile.set_boolean("GUI", "ShowClippedHighlights", showClippedHighlights);
+ keyFile.set_boolean("GUI", "ShowClippedShadows", showClippedShadows);
+ keyFile.set_integer("GUI", "FrameColor", bgcolor);
+ keyFile.set_boolean("GUI", "ProcessingQueueEnbled", procQueueEnabled);
Glib::ArrayHandle tpopen = tpOpen;
- keyFile.set_integer_list ("GUI", "ToolPanelsExpanded", tpopen);
- keyFile.set_boolean ("GUI", "ToolPanelsExpandedAutoSave", autoSaveTpOpen);
- keyFile.set_integer ("GUI", "MultiDisplayMode", multiDisplayMode);
- keyFile.set_double_list ("GUI", "CutOverlayBrush", cutOverlayBrush);
- keyFile.set_double_list ("GUI", "NavGuideBrush", navGuideBrush);
- keyFile.set_integer ("GUI", "HistogramPosition", histogramPosition);
- keyFile.set_boolean ("GUI", "HistogramBar", histogramBar);
- keyFile.set_boolean ("GUI", "HistogramFullMode", histogramFullMode);
- keyFile.set_integer ("GUI", "NavigatorRGBUnit", (int)navRGBUnit);
- keyFile.set_integer ("GUI", "NavigatorHSVUnit", (int)navHSVUnit);
- keyFile.set_boolean ("GUI", "ShowFilmStripToolBar", showFilmStripToolBar);
- keyFile.set_boolean ("GUI", "FileBrowserToolbarSingleRow", FileBrowserToolbarSingleRow);
- keyFile.set_boolean ("GUI", "HideTPVScrollbar", hideTPVScrollbar);
- keyFile.set_boolean ("GUI", "UseIconNoText", UseIconNoText);
- keyFile.set_boolean ("GUI", "HistogramWorking", rtSettings.HistogramWorking);
- keyFile.set_integer ("GUI", "CurveBBoxPosition", curvebboxpos);
+ keyFile.set_integer_list("GUI", "ToolPanelsExpanded", tpopen);
+ keyFile.set_boolean("GUI", "ToolPanelsExpandedAutoSave", autoSaveTpOpen);
+ keyFile.set_integer("GUI", "MultiDisplayMode", multiDisplayMode);
+ keyFile.set_double_list("GUI", "CutOverlayBrush", cutOverlayBrush);
+ keyFile.set_double_list("GUI", "NavGuideBrush", navGuideBrush);
+ keyFile.set_integer("GUI", "HistogramPosition", histogramPosition);
+ keyFile.set_boolean("GUI", "HistogramBar", histogramBar);
+ keyFile.set_boolean("GUI", "HistogramFullMode", histogramFullMode);
+ keyFile.set_integer("GUI", "NavigatorRGBUnit", (int)navRGBUnit);
+ keyFile.set_integer("GUI", "NavigatorHSVUnit", (int)navHSVUnit);
+ keyFile.set_boolean("GUI", "ShowFilmStripToolBar", showFilmStripToolBar);
+ keyFile.set_boolean("GUI", "FileBrowserToolbarSingleRow", FileBrowserToolbarSingleRow);
+ keyFile.set_boolean("GUI", "HideTPVScrollbar", hideTPVScrollbar);
+ keyFile.set_boolean("GUI", "UseIconNoText", UseIconNoText);
+ keyFile.set_boolean("GUI", "HistogramWorking", rtSettings.HistogramWorking);
+ keyFile.set_integer("GUI", "CurveBBoxPosition", curvebboxpos);
//Glib::ArrayHandle crvopen = crvOpen;
//keyFile.set_integer_list ("GUI", "CurvePanelsExpanded", crvopen);
- keyFile.set_integer ("Crop Settings", "PPI", cropPPI);
+ keyFile.set_integer("Crop Settings", "PPI", cropPPI);
keyFile.set_integer("Crop Settings", "GuidesMode", cropGuides);
keyFile.set_boolean("Crop Settings", "AutoFit", cropAutoFit);
- keyFile.set_string ("Color Management", "PrinterProfile", rtSettings.printerProfile);
- keyFile.set_integer ("Color Management", "PrinterIntent", rtSettings.printerIntent);
- keyFile.set_boolean ("Color Management", "PrinterBPC", rtSettings.printerBPC);
+ keyFile.set_string("Color Management", "PrinterProfile", rtSettings.printerProfile);
+ keyFile.set_integer("Color Management", "PrinterIntent", rtSettings.printerIntent);
+ keyFile.set_boolean("Color Management", "PrinterBPC", rtSettings.printerBPC);
- keyFile.set_string ("Color Management", "ICCDirectory", rtSettings.iccDirectory);
- keyFile.set_string ("Color Management", "MonitorProfile", rtSettings.monitorProfile);
- keyFile.set_boolean ("Color Management", "AutoMonitorProfile", rtSettings.autoMonitorProfile);
- keyFile.set_boolean ("Color Management", "Autocielab", rtSettings.autocielab);
- keyFile.set_boolean ("Color Management", "RGBcurvesLumamode_Gamut", rtSettings.rgbcurveslumamode_gamut);
- keyFile.set_integer ("Color Management", "Intent", rtSettings.monitorIntent);
- keyFile.set_boolean ("Color Management", "MonitorBPC", rtSettings.monitorBPC);
+ keyFile.set_string("Color Management", "ICCDirectory", rtSettings.iccDirectory);
+ keyFile.set_string("Color Management", "MonitorProfile", rtSettings.monitorProfile);
+ keyFile.set_boolean("Color Management", "AutoMonitorProfile", rtSettings.autoMonitorProfile);
+ keyFile.set_boolean("Color Management", "Autocielab", rtSettings.autocielab);
+ keyFile.set_boolean("Color Management", "RGBcurvesLumamode_Gamut", rtSettings.rgbcurveslumamode_gamut);
+ keyFile.set_integer("Color Management", "Intent", rtSettings.monitorIntent);
+ keyFile.set_boolean("Color Management", "MonitorBPC", rtSettings.monitorBPC);
//keyFile.set_integer ("Color Management", "view", rtSettings.viewingdevice);
//keyFile.set_integer ("Color Management", "grey", rtSettings.viewingdevicegrey);
// keyFile.set_integer ("Color Management", "greySc", rtSettings.viewinggreySc);
- keyFile.set_string ("Color Management", "AdobeRGB", rtSettings.adobe);
- keyFile.set_string ("Color Management", "ProPhoto", rtSettings.prophoto);
- keyFile.set_string ("Color Management", "ProPhoto10", rtSettings.prophoto10);
- keyFile.set_string ("Color Management", "WideGamut", rtSettings.widegamut);
- keyFile.set_string ("Color Management", "sRGB", rtSettings.srgb);
- keyFile.set_string ("Color Management", "sRGB10", rtSettings.srgb10);
- keyFile.set_string ("Color Management", "Beta", rtSettings.beta);
- keyFile.set_string ("Color Management", "Best", rtSettings.best);
- keyFile.set_string ("Color Management", "Rec2020", rtSettings.rec2020);
- keyFile.set_string ("Color Management", "Bruce", rtSettings.bruce);
- keyFile.set_integer ("Color Management", "WhiteBalanceSpotSize", whiteBalanceSpotSize);
- keyFile.set_boolean ("Color Management", "GamutICC", rtSettings.gamutICC);
- keyFile.set_boolean ("Color Management", "GamutLch", rtSettings.gamutLch);
- keyFile.set_integer ("Color Management", "ProtectRed", rtSettings.protectred);
- keyFile.set_integer ("Color Management", "Amountchroma", rtSettings.amchroma);
- keyFile.set_double ("Color Management", "ProtectRedH", rtSettings.protectredh);
- keyFile.set_integer ("Color Management", "CRI", rtSettings.CRI_color);
- keyFile.set_integer ("Color Management", "DenoiseLabgamma", rtSettings.denoiselabgamma);
+ keyFile.set_string("Color Management", "AdobeRGB", rtSettings.adobe);
+ keyFile.set_string("Color Management", "ProPhoto", rtSettings.prophoto);
+ keyFile.set_string("Color Management", "WideGamut", rtSettings.widegamut);
+ keyFile.set_string("Color Management", "sRGB", rtSettings.srgb);
+ keyFile.set_string("Color Management", "Beta", rtSettings.beta);
+ keyFile.set_string("Color Management", "Best", rtSettings.best);
+ keyFile.set_string("Color Management", "Rec2020", rtSettings.rec2020);
+ keyFile.set_string("Color Management", "Bruce", rtSettings.bruce);
+ keyFile.set_string("Color Management", "ACES-AP0", rtSettings.ACESp0);
+ keyFile.set_string("Color Management", "ACES-AP1", rtSettings.ACESp1);
+ keyFile.set_integer("Color Management", "WhiteBalanceSpotSize", whiteBalanceSpotSize);
+ keyFile.set_boolean("Color Management", "GamutICC", rtSettings.gamutICC);
+ keyFile.set_boolean("Color Management", "GamutLch", rtSettings.gamutLch);
+ keyFile.set_integer("Color Management", "ProtectRed", rtSettings.protectred);
+ keyFile.set_integer("Color Management", "Amountchroma", rtSettings.amchroma);
+ keyFile.set_double("Color Management", "ProtectRedH", rtSettings.protectredh);
+ keyFile.set_integer("Color Management", "CRI", rtSettings.CRI_color);
+ keyFile.set_integer("Color Management", "DenoiseLabgamma", rtSettings.denoiselabgamma);
//keyFile.set_boolean ("Color Management", "Ciebadpixgauss", rtSettings.ciebadpixgauss);
- keyFile.set_double ("Color Management", "CBDLlevel0", rtSettings.level0_cbdl);
- keyFile.set_double ("Color Management", "CBDLlevel123", rtSettings.level123_cbdl);
+ keyFile.set_double("Color Management", "CBDLlevel0", rtSettings.level0_cbdl);
+ keyFile.set_double("Color Management", "CBDLlevel123", rtSettings.level123_cbdl);
//keyFile.set_double ("Color Management", "Colortoningab", rtSettings.colortoningab);
//keyFile.set_double ("Color Management", "Decaction", rtSettings.decaction);
- keyFile.set_string ("Color Management", "ClutsDirectory", clutsDir);
+ keyFile.set_string("Color Management", "ClutsDirectory", clutsDir);
+
+ keyFile.set_string("ICC Profile Creator", "PimariesPreset", ICCPC_primariesPreset);
+ keyFile.set_double("ICC Profile Creator", "RedPrimaryX", ICCPC_redPrimaryX);
+ keyFile.set_double("ICC Profile Creator", "RedPrimaryY", ICCPC_redPrimaryY);
+ keyFile.set_double("ICC Profile Creator", "GreenPrimaryX", ICCPC_greenPrimaryX);
+ keyFile.set_double("ICC Profile Creator", "GreenPrimaryY", ICCPC_greenPrimaryY);
+ keyFile.set_double("ICC Profile Creator", "BluePrimaryX", ICCPC_bluePrimaryX);
+ keyFile.set_double("ICC Profile Creator", "BluePrimaryY", ICCPC_bluePrimaryY);
+ keyFile.set_string("ICC Profile Creator", "GammaPreset", ICCPC_gammaPreset);
+ keyFile.set_double("ICC Profile Creator", "Gamma", ICCPC_gamma);
+ keyFile.set_double("ICC Profile Creator", "Slope", ICCPC_slope);
+ keyFile.set_string("ICC Profile Creator", "ProfileVersion", ICCPC_profileVersion);
+ keyFile.set_string("ICC Profile Creator", "Illuminant", ICCPC_illuminant);
+ keyFile.set_string("ICC Profile Creator", "Description", ICCPC_description);
+ keyFile.set_string("ICC Profile Creator", "Copyright", ICCPC_copyright);
+ keyFile.set_boolean("ICC Profile Creator", "AppendParamsToDesc", ICCPC_appendParamsToDesc);
Glib::ArrayHandle bab = baBehav;
- keyFile.set_integer_list ("Batch Processing", "AdjusterBehavior", bab);
+ keyFile.set_integer_list("Batch Processing", "AdjusterBehavior", bab);
- keyFile.set_boolean ("Sounds", "Enable", sndEnable);
- keyFile.set_string ("Sounds", "BatchQueueDone", sndBatchQueueDone);
- keyFile.set_string ("Sounds", "LngEditProcDone", sndLngEditProcDone);
- keyFile.set_double ("Sounds", "LngEditProcDoneSecs", sndLngEditProcDoneSecs);
+ keyFile.set_boolean("Sounds", "Enable", sndEnable);
+ keyFile.set_string("Sounds", "BatchQueueDone", sndBatchQueueDone);
+ keyFile.set_string("Sounds", "LngEditProcDone", sndLngEditProcDone);
+ keyFile.set_double("Sounds", "LngEditProcDoneSecs", sndLngEditProcDoneSecs);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_sharpening", fastexport_bypass_sharpening);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_sharpenEdge", fastexport_bypass_sharpenEdge);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_sharpenMicro", fastexport_bypass_sharpenMicro);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_sharpening", fastexport_bypass_sharpening);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_sharpenEdge", fastexport_bypass_sharpenEdge);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_sharpenMicro", fastexport_bypass_sharpenMicro);
//keyFile.set_boolean ("Fast Export", "fastexport_bypass_lumaDenoise" , fastexport_bypass_lumaDenoise);
//keyFile.set_boolean ("Fast Export", "fastexport_bypass_colorDenoise" , fastexport_bypass_colorDenoise);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_defringe", fastexport_bypass_defringe);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_dirpyrDenoise", fastexport_bypass_dirpyrDenoise);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_dirpyrequalizer", fastexport_bypass_dirpyrequalizer);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_wavelet", fastexport_bypass_wavelet);
- keyFile.set_string ("Fast Export", "fastexport_raw_bayer_method", fastexport_raw_bayer_method);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_defringe", fastexport_bypass_defringe);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_dirpyrDenoise", fastexport_bypass_dirpyrDenoise);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_dirpyrequalizer", fastexport_bypass_dirpyrequalizer);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_wavelet", fastexport_bypass_wavelet);
+ keyFile.set_string("Fast Export", "fastexport_raw_bayer_method", fastexport_raw_bayer_method);
//keyFile.set_boolean ("Fast Export", "fastexport_bypass_bayer_raw_all_enhance" , fastexport_bypass_raw_bayer_all_enhance);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations", fastexport_bypass_raw_bayer_dcb_iterations);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance", fastexport_bypass_raw_bayer_dcb_enhance);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations", fastexport_bypass_raw_bayer_lmmse_iterations);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_bayer_linenoise", fastexport_bypass_raw_bayer_linenoise);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_bayer_greenthresh", fastexport_bypass_raw_bayer_greenthresh);
- keyFile.set_string ("Fast Export", "fastexport_raw_xtrans_method", fastexport_raw_xtrans_method);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_ccSteps", fastexport_bypass_raw_ccSteps);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_ca", fastexport_bypass_raw_ca);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_df", fastexport_bypass_raw_df);
- keyFile.set_boolean ("Fast Export", "fastexport_bypass_raw_ff", fastexport_bypass_raw_ff);
- keyFile.set_string ("Fast Export", "fastexport_icm_input", fastexport_icm_input);
- keyFile.set_string ("Fast Export", "fastexport_icm_working", fastexport_icm_working);
- keyFile.set_string ("Fast Export", "fastexport_icm_output", fastexport_icm_output);
- keyFile.set_integer ("Fast Export", "fastexport_icm_output_intent", fastexport_icm_outputIntent);
- keyFile.set_boolean ("Fast Export", "fastexport_icm_output_bpc", fastexport_icm_outputBPC);
- keyFile.set_string ("Fast Export", "fastexport_icm_gamma", fastexport_icm_gamma);
- keyFile.set_boolean ("Fast Export", "fastexport_resize_enabled", fastexport_resize_enabled);
- keyFile.set_double ("Fast Export", "fastexport_resize_scale", fastexport_resize_scale);
- keyFile.set_string ("Fast Export", "fastexport_resize_appliesTo", fastexport_resize_appliesTo);
- keyFile.set_string ("Fast Export", "fastexport_resize_method", fastexport_resize_method);
- keyFile.set_integer ("Fast Export", "fastexport_resize_dataspec", fastexport_resize_dataspec);
- keyFile.set_integer ("Fast Export", "fastexport_resize_width", fastexport_resize_width);
- keyFile.set_integer ("Fast Export", "fastexport_resize_height", fastexport_resize_height);
- keyFile.set_integer ("Fast Export", "fastexport_use_fast_pipeline", fastexport_use_fast_pipeline);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_bayer_dcb_iterations", fastexport_bypass_raw_bayer_dcb_iterations);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_bayer_dcb_enhance", fastexport_bypass_raw_bayer_dcb_enhance);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_bayer_lmmse_iterations", fastexport_bypass_raw_bayer_lmmse_iterations);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_bayer_linenoise", fastexport_bypass_raw_bayer_linenoise);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_bayer_greenthresh", fastexport_bypass_raw_bayer_greenthresh);
+ keyFile.set_string("Fast Export", "fastexport_raw_xtrans_method", fastexport_raw_xtrans_method);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_ccSteps", fastexport_bypass_raw_ccSteps);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_ca", fastexport_bypass_raw_ca);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_df", fastexport_bypass_raw_df);
+ keyFile.set_boolean("Fast Export", "fastexport_bypass_raw_ff", fastexport_bypass_raw_ff);
+ keyFile.set_string("Fast Export", "fastexport_icm_input", fastexport_icm_input_profile);
+ keyFile.set_string("Fast Export", "fastexport_icm_working", fastexport_icm_working_profile);
+ keyFile.set_string("Fast Export", "fastexport_icm_output", fastexport_icm_output_profile);
+ keyFile.set_integer("Fast Export", "fastexport_icm_output_intent", fastexport_icm_outputIntent);
+ keyFile.set_boolean("Fast Export", "fastexport_icm_output_bpc", fastexport_icm_outputBPC);
+ keyFile.set_boolean("Fast Export", "fastexport_resize_enabled", fastexport_resize_enabled);
+ keyFile.set_double("Fast Export", "fastexport_resize_scale", fastexport_resize_scale);
+ keyFile.set_string("Fast Export", "fastexport_resize_appliesTo", fastexport_resize_appliesTo);
+ keyFile.set_string("Fast Export", "fastexport_resize_method", fastexport_resize_method);
+ keyFile.set_integer("Fast Export", "fastexport_resize_dataspec", fastexport_resize_dataspec);
+ keyFile.set_integer("Fast Export", "fastexport_resize_width", fastexport_resize_width);
+ keyFile.set_integer("Fast Export", "fastexport_resize_height", fastexport_resize_height);
+ keyFile.set_integer("Fast Export", "fastexport_use_fast_pipeline", fastexport_use_fast_pipeline);
- keyFile.set_string ("Dialogs", "LastIccDir", lastIccDir);
- keyFile.set_string ("Dialogs", "LastDarkframeDir", lastDarkframeDir);
- keyFile.set_string ("Dialogs", "LastFlatfieldDir", lastFlatfieldDir);
- keyFile.set_string ("Dialogs", "LastRgbCurvesDir", lastRgbCurvesDir);
- keyFile.set_string ("Dialogs", "LastLabCurvesDir", lastLabCurvesDir);
- keyFile.set_string ("Dialogs", "LastRetinexDir", lastRetinexDir);
- keyFile.set_string ("Dialogs", "LastDenoiseCurvesDir", lastDenoiseCurvesDir);
- keyFile.set_string ("Dialogs", "LastWaveletCurvesDir", lastWaveletCurvesDir);
- keyFile.set_string ("Dialogs", "LastPFCurvesDir", lastPFCurvesDir);
- keyFile.set_string ("Dialogs", "LastHsvCurvesDir", lastHsvCurvesDir);
- keyFile.set_string ("Dialogs", "LastBWCurvesDir", lastBWCurvesDir);
- keyFile.set_string ("Dialogs", "LastToneCurvesDir", lastToneCurvesDir);
- keyFile.set_string ("Dialogs", "LastVibranceCurvesDir", lastVibranceCurvesDir);
- keyFile.set_string ("Dialogs", "LastProfilingReferenceDir", lastProfilingReferenceDir);
- keyFile.set_string ("Dialogs", "LastLensProfileDir", lastLensProfileDir);
- keyFile.set_boolean ("Dialogs", "GimpPluginShowInfoDialog", gimpPluginShowInfoDialog);
+ keyFile.set_string("Dialogs", "LastIccDir", lastIccDir);
+ keyFile.set_string("Dialogs", "LastDarkframeDir", lastDarkframeDir);
+ keyFile.set_string("Dialogs", "LastFlatfieldDir", lastFlatfieldDir);
+ keyFile.set_string("Dialogs", "LastRgbCurvesDir", lastRgbCurvesDir);
+ keyFile.set_string("Dialogs", "LastLabCurvesDir", lastLabCurvesDir);
+ keyFile.set_string("Dialogs", "LastRetinexDir", lastRetinexDir);
+ keyFile.set_string("Dialogs", "LastDenoiseCurvesDir", lastDenoiseCurvesDir);
+ keyFile.set_string("Dialogs", "LastWaveletCurvesDir", lastWaveletCurvesDir);
+ keyFile.set_string("Dialogs", "LastPFCurvesDir", lastPFCurvesDir);
+ keyFile.set_string("Dialogs", "LastHsvCurvesDir", lastHsvCurvesDir);
+ keyFile.set_string("Dialogs", "LastBWCurvesDir", lastBWCurvesDir);
+ keyFile.set_string("Dialogs", "LastToneCurvesDir", lastToneCurvesDir);
+ keyFile.set_string("Dialogs", "LastVibranceCurvesDir", lastVibranceCurvesDir);
+ keyFile.set_string("Dialogs", "LastProfilingReferenceDir", lastProfilingReferenceDir);
+ keyFile.set_string("Dialogs", "LastLensProfileDir", lastLensProfileDir);
+ keyFile.set_string("Dialogs", "LastICCProfCreatorDir", lastICCProfCreatorDir);
+ keyFile.set_boolean("Dialogs", "GimpPluginShowInfoDialog", gimpPluginShowInfoDialog);
- keyFile.set_string ("Lensfun", "DBDirectory", rtSettings.lensfunDbDirectory);
+ keyFile.set_string("Lensfun", "DBDirectory", rtSettings.lensfunDbDirectory);
- keyData = keyFile.to_data ();
+ keyData = keyFile.to_data();
} catch (Glib::KeyFileError &e) {
- throw Error (e.what());
+ throw Error(e.what());
}
- FILE *f = g_fopen (fname.c_str (), "wt");
+ FILE *f = g_fopen(fname.c_str(), "wt");
if (f == nullptr) {
std::cout << "Warning! Unable to save your preferences to: " << fname << std::endl;
- Glib::ustring msg_ = Glib::ustring::compose (M ("MAIN_MSG_WRITEFAILED"), fname.c_str());
- throw Error (msg_);
+ Glib::ustring msg_ = Glib::ustring::compose(M("MAIN_MSG_WRITEFAILED"), fname.c_str());
+ throw Error(msg_);
} else {
- fprintf (f, "%s", keyData.c_str ());
- fclose (f);
+ fprintf(f, "%s", keyData.c_str());
+ fclose(f);
}
}
-void Options::load (bool lightweight)
+void Options::load(bool lightweight)
{
// Find the application data path
@@ -2086,89 +2195,91 @@ void Options::load (bool lightweight)
const gchar* path;
Glib::ustring dPath;
- path = g_getenv ("RT_SETTINGS");
+ path = g_getenv("RT_SETTINGS");
if (path != nullptr) {
- rtdir = Glib::ustring (path);
+ rtdir = Glib::ustring(path);
- if (!Glib::path_is_absolute (rtdir)) {
- Glib::ustring msg = Glib::ustring::compose ("Settings path %1 is not absolute", rtdir);
- throw Error (msg);
+ if (!Glib::path_is_absolute(rtdir)) {
+ Glib::ustring msg = Glib::ustring::compose("Settings path %1 is not absolute", rtdir);
+ throw Error(msg);
}
} else {
#ifdef WIN32
WCHAR pathW[MAX_PATH] = {0};
- if (SHGetSpecialFolderPathW (NULL, pathW, CSIDL_LOCAL_APPDATA, false)) {
+ if (SHGetSpecialFolderPathW(NULL, pathW, CSIDL_LOCAL_APPDATA, false)) {
char pathA[MAX_PATH];
- WideCharToMultiByte (CP_UTF8, 0, pathW, -1, pathA, MAX_PATH, 0, 0);
- rtdir = Glib::build_filename (Glib::ustring (pathA), Glib::ustring (CACHEFOLDERNAME));
+ WideCharToMultiByte(CP_UTF8, 0, pathW, -1, pathA, MAX_PATH, 0, 0);
+ rtdir = Glib::build_filename(Glib::ustring(pathA), Glib::ustring(CACHEFOLDERNAME));
}
#else
- rtdir = Glib::build_filename (Glib::ustring (g_get_user_config_dir ()), Glib::ustring (CACHEFOLDERNAME));
+ rtdir = Glib::build_filename(Glib::ustring(g_get_user_config_dir()), Glib::ustring(CACHEFOLDERNAME));
#endif
}
if (options.rtSettings.verbose) {
- printf ("Settings directory (rtdir) = %s\n", rtdir.c_str());
+ printf("Settings directory (rtdir) = %s\n", rtdir.c_str());
}
// Set the cache folder in RT's base folder
- cacheBaseDir = Glib::build_filename (argv0, "mycache");
+ cacheBaseDir = Glib::build_filename(argv0, "mycache");
// Read the global option file (the one located in the application's base folder)
try {
- options.readFromFile (Glib::build_filename (argv0, "options"));
+ options.readFromFile(Glib::build_filename(argv0, "options"));
} catch (Options::Error &) {
// ignore errors here
}
if (!options.multiUser && path == nullptr) {
- rtdir = Glib::build_filename (argv0, "mysettings");
+ rtdir = Glib::build_filename(argv0, "mysettings");
}
// Modify the path of the cache folder to the one provided in RT_CACHE environment variable
- path = g_getenv ("RT_CACHE");
+ path = g_getenv("RT_CACHE");
if (path != nullptr) {
- cacheBaseDir = Glib::ustring (path);
+ cacheBaseDir = Glib::ustring(path);
- if (!Glib::path_is_absolute (cacheBaseDir)) {
- Glib::ustring msg = Glib::ustring::compose ("Cache base dir %1 is not absolute", cacheBaseDir);
- throw Error (msg);
+ if (!Glib::path_is_absolute(cacheBaseDir)) {
+ Glib::ustring msg = Glib::ustring::compose("Cache base dir %1 is not absolute", cacheBaseDir);
+ throw Error(msg);
}
}
// No environment variable provided, so falling back to the multi user mode, if enabled
else if (options.multiUser) {
#ifdef WIN32
- cacheBaseDir = Glib::build_filename (rtdir, "cache");
+ cacheBaseDir = Glib::build_filename(rtdir, "cache");
#else
- cacheBaseDir = Glib::build_filename (Glib::ustring (g_get_user_cache_dir()), Glib::ustring (CACHEFOLDERNAME));
+ cacheBaseDir = Glib::build_filename(Glib::ustring(g_get_user_cache_dir()), Glib::ustring(CACHEFOLDERNAME));
#endif
}
// Read the user option file (the one located somewhere in the user's home folder)
// Those values supersets those of the global option file
try {
- options.readFromFile (Glib::build_filename (rtdir, "options"));
+ options.readFromFile(Glib::build_filename(rtdir, "options"));
} catch (Options::Error &) {
// If the local option file does not exist or is broken, and the local cache folder does not exist, recreate it
- if (!g_mkdir_with_parents (rtdir.c_str (), 511)) {
+ if (!g_mkdir_with_parents(rtdir.c_str(), 511)) {
// Save the option file
- options.saveToFile (Glib::build_filename (rtdir, "options"));
+ options.saveToFile(Glib::build_filename(rtdir, "options"));
}
}
#ifdef __APPLE__
+
if (options.multiUser) {
// make sure .local/share exists on OS X so we don't get problems with recently-used.xbel
- g_mkdir_with_parents (g_get_user_data_dir(), 511);
+ g_mkdir_with_parents(g_get_user_data_dir(), 511);
}
+
#endif
if (options.rtSettings.verbose) {
- printf ("Cache directory (cacheBaseDir) = %s\n", cacheBaseDir.c_str());
+ printf("Cache directory (cacheBaseDir) = %s\n", cacheBaseDir.c_str());
}
// Update profile's path and recreate it if necessary
@@ -2178,7 +2289,7 @@ void Options::load (bool lightweight)
if (options.defProfRaw.empty()) {
options.defProfRaw = DEFPROFILE_RAW;
} else {
- if (!options.findProfilePath (options.defProfRaw).empty()) {
+ if (!options.findProfilePath(options.defProfRaw).empty()) {
if (options.rtSettings.verbose) {
std::cout << "Default profile for raw images \"" << options.defProfRaw << "\" found" << std::endl;
}
@@ -2187,7 +2298,8 @@ void Options::load (bool lightweight)
options.setDefProfRawMissing(true);
Glib::ustring dpr(DEFPROFILE_RAW);
- if (options.findProfilePath (dpr).empty()) {
+
+ if (options.findProfilePath(dpr).empty()) {
options.setBundledDefProfRawMissing(true);
}
} else {
@@ -2199,7 +2311,7 @@ void Options::load (bool lightweight)
if (options.defProfImg.empty()) {
options.defProfImg = DEFPROFILE_IMG;
} else {
- if (!options.findProfilePath (options.defProfImg).empty()) {
+ if (!options.findProfilePath(options.defProfImg).empty()) {
if (options.rtSettings.verbose) {
std::cout << "Default profile for non-raw images \"" << options.defProfImg << "\" found" << std::endl;
}
@@ -2208,7 +2320,8 @@ void Options::load (bool lightweight)
options.setDefProfImgMissing(true);
Glib::ustring dpi(DEFPROFILE_IMG);
- if (options.findProfilePath (dpi).empty()) {
+
+ if (options.findProfilePath(dpi).empty()) {
options.setBundledDefProfImgMissing(true);
}
} else {
@@ -2232,7 +2345,7 @@ void Options::load (bool lightweight)
// out which are the parent translations. Furthermore, there must be a file for each locale () -- you cannot have
// 'French (CA)' unless there is a file 'French'.
- Glib::ustring defaultTranslation = Glib::build_filename (argv0, "languages", "default");
+ Glib::ustring defaultTranslation = Glib::build_filename(argv0, "languages", "default");
Glib::ustring languageTranslation = "";
Glib::ustring localeTranslation = "";
@@ -2241,34 +2354,34 @@ void Options::load (bool lightweight)
}
if (!options.language.empty()) {
- std::vector langPortions = Glib::Regex::split_simple (" ", options.language);
+ std::vector langPortions = Glib::Regex::split_simple(" ", options.language);
if (langPortions.size() >= 1) {
- languageTranslation = Glib::build_filename (argv0, "languages", langPortions.at (0));
+ languageTranslation = Glib::build_filename(argv0, "languages", langPortions.at(0));
}
if (langPortions.size() >= 2) {
- localeTranslation = Glib::build_filename (argv0, "languages", options.language);
+ localeTranslation = Glib::build_filename(argv0, "languages", options.language);
}
}
- langMgr.load (options.language, {localeTranslation, languageTranslation, defaultTranslation});
+ langMgr.load(options.language, {localeTranslation, languageTranslation, defaultTranslation});
- rtengine::init (&options.rtSettings, argv0, rtdir, !lightweight);
+ rtengine::init(&options.rtSettings, argv0, rtdir, !lightweight);
}
-void Options::save ()
+void Options::save()
{
- options.saveToFile (Glib::build_filename (rtdir, "options"));
+ options.saveToFile(Glib::build_filename(rtdir, "options"));
}
/*
* return true if ext is a parsed extension (retained or not)
*/
-bool Options::is_parse_extention (Glib::ustring fname)
+bool Options::is_parse_extention(Glib::ustring fname)
{
- Glib::ustring ext = getExtension (fname).lowercase();
+ Glib::ustring ext = getExtension(fname).lowercase();
if (!ext.empty()) {
// there is an extension to the filename
@@ -2287,10 +2400,10 @@ bool Options::is_parse_extention (Glib::ustring fname)
/*
* return true if fname ends with one of the retained image file extensions
*/
-bool Options::has_retained_extention (Glib::ustring fname)
+bool Options::has_retained_extention(Glib::ustring fname)
{
- Glib::ustring ext = getExtension (fname).lowercase();
+ Glib::ustring ext = getExtension(fname).lowercase();
if (!ext.empty()) {
// there is an extension to the filename
@@ -2309,7 +2422,7 @@ bool Options::has_retained_extention (Glib::ustring fname)
/*
* return true if ext is an enabled extension
*/
-bool Options::is_extention_enabled (Glib::ustring ext)
+bool Options::is_extention_enabled(Glib::ustring ext)
{
for (int j = 0; j < (int)parseExtensions.size(); j++)
if (parseExtensions[j].casefold() == ext.casefold()) {
@@ -2337,7 +2450,7 @@ bool Options::is_defProfImgMissing()
{
return defProfError & rtengine::toUnderlying(DefProfError::defProfImgMissing);
}
-void Options::setDefProfRawMissing (bool value)
+void Options::setDefProfRawMissing(bool value)
{
if (value) {
defProfError |= rtengine::toUnderlying(DefProfError::defProfRawMissing);
@@ -2345,7 +2458,7 @@ void Options::setDefProfRawMissing (bool value)
defProfError &= ~rtengine::toUnderlying(DefProfError::defProfRawMissing);
}
}
-void Options::setDefProfImgMissing (bool value)
+void Options::setDefProfImgMissing(bool value)
{
if (value) {
defProfError |= rtengine::toUnderlying(DefProfError::defProfImgMissing);
@@ -2361,7 +2474,7 @@ bool Options::is_bundledDefProfImgMissing()
{
return defProfError & rtengine::toUnderlying(DefProfError::bundledDefProfImgMissing);
}
-void Options::setBundledDefProfRawMissing (bool value)
+void Options::setBundledDefProfRawMissing(bool value)
{
if (value) {
defProfError |= rtengine::toUnderlying(DefProfError::bundledDefProfRawMissing);
@@ -2369,7 +2482,7 @@ void Options::setBundledDefProfRawMissing (bool value)
defProfError &= ~rtengine::toUnderlying(DefProfError::bundledDefProfRawMissing);
}
}
-void Options::setBundledDefProfImgMissing (bool value)
+void Options::setBundledDefProfImgMissing(bool value)
{
if (value) {
defProfError |= rtengine::toUnderlying(DefProfError::bundledDefProfImgMissing);
@@ -2377,4 +2490,9 @@ void Options::setBundledDefProfImgMissing (bool value)
defProfError &= ~rtengine::toUnderlying(DefProfError::bundledDefProfImgMissing);
}
}
-
+Glib::ustring Options::getICCProfileCopyright()
+{
+ Glib::Date now;
+ now.set_time_current();
+ return Glib::ustring::compose("Copyright RawTherapee %1, CC0", now.get_year());
+}
diff --git a/rtgui/options.h b/rtgui/options.h
index 25fa31b6d..50535108e 100644
--- a/rtgui/options.h
+++ b/rtgui/options.h
@@ -287,6 +287,23 @@ public:
bool menuGroupProfileOperations;
bool menuGroupExtProg;
+ // ICC Profile Creator
+ Glib::ustring ICCPC_primariesPreset;
+ double ICCPC_redPrimaryX;
+ double ICCPC_redPrimaryY;
+ double ICCPC_greenPrimaryX;
+ double ICCPC_greenPrimaryY;
+ double ICCPC_bluePrimaryX;
+ double ICCPC_bluePrimaryY;
+ Glib::ustring ICCPC_gammaPreset;
+ double ICCPC_gamma;
+ double ICCPC_slope;
+ Glib::ustring ICCPC_profileVersion;
+ Glib::ustring ICCPC_illuminant;
+ Glib::ustring ICCPC_description;
+ Glib::ustring ICCPC_copyright;
+ bool ICCPC_appendParamsToDesc;
+
// fast export options
bool fastexport_bypass_sharpening;
bool fastexport_bypass_sharpenEdge;
@@ -309,12 +326,12 @@ public:
bool fastexport_bypass_raw_ca;
bool fastexport_bypass_raw_df;
bool fastexport_bypass_raw_ff;
- Glib::ustring fastexport_icm_input;
- Glib::ustring fastexport_icm_working;
- Glib::ustring fastexport_icm_output;
+ Glib::ustring fastexport_icm_input_profile;
+ Glib::ustring fastexport_icm_working_profile;
+ Glib::ustring fastexport_icm_output_profile;
rtengine::RenderingIntent fastexport_icm_outputIntent;
bool fastexport_icm_outputBPC;
- Glib::ustring fastexport_icm_gamma;
+ Glib::ustring fastexport_icm_custom_output_profile;
bool fastexport_resize_enabled;
double fastexport_resize_scale;
Glib::ustring fastexport_resize_appliesTo;
@@ -341,6 +358,7 @@ public:
Glib::ustring lastProfilingReferenceDir;
Glib::ustring lastBWCurvesDir;
Glib::ustring lastLensProfileDir;
+ Glib::ustring lastICCProfCreatorDir;
bool gimpPluginShowInfoDialog;
size_t maxRecentFolders; // max. number of recent folders stored in options file
@@ -373,6 +391,7 @@ public:
void setBundledDefProfRawMissing (bool value);
void setDefProfImgMissing (bool value);
void setBundledDefProfImgMissing (bool value);
+ static Glib::ustring getICCProfileCopyright();
};
extern Options options;
diff --git a/rtgui/paramsedited.cc b/rtgui/paramsedited.cc
index 5ff8d1c54..400568203 100644
--- a/rtgui/paramsedited.cc
+++ b/rtgui/paramsedited.cc
@@ -21,13 +21,13 @@
#include "options.h"
#include "addsetids.h"
-ParamsEdited::ParamsEdited (bool value)
+ParamsEdited::ParamsEdited(bool value)
{
- set (value);
+ set(value);
}
-void ParamsEdited::set (bool v)
+void ParamsEdited::set(bool v)
{
general.rank = v;
@@ -379,20 +379,19 @@ void ParamsEdited::set (bool v)
resize.height = v;
resize.enabled = v;
resize.allowUpscaling = v;
- icm.input = v;
+ icm.inputProfile = v;
icm.toneCurve = v;
icm.applyLookTable = v;
icm.applyBaselineExposureOffset = v;
icm.applyHueSatMap = v;
icm.dcpIlluminant = v;
- icm.working = v;
- icm.output = v;
+ icm.workingProfile = v;
+ icm.outputProfile = v;
icm.outputIntent = v;
- icm.outputBPC = v;
- icm.gamma = v;
- icm.freegamma = v;
- icm.gampos = v;
- icm.slpos = v;
+ icm.outputBPC = v;
+ icm.workingTRCGamma = v;
+ icm.workingTRCSlope = v;
+ icm.workingTRC = v;
raw.bayersensor.method = v;
raw.bayersensor.border = v;
raw.bayersensor.imageNum = v;
@@ -573,10 +572,10 @@ void ParamsEdited::set (bool v)
using namespace rtengine;
using namespace rtengine::procparams;
-void ParamsEdited::initFrom (const std::vector& src)
+void ParamsEdited::initFrom(const std::vector& src)
{
- set (true);
+ set(true);
if (src.empty()) {
return;
@@ -654,12 +653,12 @@ void ParamsEdited::initFrom (const std::vector
labCurve.rstprotection = labCurve.rstprotection && p.labCurve.rstprotection == other.labCurve.rstprotection;
labCurve.lcredsk = labCurve.lcredsk && p.labCurve.lcredsk == other.labCurve.lcredsk;
- localContrast.enabled = localContrast.enabled && p.localContrast.enabled == other.localContrast.enabled;
+ localContrast.enabled = localContrast.enabled && p.localContrast.enabled == other.localContrast.enabled;
localContrast.radius = localContrast.radius && p.localContrast.radius == other.localContrast.radius;
localContrast.amount = localContrast.amount && p.localContrast.amount == other.localContrast.amount;
localContrast.darkness = localContrast.darkness && p.localContrast.darkness == other.localContrast.darkness;
localContrast.lightness = localContrast.lightness && p.localContrast.lightness == other.localContrast.lightness;
-
+
rgbCurves.enabled = rgbCurves.enabled && p.rgbCurves.enabled == other.rgbCurves.enabled;
rgbCurves.lumamode = rgbCurves.lumamode && p.rgbCurves.lumamode == other.rgbCurves.lumamode;
rgbCurves.rcurve = rgbCurves.rcurve && p.rgbCurves.rcurve == other.rgbCurves.rcurve;
@@ -843,7 +842,7 @@ void ParamsEdited::initFrom (const std::vector
fattal.threshold = fattal.threshold && p.fattal.threshold == other.fattal.threshold;
fattal.amount = fattal.amount && p.fattal.amount == other.fattal.amount;
fattal.anchor = fattal.anchor && p.fattal.anchor == other.fattal.anchor;
-
+
sh.enabled = sh.enabled && p.sh.enabled == other.sh.enabled;
sh.highlights = sh.highlights && p.sh.highlights == other.sh.highlights;
sh.htonalwidth = sh.htonalwidth && p.sh.htonalwidth == other.sh.htonalwidth;
@@ -935,20 +934,19 @@ void ParamsEdited::initFrom (const std::vector
resize.height = resize.height && p.resize.height == other.resize.height;
resize.enabled = resize.enabled && p.resize.enabled == other.resize.enabled;
resize.allowUpscaling = resize.allowUpscaling && p.resize.allowUpscaling == other.resize.allowUpscaling;
- icm.input = icm.input && p.icm.input == other.icm.input;
+ icm.inputProfile = icm.inputProfile && p.icm.inputProfile == other.icm.inputProfile;
icm.toneCurve = icm.toneCurve && p.icm.toneCurve == other.icm.toneCurve;
icm.applyLookTable = icm.applyLookTable && p.icm.applyLookTable == other.icm.applyLookTable;
icm.applyBaselineExposureOffset = icm.applyBaselineExposureOffset && p.icm.applyBaselineExposureOffset == other.icm.applyBaselineExposureOffset;
icm.applyHueSatMap = icm.applyHueSatMap && p.icm.applyHueSatMap == other.icm.applyHueSatMap;
icm.dcpIlluminant = icm.dcpIlluminant && p.icm.dcpIlluminant == other.icm.dcpIlluminant;
- icm.working = icm.working && p.icm.working == other.icm.working;
- icm.output = icm.output && p.icm.output == other.icm.output;
+ icm.workingProfile = icm.workingProfile && p.icm.workingProfile == other.icm.workingProfile;
+ icm.outputProfile = icm.outputProfile && p.icm.outputProfile == other.icm.outputProfile;
icm.outputIntent = icm.outputIntent && p.icm.outputIntent == other.icm.outputIntent;
icm.outputBPC = icm.outputBPC && p.icm.outputBPC == other.icm.outputBPC ;
- icm.gamma = icm.gamma && p.icm.gamma == other.icm.gamma;
- icm.freegamma = icm.freegamma && p.icm.freegamma == other.icm.freegamma;
- icm.gampos = icm.gampos && p.icm.gampos == other.icm.gampos;
- icm.slpos = icm.slpos && p.icm.slpos == other.icm.slpos;
+ icm.workingTRCGamma = icm.workingTRCGamma && p.icm.workingTRCGamma == other.icm.workingTRCGamma;
+ icm.workingTRCSlope = icm.workingTRCSlope && p.icm.workingTRCSlope == other.icm.workingTRCSlope;
+ icm.workingTRC = icm.workingTRC && p.icm.workingTRC == other.icm.workingTRC;
raw.bayersensor.method = raw.bayersensor.method && p.raw.bayersensor.method == other.raw.bayersensor.method;
raw.bayersensor.border = raw.bayersensor.border && p.raw.bayersensor.border == other.raw.bayersensor.border;
raw.bayersensor.imageNum = raw.bayersensor.imageNum && p.raw.bayersensor.imageNum == other.raw.bayersensor.imageNum;
@@ -1106,7 +1104,7 @@ void ParamsEdited::initFrom (const std::vector
dirpyrequalizer.skinprotect = dirpyrequalizer.skinprotect && p.dirpyrequalizer.skinprotect == other.dirpyrequalizer.skinprotect;
// dirpyrequalizer.algo = dirpyrequalizer.algo && p.dirpyrequalizer.algo == other.dirpyrequalizer.algo;
dirpyrequalizer.hueskin = dirpyrequalizer.hueskin && p.dirpyrequalizer.hueskin == other.dirpyrequalizer.hueskin;
- hsvequalizer.enabled = hsvequalizer.enabled && p.hsvequalizer.enabled == other.hsvequalizer.enabled;
+ hsvequalizer.enabled = hsvequalizer.enabled && p.hsvequalizer.enabled == other.hsvequalizer.enabled;
hsvequalizer.hcurve = hsvequalizer.hcurve && p.hsvequalizer.hcurve == other.hsvequalizer.hcurve;
hsvequalizer.scurve = hsvequalizer.scurve && p.hsvequalizer.scurve == other.hsvequalizer.scurve;
hsvequalizer.vcurve = hsvequalizer.vcurve && p.hsvequalizer.vcurve == other.hsvequalizer.vcurve;
@@ -1123,7 +1121,7 @@ void ParamsEdited::initFrom (const std::vector
}
}
-void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rtengine::procparams::ProcParams& mods, bool forceSet)
+void ParamsEdited::combine(rtengine::procparams::ProcParams& toEdit, const rtengine::procparams::ProcParams& mods, bool forceSet)
{
bool dontforceSet = !forceSet;
@@ -1203,7 +1201,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (toneCurve.clampOOG) {
toEdit.toneCurve.clampOOG = mods.toneCurve.clampOOG;
}
-
+
if (retinex.enabled) {
toEdit.retinex.enabled = mods.retinex.enabled;
}
@@ -1337,7 +1335,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (labCurve.enabled) {
toEdit.labCurve.enabled = mods.labCurve.enabled;
}
-
+
if (labCurve.lcurve) {
toEdit.labCurve.lcurve = mods.labCurve.lcurve;
}
@@ -1550,12 +1548,15 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (colorToning.labgridALow) {
toEdit.colorToning.labgridALow = mods.colorToning.labgridALow;
}
+
if (colorToning.labgridBLow) {
toEdit.colorToning.labgridBLow = mods.colorToning.labgridBLow;
}
+
if (colorToning.labgridAHigh) {
toEdit.colorToning.labgridAHigh = mods.colorToning.labgridAHigh;
}
+
if (colorToning.labgridBHigh) {
toEdit.colorToning.labgridBHigh = mods.colorToning.labgridBHigh;
}
@@ -1621,7 +1622,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
}
if (sharpening.edges_radius) {
- toEdit.sharpening.edges_radius = dontforceSet && options.baBehav[ADDSET_SHARP_RADIUS] ? toEdit.sharpening.edges_radius + mods.sharpening.edges_radius: mods.sharpening.edges_radius;
+ toEdit.sharpening.edges_radius = dontforceSet && options.baBehav[ADDSET_SHARP_RADIUS] ? toEdit.sharpening.edges_radius + mods.sharpening.edges_radius : mods.sharpening.edges_radius;
}
if (sharpening.edges_tolerance) {
@@ -1755,7 +1756,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (wb.enabled) {
toEdit.wb.enabled = mods.wb.enabled;
}
-
+
if (wb.method) {
toEdit.wb.method = mods.wb.method;
}
@@ -2074,15 +2075,18 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (fattal.enabled) {
toEdit.fattal.enabled = mods.fattal.enabled;
}
+
if (fattal.threshold) {
toEdit.fattal.threshold = mods.fattal.threshold;
}
+
if (fattal.amount) {
toEdit.fattal.amount = mods.fattal.amount;
- }
+ }
+
if (fattal.anchor) {
toEdit.fattal.anchor = mods.fattal.anchor;
- }
+ }
if (sh.enabled) {
toEdit.sh.enabled = mods.sh.enabled;
@@ -2279,7 +2283,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (chmixer.enabled) {
toEdit.chmixer.enabled = mods.chmixer.enabled;
}
-
+
for (int i = 0; i < 3; i++) {
if (chmixer.red[i]) {
toEdit.chmixer.red[i] = dontforceSet && options.baBehav[ADDSET_CHMIXER] ? toEdit.chmixer.red[i] + mods.chmixer.red[i] : mods.chmixer.red[i];
@@ -2418,8 +2422,8 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
toEdit.resize.allowUpscaling = mods.resize.allowUpscaling;
}
- if (icm.input) {
- toEdit.icm.input = mods.icm.input;
+ if (icm.inputProfile) {
+ toEdit.icm.inputProfile = mods.icm.inputProfile;
}
if (icm.toneCurve) {
@@ -2442,12 +2446,12 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
toEdit.icm.dcpIlluminant = mods.icm.dcpIlluminant;
}
- if (icm.working) {
- toEdit.icm.working = mods.icm.working;
+ if (icm.workingProfile) {
+ toEdit.icm.workingProfile = mods.icm.workingProfile;
}
- if (icm.output) {
- toEdit.icm.output = mods.icm.output;
+ if (icm.outputProfile) {
+ toEdit.icm.outputProfile = mods.icm.outputProfile;
}
if (icm.outputIntent) {
@@ -2458,20 +2462,16 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
toEdit.icm.outputBPC = mods.icm.outputBPC;
}
- if (icm.gampos) {
- toEdit.icm.gampos = dontforceSet && options.baBehav[ADDSET_FREE_OUPUT_GAMMA] ? toEdit.icm.gampos + mods.icm.gampos : mods.icm.gampos;
+ if (icm.workingTRCGamma) {
+ toEdit.icm.workingTRCGamma = mods.icm.workingTRCGamma;
}
- if (icm.slpos) {
- toEdit.icm.slpos = dontforceSet && options.baBehav[ADDSET_FREE_OUTPUT_SLOPE] ? toEdit.icm.slpos + mods.icm.slpos : mods.icm.slpos;
+ if (icm.workingTRCSlope) {
+ toEdit.icm.workingTRCSlope = mods.icm.workingTRCSlope;
}
- if (icm.gamma) {
- toEdit.icm.gamma = mods.icm.gamma;
- }
-
- if (icm.freegamma) {
- toEdit.icm.freegamma = mods.icm.freegamma;
+ if (icm.workingTRC) {
+ toEdit.icm.workingTRC = mods.icm.workingTRC;
}
if (raw.bayersensor.method) {
@@ -2593,7 +2593,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (raw.bayersensor.linenoiseDirection) {
toEdit.raw.bayersensor.linenoiseDirection = mods.raw.bayersensor.linenoiseDirection;
}
-
+
if (raw.bayersensor.pdafLinesFilter) {
toEdit.raw.bayersensor.pdafLinesFilter = mods.raw.bayersensor.pdafLinesFilter;
}
@@ -3062,7 +3062,7 @@ void ParamsEdited::combine (rtengine::procparams::ProcParams& toEdit, const rten
if (hsvequalizer.enabled) {
toEdit.hsvequalizer.enabled = mods.hsvequalizer.enabled;
}
-
+
if (hsvequalizer.hcurve) {
toEdit.hsvequalizer.hcurve = mods.hsvequalizer.hcurve;
}
diff --git a/rtgui/paramsedited.h b/rtgui/paramsedited.h
index 974a1a31f..c4c36ce61 100644
--- a/rtgui/paramsedited.h
+++ b/rtgui/paramsedited.h
@@ -122,7 +122,8 @@ public:
};
-class LocalContrastParamsEdited {
+class LocalContrastParamsEdited
+{
public:
bool enabled;
bool radius;
@@ -386,7 +387,8 @@ public:
};
-class FattalToneMappingParamsEdited {
+class FattalToneMappingParamsEdited
+{
public:
bool enabled;
bool threshold;
@@ -577,20 +579,21 @@ class ColorManagementParamsEdited
{
public:
- bool input;
+ bool inputProfile;
bool toneCurve;
bool applyLookTable;
bool applyBaselineExposureOffset;
bool applyHueSatMap;
bool dcpIlluminant;
- bool working;
- bool output;
+
+ bool workingProfile;
+ bool workingTRC;
+ bool workingTRCGamma;
+ bool workingTRCSlope;
+
+ bool outputProfile;
bool outputIntent;
bool outputBPC;
- bool gamma;
- bool gampos;
- bool slpos;
- bool freegamma;
};
class WaveletParamsEdited
{
@@ -804,7 +807,8 @@ public:
};
-class MetaDataParamsEdited {
+class MetaDataParamsEdited
+{
public:
bool mode;
};
@@ -863,10 +867,10 @@ public:
bool exif;
bool iptc;
- explicit ParamsEdited (bool value = false);
+ explicit ParamsEdited(bool value = false);
- void set (bool v);
- void initFrom (const std::vector& src);
- void combine (rtengine::procparams::ProcParams& toEdit, const rtengine::procparams::ProcParams& mods, bool forceSet);
+ void set(bool v);
+ void initFrom(const std::vector& src);
+ void combine(rtengine::procparams::ProcParams& toEdit, const rtengine::procparams::ProcParams& mods, bool forceSet);
};
#endif
diff --git a/rtgui/ppversion.h b/rtgui/ppversion.h
index a09f59d7a..f4ca1f360 100644
--- a/rtgui/ppversion.h
+++ b/rtgui/ppversion.h
@@ -6,6 +6,8 @@
/*
Log of version changes
+ 341 2018-07-22
+ [ICM] enhanced custom output profile
340 2018-07-08
store whether curve is from histogram matching
339 2018-07-04
diff --git a/rtgui/preferences.cc b/rtgui/preferences.cc
index 5a59b875a..086592822 100644
--- a/rtgui/preferences.cc
+++ b/rtgui/preferences.cc
@@ -292,8 +292,6 @@ Gtk::Widget* Preferences::getBatchProcPanel ()
mi = behModel->append ();
mi->set_value (behavColumns.label, M ("TP_GAMMA_OUTPUT"));
- appendBehavList (mi, M ("TP_GAMMA_CURV"), ADDSET_FREE_OUPUT_GAMMA, false);
- appendBehavList (mi, M ("TP_GAMMA_SLOP"), ADDSET_FREE_OUTPUT_SLOPE, false);
mi = behModel->append ();
mi->set_value (behavColumns.label, M ("TP_CHMIXER_LABEL"));
diff --git a/rtgui/rtwindow.cc b/rtgui/rtwindow.cc
index 62472d909..8541504f8 100644
--- a/rtgui/rtwindow.cc
+++ b/rtgui/rtwindow.cc
@@ -21,6 +21,7 @@
#include "rtwindow.h"
#include "options.h"
#include "preferences.h"
+#include "iccprofilecreator.h"
#include "cursormanager.h"
#include "rtimage.h"
#include "whitebalance.h"
@@ -229,6 +230,12 @@ RTWindow::RTWindow ()
iFullscreen = new RTImage ("fullscreen-enter.png");
iFullscreen_exit = new RTImage ("fullscreen-leave.png");
+ Gtk::Button* iccProfileCreator = Gtk::manage (new Gtk::Button ());
+ setExpandAlignProperties (iccProfileCreator, false, false, Gtk::ALIGN_CENTER, Gtk::ALIGN_CENTER);
+ iccProfileCreator->set_image (*Gtk::manage (new RTImage ("gamut-plus.png")));
+ iccProfileCreator->set_tooltip_markup (M ("MAIN_BUTTON_ICCPROFCREATOR"));
+ iccProfileCreator->signal_clicked().connect ( sigc::mem_fun (*this, &RTWindow::showICCProfileCreator) );
+
//Gtk::LinkButton* rtWeb = Gtk::manage (new Gtk::LinkButton ("http://rawtherapee.com")); // unused... but fail to be linked anyway !?
//Gtk::Button* preferences = Gtk::manage (new Gtk::Button (M("MAIN_BUTTON_PREFERENCES")+"..."));
Gtk::Button* preferences = Gtk::manage (new Gtk::Button ());
@@ -257,6 +264,7 @@ RTWindow::RTWindow ()
prProgBar.set_inverted (true);
actionGrid->set_orientation (Gtk::ORIENTATION_VERTICAL);
actionGrid->attach_next_to (prProgBar, Gtk::POS_BOTTOM, 1, 1);
+ actionGrid->attach_next_to (*iccProfileCreator, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*preferences, Gtk::POS_BOTTOM, 1, 1);
actionGrid->attach_next_to (*btn_fullscreen, Gtk::POS_BOTTOM, 1, 1);
mainNB->set_action_widget (actionGrid, Gtk::PACK_END);
@@ -264,6 +272,7 @@ RTWindow::RTWindow ()
prProgBar.set_orientation (Gtk::ORIENTATION_HORIZONTAL);
actionGrid->set_orientation (Gtk::ORIENTATION_HORIZONTAL);
actionGrid->attach_next_to (prProgBar, Gtk::POS_RIGHT, 1, 1);
+ actionGrid->attach_next_to (*iccProfileCreator, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*preferences, Gtk::POS_RIGHT, 1, 1);
actionGrid->attach_next_to (*btn_fullscreen, Gtk::POS_RIGHT, 1, 1);
mainNB->set_action_widget (actionGrid, Gtk::PACK_END);
@@ -748,6 +757,23 @@ void RTWindow::writeToolExpandedStatus (std::vector &tpOpen)
}
+void RTWindow::showICCProfileCreator ()
+{
+ ICCProfileCreator *iccpc = new ICCProfileCreator (this);
+ iccpc->run ();
+ delete iccpc;
+
+ fpanel->optionsChanged ();
+
+ if (epanel) {
+ epanel->defaultMonitorProfileChanged (options.rtSettings.monitorProfile, options.rtSettings.autoMonitorProfile);
+ }
+
+ for (const auto &p : epanels) {
+ p.second->defaultMonitorProfileChanged (options.rtSettings.monitorProfile, options.rtSettings.autoMonitorProfile);
+ }
+}
+
void RTWindow::showPreferences ()
{
Preferences *pref = new Preferences (this);
diff --git a/rtgui/rtwindow.h b/rtgui/rtwindow.h
index e9fe51b1d..7bb818c7c 100644
--- a/rtgui/rtwindow.h
+++ b/rtgui/rtwindow.h
@@ -86,6 +86,7 @@ public:
bool on_window_state_event (GdkEventWindowState* event);
void on_mainNB_switch_page (Gtk::Widget* widget, guint page_num);
+ void showICCProfileCreator ();
void showPreferences ();
void on_realize ();
void toggle_fullscreen ();
diff --git a/tools/source_icons/scalable/gamut-plus.file b/tools/source_icons/scalable/gamut-plus.file
new file mode 100644
index 000000000..ec6f9f83f
--- /dev/null
+++ b/tools/source_icons/scalable/gamut-plus.file
@@ -0,0 +1 @@
+gamut-plus.png,w22,actions
diff --git a/tools/source_icons/scalable/gamut-plus.svg b/tools/source_icons/scalable/gamut-plus.svg
new file mode 100644
index 000000000..268bcde62
--- /dev/null
+++ b/tools/source_icons/scalable/gamut-plus.svg
@@ -0,0 +1,653 @@
+
+
+
+