diff --git a/rtdata/languages/Francais b/rtdata/languages/Francais
index a38254bb8..1262cd065 100644
--- a/rtdata/languages/Francais
+++ b/rtdata/languages/Francais
@@ -731,10 +731,14 @@ PROFILEPANEL_PLASTPHOTO;Photo précédente
PROFILEPANEL_PLASTSAVED;Dernière sauvegarde
PROFILEPANEL_PROFILE;Profil
PROFILEPANEL_SAVEDLGLABEL;Enregistrer les paramètres de post-traitement...
-PROFILEPANEL_TOOLTIPCOPY;Copie le profil courant dans le presse-papier
-PROFILEPANEL_TOOLTIPLOAD;Charger un profil depuis un fichier
-PROFILEPANEL_TOOLTIPPASTE; Colle le profil depuis le presse-papier
-PROFILEPANEL_TOOLTIPSAVE;Enregistrer le profil actuel
+PROFILEPANEL_COPYPPASTE;Paramètres à copier
+PROFILEPANEL_LOADPPASTE;Paramètres à charger
+PROFILEPANEL_PASTEPPASTE;Paramètres à coller
+PROFILEPANEL_SAVEPPASTE;Paramètres à enregistrer
+PROFILEPANEL_TOOLTIPCOPY;Copie le profil courant dans le presse-papier\nCTRL-clic pour sélectionner les paramètres à copier
+PROFILEPANEL_TOOLTIPLOAD;Charger un profil depuis un fichier\nCTRL-clic pour sélectionner les paramètres à charger
+PROFILEPANEL_TOOLTIPPASTE;Colle le profil depuis le presse-papier\nCTRL-clic pour sélectionner les paramètres à coller
+PROFILEPANEL_TOOLTIPSAVE;Enregistrer le profil actuel\nCTRL-clic pour sélectionner les paramètres à enregistrer
PROGRESSBAR_BADPIXELS;Pixels chauds/morts...
PROGRESSBAR_CACORRECTION;Correction de l'aberr. chomatique...
PROGRESSBAR_DARKFRAME;Trame Noire...
@@ -808,6 +812,7 @@ TP_COLORSHIFT_GREENMAGENTA;Vert-Magenta
TP_COLORSHIFT_LABEL;Décalage couleur
TP_CROP_FIXRATIO;Ratio fixe:
TP_CROP_GTDIAGONALS;Règle des diagonales
+TP_CROP_GTEPASSPORT;Passeport biométrique
TP_CROP_GTGRID;Grille
TP_CROP_GTHARMMEANS1;Manière harmonique 1
TP_CROP_GTHARMMEANS2;Manière harmonique 2
@@ -927,6 +932,7 @@ TP_PERSPECTIVE_LABEL;Perspective
TP_PERSPECTIVE_VERTICAL;Verticale
TP_PREPROCESS_GREENEQUIL;Équilibrage du vert
TP_PREPROCESS_HOTDEADPIXFILT;Filtrer les pixels chauds/morts
+TP_PREPROCESS_HOTDEADPIXTHRESH;Seuil de détection des pixels morts
TP_PREPROCESS_LABEL;Traitement pre-dématriçage
TP_PREPROCESS_LINEDENOISE;Filtre de bruit de ligne
TP_PREPROCESS_NO_FOUND;Aucun trouvé
diff --git a/rtdata/languages/default b/rtdata/languages/default
index c811628f3..bfa94fe7e 100644
--- a/rtdata/languages/default
+++ b/rtdata/languages/default
@@ -748,10 +748,14 @@ PROFILEPANEL_PLASTPHOTO;Last Photo
PROFILEPANEL_PLASTSAVED;Last Saved
PROFILEPANEL_PROFILE;Profile
PROFILEPANEL_SAVEDLGLABEL;Save Postprocessing Parameters...
-PROFILEPANEL_TOOLTIPCOPY;Copy current profile to clipboard
-PROFILEPANEL_TOOLTIPLOAD;Load a profile from file
-PROFILEPANEL_TOOLTIPPASTE; Paste profile from clipboard
-PROFILEPANEL_TOOLTIPSAVE;Save current profile
+PROFILEPANEL_COPYPPASTE;Parameters to copy
+PROFILEPANEL_LOADPPASTE;Parameters to load
+PROFILEPANEL_PASTEPPASTE;Parameters to paste
+PROFILEPANEL_SAVEPPASTE;Parameters to save
+PROFILEPANEL_TOOLTIPCOPY;Copy current profile to clipboard\nCTRL-click to select the parameters to copy
+PROFILEPANEL_TOOLTIPLOAD;Load a profile from file\nCTRL-click to select the parameters to load
+PROFILEPANEL_TOOLTIPPASTE;Paste profile from clipboard\nCTRL-click key to select the parameters to paste
+PROFILEPANEL_TOOLTIPSAVE;Save current profile\nCTRL-click key to select the parameters to save
PROGRESSBAR_BADPIXELS;Bad pixels...
PROGRESSBAR_CACORRECTION;CA correction...
PROGRESSBAR_DARKFRAME;Darkframe...
@@ -955,6 +959,7 @@ TP_PERSPECTIVE_LABEL;Perspective
TP_PERSPECTIVE_VERTICAL;Vertical
TP_PREPROCESS_GREENEQUIL;Green equilibration
TP_PREPROCESS_HOTDEADPIXFILT;Apply hot/dead pixel filter
+TP_PREPROCESS_HOTDEADPIXTHRESH;Hot/dead pixel detection threshold
TP_PREPROCESS_LABEL;Preprocessing
TP_PREPROCESS_LINEDENOISE;Line noise filter
TP_PREPROCESS_NO_FOUND;None found
@@ -1101,4 +1106,5 @@ ZOOMPANEL_ZOOMFITSCREEN;Fit to screen F
ZOOMPANEL_ZOOMIN;Zoom In +
ZOOMPANEL_ZOOMOUT;Zoom Out -
#00 default translation file
-#01 Developers should add translations to this file and then run 'generateDifferences.sh' script to update other locales.
+#01 Developers should add translations to this file and then run 'generateTranslationDiffs' script to update other locales.
+#02 WARNING: This script works on Linux only
diff --git a/rtdata/profiles/BW-1.pp3 b/rtdata/profiles/BW-1.pp3
index f8aa974db..6e126b417 100644
--- a/rtdata/profiles/BW-1.pp3
+++ b/rtdata/profiles/BW-1.pp3
@@ -19,7 +19,7 @@ Black=0
HighlightCompr=0
HighlightComprThreshold=33
ShadowCompr=50
-Curve=1;0;0;0.040000000000000015;0.029999999999999995;0.17684498029510265;0.21732319394192093;0.70232558139534862;0.74883720930232545;1;1;
+Curve=1;0;0;0.04;0.03;0.17684498029510265;0.21732319394192093;0.70232558139534862;0.74883720930232545;1;1;
[Channel Mixer]
Red=100;0;0;
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/BW-2.pp3 b/rtdata/profiles/BW-2.pp3
index 1ffc444c6..b22114c4a 100644
--- a/rtdata/profiles/BW-2.pp3
+++ b/rtdata/profiles/BW-2.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/BW-3.pp3 b/rtdata/profiles/BW-3.pp3
index 03130b738..e70e43ad3 100644
--- a/rtdata/profiles/BW-3.pp3
+++ b/rtdata/profiles/BW-3.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,21 +74,11 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
+Temperature=5745
Green=1.0
-[Color Shift]
-ChannelA=0
-ChannelB=0
-
[Impulse Denoising]
Enabled=false
Threshold=50
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4276
-H=2836
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4276
-Height=2836
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/BW-4.pp3 b/rtdata/profiles/BW-4.pp3
index 67596d667..ddd7361d0 100644
--- a/rtdata/profiles/BW-4.pp3
+++ b/rtdata/profiles/BW-4.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,21 +74,11 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
+Temperature=5745
Green=1.0
-[Color Shift]
-ChannelA=0
-ChannelB=0
-
[Impulse Denoising]
Enabled=false
Threshold=50
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4276
-H=2836
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4276
-Height=2836
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/Highkey-1.pp3 b/rtdata/profiles/Highkey-1.pp3
index f5a34bafc..b83d3f82f 100644
--- a/rtdata/profiles/Highkey-1.pp3
+++ b/rtdata/profiles/Highkey-1.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/Natural-1.pp3 b/rtdata/profiles/Natural-1.pp3
index 2cf6e2217..6ca2bfb7d 100644
--- a/rtdata/profiles/Natural-1.pp3
+++ b/rtdata/profiles/Natural-1.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/Natural-2.pp3 b/rtdata/profiles/Natural-2.pp3
index 004cee28e..7d7c6b93b 100644
--- a/rtdata/profiles/Natural-2.pp3
+++ b/rtdata/profiles/Natural-2.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/Punchy-1.pp3 b/rtdata/profiles/Punchy-1.pp3
index 2c0eca159..969a1cc1d 100644
--- a/rtdata/profiles/Punchy-1.pp3
+++ b/rtdata/profiles/Punchy-1.pp3
@@ -11,7 +11,7 @@ InTrash=false
[Exposure]
Auto=true
Clip=0
-Compensation=-0
+Compensation=0.0
Brightness=0
Contrast=0
Saturation=0
@@ -74,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
Temperature=5745
-Green=1.0353332844067824
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -106,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -125,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4276
-H=2836
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1.0
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -202,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/Punchy-2.pp3 b/rtdata/profiles/Punchy-2.pp3
index 401a491ae..31256eee3 100644
--- a/rtdata/profiles/Punchy-2.pp3
+++ b/rtdata/profiles/Punchy-2.pp3
@@ -74,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
Temperature=5745
-Green=1.0349999999999993
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -106,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -125,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4276
-H=2836
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1.0
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4276
-Height=2836
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -202,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/default-ISO-high.pp3 b/rtdata/profiles/default-ISO-high.pp3
index 3326523ad..034061cf7 100644
--- a/rtdata/profiles/default-ISO-high.pp3
+++ b/rtdata/profiles/default-ISO-high.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=true
@@ -97,15 +96,6 @@ Gamma=1.2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/default-ISO-medium.pp3 b/rtdata/profiles/default-ISO-medium.pp3
index 679934bd4..98ff56a44 100644
--- a/rtdata/profiles/default-ISO-medium.pp3
+++ b/rtdata/profiles/default-ISO-medium.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=true
@@ -97,15 +96,6 @@ Gamma=1.2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/default.pp3 b/rtdata/profiles/default.pp3
index 52122c976..58955be74 100644
--- a/rtdata/profiles/default.pp3
+++ b/rtdata/profiles/default.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5000
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,60 +106,13 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4281
-H=2871
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4281
-Height=2871
-
[Color Management]
InputProfile=(cameraICC)
BlendCMSMatrix=true
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtdata/profiles/full neutral.pp3 b/rtdata/profiles/full neutral.pp3
new file mode 100644
index 000000000..34b482458
--- /dev/null
+++ b/rtdata/profiles/full neutral.pp3
@@ -0,0 +1,216 @@
+
+[Version]
+AppVersion=4.0.6
+Version=301
+
+[General]
+Rank=0
+ColorLabel=0
+InTrash=false
+
+[Exposure]
+Auto=false
+Clip=0.0000
+Compensation=0
+Brightness=0
+Contrast=0
+Saturation=0
+Black=0
+HighlightCompr=0
+HighlightComprThreshold=0
+ShadowCompr=0
+Curve=0;
+
+[Channel Mixer]
+Red=100;0;0;
+Green=0;100;0;
+Blue=0;0;100;
+
+[Luminance Curve]
+Brightness=0
+Contrast=0
+Saturation=0
+AvoidColorClipping=false
+SaturationLimiter=false
+SaturationLimit=50
+LCurve=0;
+aCurve=0;
+bCurve=0;
+
+[Sharpening]
+Enabled=false
+Method=usm
+Radius=0.5
+Amount=125
+Threshold=512
+OnlyEdges=false
+EdgedetectionRadius=1.9
+EdgeTolerance=1800
+HalocontrolEnabled=false
+HalocontrolAmount=85
+DeconvRadius=0.75
+DeconvAmount=75
+DeconvDamping=20
+DeconvIterations=30
+
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
+[SharpenEdge]
+Enabled=false
+Passes=2
+Strength=50
+ThreeChannels=false
+
+[SharpenMicro]
+Enabled=false
+Matrix=false
+Strength=20
+Uniformity=50
+
+[White Balance]
+Setting=Camera
+Temperature=5745
+Green=1.0
+
+[Impulse Denoising]
+Enabled=false
+Threshold=50
+
+[Defringing]
+Enabled=false
+Radius=2.0
+Threshold=25
+
+[Directional Pyramid Denoising]
+Enabled=false
+Luma=5
+Chroma=5
+Gamma=2
+LumCurve=0;
+ChromCurve=0;
+
+[Shadows & Highlights]
+Enabled=false
+HighQuality=false
+Highlights=10
+HighlightTonalWidth=80
+Shadows=10
+ShadowTonalWidth=80
+LocalContrast=0
+Radius=30
+
+[Crop]
+Enabled=false
+X=0
+Y=0
+W=4276
+H=2836
+FixedRatio=false
+Ratio=3:2
+Orientation=Landscape
+Guide=None
+
+[Coarse Transformation]
+Rotate=0
+HorizontalFlip=false
+VerticalFlip=false
+
+[Common Properties for Transformations]
+AutoFill=false
+
+[Rotation]
+Degree=0
+
+[Distortion]
+Amount=0
+UseLensFun=false
+
+[Perspective]
+Horizontal=0
+Vertical=0
+
+[CACorrection]
+Red=0
+Blue=0
+
+[Vignetting Correction]
+Amount=0
+Radius=50
+Strength=1
+CenterX=0
+CenterY=0
+
+[HLRecovery]
+Enabled=false
+Method=Blend
+
+[Resize]
+Enabled=false
+Scale=1
+AppliesTo=Cropped area
+Method=Bicubic
+DataSpecified=0
+Width=4276
+Height=2836
+
+[Color Management]
+InputProfile=(cameraICC)
+BlendCMSMatrix=true
+WorkingProfile=sRGB
+OutputProfile=RT_sRGB
+Gammafree=default
+Freegamma=false
+GammaValue=2.22
+GammaSlope=4.5
+
+[Directional Pyramid Equalizer]
+Enabled=false
+Mult0=1
+Mult1=1
+Mult2=1
+Mult3=1
+Mult4=0.2
+
+[HSV Equalizer]
+HCurve=0;
+SCurve=0;
+VCurve=0;
+
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
+[RAW]
+DarkFrame=
+DarkFrameAuto=false
+FlatFieldFile=
+FlatFieldAutoSelect=false
+FlatFieldBlurRadius=32
+FlatFieldBlurType=Area Flatfield
+CA=false
+CARed=0
+CABlue=0
+HotDeadPixels=false
+HotDeadPixelThresh=40
+LineDenoise=0
+GreenEqThreshold=0
+CcSteps=1
+Method=amaze
+DCBIterations=2
+DCBEnhance=false
+ALLEnhance=false
+PreExposure=1
+PrePreserv=0
+PreBlackzero=0
+PreBlackone=0
+PreBlacktwo=0
+PreBlackthree=0
+PreTwoGreen=true
diff --git a/rtdata/profiles/neutral.pp3 b/rtdata/profiles/neutral.pp3
index 8b8250f65..53c4e6f34 100644
--- a/rtdata/profiles/neutral.pp3
+++ b/rtdata/profiles/neutral.pp3
@@ -53,6 +53,15 @@ DeconvAmount=75
DeconvDamping=20
DeconvIterations=30
+[Vibrance]
+Enabled=false
+Pastels=50
+Saturated=50
+PSThreshold=75
+ProtectSkins=false
+AvoidColorShift=true
+PastSatTog=true
+
[SharpenEdge]
Enabled=false
Passes=2
@@ -65,20 +74,10 @@ Matrix=false
Strength=20
Uniformity=50
-[Color Boost]
-Amount=0
-AvoidColorClipping=false
-SaturationLimiter=false
-SaturationLimit=75
-
[White Balance]
Setting=Camera
-Temperature=5200
-Green=1
-
-[Color Shift]
-ChannelA=0
-ChannelB=0
+Temperature=5745
+Green=1.0
[Impulse Denoising]
Enabled=false
@@ -86,7 +85,7 @@ Threshold=50
[Defringing]
Enabled=false
-Radius=2
+Radius=2.0
Threshold=25
[Directional Pyramid Denoising]
@@ -97,15 +96,6 @@ Gamma=2
LumCurve=0;
ChromCurve=0;
-[Luminance Denoising]
-Enabled=false
-Radius=2.5
-EdgeTolerance=1500
-
-[Chrominance Denoising]
-Enabled=false
-Amount=20
-
[Shadows & Highlights]
Enabled=false
HighQuality=false
@@ -116,69 +106,22 @@ ShadowTonalWidth=80
LocalContrast=0
Radius=30
-[Crop]
-Enabled=false
-X=0
-Y=0
-W=4276
-H=2836
-FixedRatio=false
-Ratio=3:2
-Orientation=Landscape
-Guide=None
-
-[Coarse Transformation]
-Rotate=0
-HorizontalFlip=false
-VerticalFlip=false
-
[Common Properties for Transformations]
AutoFill=false
-[Rotation]
-Degree=0
-
-[Distortion]
-Amount=0
-UseLensFun=false
-
-[Perspective]
-Horizontal=0
-Vertical=0
-
-[CACorrection]
-Red=0
-Blue=0
-
-[Vignetting Correction]
-Amount=0
-Radius=50
-Strength=1
-CenterX=0
-CenterY=0
-
[HLRecovery]
Enabled=false
Method=Blend
-[Resize]
-Enabled=false
-Scale=1
-AppliesTo=Cropped area
-Method=Bicubic
-DataSpecified=0
-Width=4276
-Height=2836
-
[Color Management]
-InputProfile=(cameraICC)
-BlendCMSMatrix=true
-WorkingProfile=sRGB
-OutputProfile=RT_sRGB
+InputProfile=(cameraICC)
+BlendCMSMatrix=true
+WorkingProfile=sRGB
+OutputProfile=RT_sRGB
Gammafree=default
Freegamma=false
-GammaValue=2.22
-GammaSlope=4.5
+GammaValue=2.22
+GammaSlope=4.5
[Directional Pyramid Equalizer]
Enabled=false
@@ -193,13 +136,12 @@ HCurve=0;
SCurve=0;
VCurve=0;
+[RGB Curves]
+rCurve=0;
+gCurve=0;
+bCurve=0;
+
[RAW]
-DarkFrame=
-DarkFrameAuto=false
-FlatFieldFile=
-FlatFieldAutoSelect=false
-FlatFieldBlurRadius=32
-FlatFieldBlurType=Area Flatfield
CA=false
CARed=0
CABlue=0
diff --git a/rtengine/imagedata.cc b/rtengine/imagedata.cc
index 733c28354..508df3a80 100644
--- a/rtengine/imagedata.cc
+++ b/rtengine/imagedata.cc
@@ -277,9 +277,9 @@ ImageData::~ImageData () {
iptc_data_free (iptc);
}
-const std::vector ImageData::getIPTCData () const {
+const procparams::IPTCPairs ImageData::getIPTCData () const {
- std::vector iptcc;
+ procparams::IPTCPairs iptcc;
if (!iptc)
return iptcc;
@@ -288,31 +288,28 @@ const std::vector ImageData::getIPTCData () const {
IptcDataSet* ds = iptc_data_get_next_dataset (iptc, NULL, IPTC_RECORD_APP_2, strTags[i].tag);
if (ds) {
iptc_dataset_get_data (ds, buffer, 2100);
- procparams::IPTCPair ic;
- ic.field = strTags[i].field;
- ic.values.push_back (safe_locale_to_utf8((char*)buffer));
+ std::vector icValues;
+ icValues.push_back (safe_locale_to_utf8((char*)buffer));
- iptcc.push_back (ic);
+ iptcc[strTags[i].field] = icValues;
iptc_dataset_unref (ds);
}
}
IptcDataSet* ds = NULL;
- procparams::IPTCPair ickw;
- ickw.field = "Keywords";
+ std::vector keywords;
while ((ds=iptc_data_get_next_dataset (iptc, ds, IPTC_RECORD_APP_2, IPTC_TAG_KEYWORDS))) {
iptc_dataset_get_data (ds, buffer, 2100);
- ickw.values.push_back (safe_locale_to_utf8((char*)buffer));
+ keywords.push_back (safe_locale_to_utf8((char*)buffer));
}
- iptcc.push_back (ickw);
+ iptcc["Keywords"] = keywords;
ds = NULL;
- procparams::IPTCPair icsc;
- icsc.field = "SupplementalCategories";
+ std::vector suppCategories;
while ((ds=iptc_data_get_next_dataset (iptc, ds, IPTC_RECORD_APP_2, IPTC_TAG_SUPPL_CATEGORY))) {
iptc_dataset_get_data (ds, buffer, 2100);
- icsc.values.push_back (safe_locale_to_utf8((char*)buffer));
+ suppCategories.push_back (safe_locale_to_utf8((char*)buffer));
iptc_dataset_unref (ds);
}
- iptcc.push_back (icsc);
+ iptcc["SupplementalCategories"] = suppCategories;
return iptcc;
}
diff --git a/rtengine/imagedata.h b/rtengine/imagedata.h
index 9cfd7039d..f6f127ad5 100644
--- a/rtengine/imagedata.h
+++ b/rtengine/imagedata.h
@@ -55,7 +55,7 @@ class ImageData : public ImageMetaData {
virtual ~ImageData ();
const rtexif::TagDirectory* getExifData () const { return root; }
- const std::vector getIPTCData () const;
+ const procparams::IPTCPairs getIPTCData () const;
bool hasExif () const { return root && root->getCount(); }
bool hasIPTC () const { return iptc; }
diff --git a/rtengine/imageio.cc b/rtengine/imageio.cc
index df012bca7..440faede1 100644
--- a/rtengine/imageio.cc
+++ b/rtengine/imageio.cc
@@ -61,14 +61,17 @@ void ImageIO::setMetadata (const rtexif::TagDirectory* eroot) {
}
// For merging with RT specific data
-void ImageIO::setMetadata (const rtexif::TagDirectory* eroot, const std::vector& exif, const std::vector& iptcc) {
+void ImageIO::setMetadata (const rtexif::TagDirectory* eroot, const rtengine::procparams::ExifPairs& exif, const rtengine::procparams::IPTCPairs& iptcc) {
// store exif info
- exifChange.resize (exif.size());
- for (int i=0; ifirst;
+ exifChange.at(j).second = i->second;
+ j++;
+ }*/
if (exifRoot!=NULL) { delete exifRoot; exifRoot = NULL; }
@@ -82,23 +85,23 @@ void ImageIO::setMetadata (const rtexif::TagDirectory* eroot, const std::vector<
return;
iptc = iptc_data_new ();
- for (int i=0; ifirst == "Keywords" && !(i->second.empty())) {
+ for (unsigned int j=0; jsecond.size(); j++) {
IptcDataSet * ds = iptc_dataset_new ();
iptc_dataset_set_tag (ds, IPTC_RECORD_APP_2, IPTC_TAG_KEYWORDS);
- std::string loc = safe_locale_to_utf8(iptcc[i].values[j]);
+ std::string loc = safe_locale_to_utf8(i->second.at(j));
iptc_dataset_set_data (ds, (unsigned char*)loc.c_str(), MIN(64,loc.size()), IPTC_DONT_VALIDATE);
iptc_data_add_dataset (iptc, ds);
iptc_dataset_unref (ds);
}
continue;
}
- else if (iptcc[i].field == "SupplementalCategories" && !(iptcc[i].values.empty())) {
- for (int j=0; jfirst == "SupplementalCategories" && !(i->second.empty())) {
+ for (unsigned int j=0; jsecond.size(); j++) {
IptcDataSet * ds = iptc_dataset_new ();
iptc_dataset_set_tag (ds, IPTC_RECORD_APP_2, IPTC_TAG_SUPPL_CATEGORY);
- std::string loc = safe_locale_to_utf8(iptcc[i].values[j]);
+ std::string loc = safe_locale_to_utf8(i->second.at(j));
iptc_dataset_set_data (ds, (unsigned char*)loc.c_str(), MIN(32,loc.size()), IPTC_DONT_VALIDATE);
iptc_data_add_dataset (iptc, ds);
iptc_dataset_unref (ds);
@@ -106,10 +109,10 @@ void ImageIO::setMetadata (const rtexif::TagDirectory* eroot, const std::vector<
continue;
}
for (int j=0; j<16; j++)
- if (iptcc[i].field == strTags[j].field && !(iptcc[i].values.empty())) {
+ if (i->first == strTags[j].field && !(i->second.empty())) {
IptcDataSet * ds = iptc_dataset_new ();
iptc_dataset_set_tag (ds, IPTC_RECORD_APP_2, strTags[j].tag);
- std::string loc = safe_locale_to_utf8(iptcc[i].values[0]);
+ std::string loc = safe_locale_to_utf8(i->second.at(0));
iptc_dataset_set_data (ds, (unsigned char*)loc.c_str(), MIN(strTags[j].size,loc.size()), IPTC_DONT_VALIDATE);
iptc_data_add_dataset (iptc, ds);
iptc_dataset_unref (ds);
@@ -243,7 +246,7 @@ int ImageIO::loadPNG (Glib::ustring fname) {
png_read_row (png, (png_byte*)row, NULL);
if (bit_depth==16) { // convert scanline to host byte order
unsigned short* srow = (unsigned short*)row;
- for (int j=0; j > exifChange;
+ procparams::ExifPairs exifChange;
IptcData* iptc;
const rtexif::TagDirectory* exifRoot;
Glib::Mutex imutex;
public:
static Glib::ustring errorMsg[6];
-
+
ImageIO () : pl (NULL), embProfile(NULL), profileData(NULL), loadedProfileData(NULL), loadedProfileLength(0), iptc(NULL), exifRoot (NULL) {}
-
+
virtual ~ImageIO ();
void setProgressListener (ProgressListener* l) { pl = l; }
virtual int getW () =0;
- virtual int getH () =0;
- virtual void allocate (int width, int height) =0;
+ virtual int getH () =0;
+ virtual void allocate (int width, int height) =0;
virtual int getBPS () =0;
virtual void getScanline (int row, unsigned char* buffer, int bps) {}
virtual void setScanline (int row, unsigned char* buffer, int bps) {}
@@ -78,12 +78,12 @@ class ImageIO {
int savePNG (Glib::ustring fname, int compression = -1, volatile int bps = -1);
int saveJPEG (Glib::ustring fname, int quality = 100);
int saveTIFF (Glib::ustring fname, int bps = -1, bool uncompressed = false);
-
+
cmsHPROFILE getEmbeddedProfile () { return embProfile; }
void getEmbeddedProfileData (int& length, unsigned char*& pdata) { length = loadedProfileLength; pdata = (unsigned char*)loadedProfileData; }
- void setMetadata (const rtexif::TagDirectory* eroot);
- void setMetadata (const rtexif::TagDirectory* eroot, const std::vector& exif, const std::vector& iptcc);
+ void setMetadata (const rtexif::TagDirectory* eroot);
+ void setMetadata (const rtexif::TagDirectory* eroot, const rtengine::procparams::ExifPairs& exif, const rtengine::procparams::IPTCPairs& iptcc);
void setOutputProfile (char* pdata, int plen);
Glib::Mutex& mutex () { return imutex; }
};
diff --git a/rtengine/procparams.cc b/rtengine/procparams.cc
index 95bec374b..969c4796f 100644
--- a/rtengine/procparams.cc
+++ b/rtengine/procparams.cc
@@ -30,6 +30,7 @@
#include "safekeyfile.h"
#include "rawimage.h"
#include "../rtgui/ppversion.h"
+#include "../rtgui/paramsedited.h"
#define APPVERSION VERSION
@@ -186,31 +187,30 @@ void ProcParams::setDefaults () {
vibrance.protectskins = false;
vibrance.avoidcolorshift = true;
vibrance.pastsattog = true;
-
- colorBoost.amount = 0;
- colorBoost.avoidclip = false;
- colorBoost.enable_saturationlimiter = false;
- colorBoost.saturationlimit = 50;
-
+
+ //colorBoost.amount = 0;
+ //colorBoost.avoidclip = false;
+ //colorBoost.enable_saturationlimiter = false;
+ //colorBoost.saturationlimit = 50;
+
wb.method = "Camera";
wb.temperature = 6504;
wb.green = 1.0;
-
- colorShift.a = 0;
- colorShift.b = 0;
-
- lumaDenoise.enabled = false;
- lumaDenoise.radius = 1.9;
- lumaDenoise.edgetolerance = 2000;
-
- colorDenoise.enabled = false;
- colorDenoise.edgesensitive = false;
- colorDenoise.radius = 1.9;
- colorDenoise.edgetolerance = 2000;
-
+
+ //colorShift.a = 0;
+ //colorShift.b = 0;
+
+ //lumaDenoise.enabled = false;
+ //lumaDenoise.radius = 1.9;
+ //lumaDenoise.edgetolerance = 2000;
+
+ //colorDenoise.enabled = false;
+ //colorDenoise.edgesensitive = false;
+ //colorDenoise.edgetolerance = 2000;
+
impulseDenoise.enabled = false;
impulseDenoise.thresh = 50;
-
+
defringe.enabled = false;
defringe.radius = 2.0;
defringe.threshold = 25;
@@ -219,16 +219,12 @@ void ProcParams::setDefaults () {
dirpyrDenoise.luma = 10;
dirpyrDenoise.chroma = 10;
dirpyrDenoise.gamma = 2.0;
- dirpyrDenoise.lumcurve.clear ();
- dirpyrDenoise.lumcurve.push_back (DCT_Linear);
- dirpyrDenoise.chromcurve.clear ();
- dirpyrDenoise.chromcurve.push_back (DCT_Linear);
-
- edgePreservingDecompositionUI.enabled = false;
- edgePreservingDecompositionUI.Strength = 0.25;
- edgePreservingDecompositionUI.EdgeStopping = 1.4;
- edgePreservingDecompositionUI.Scale = 1.0;
- edgePreservingDecompositionUI.ReweightingIterates = 0;
+
+ edgePreservingDecompositionUI.enabled = false;
+ edgePreservingDecompositionUI.Strength = 0.25;
+ edgePreservingDecompositionUI.EdgeStopping = 1.4;
+ edgePreservingDecompositionUI.Scale = 1.0;
+ edgePreservingDecompositionUI.ReweightingIterates = 0;
sh.enabled = false;
sh.hq = false;
@@ -349,7 +345,7 @@ void ProcParams::setDefaults () {
ppVersion = PPVERSION;
}
-int ProcParams::save (Glib::ustring fname, Glib::ustring fname2) const {
+int ProcParams::save (Glib::ustring fname, Glib::ustring fname2, ParamsEdited* pedited) const {
if (!fname.length() && !fname2.length())
return 0;
@@ -359,270 +355,301 @@ int ProcParams::save (Glib::ustring fname, Glib::ustring fname2) const {
keyFile.set_string ("Version", "AppVersion", APPVERSION);
keyFile.set_integer ("Version", "Version", PPVERSION);
- keyFile.set_integer ("General", "Rank", rank);
- keyFile.set_integer ("General", "ColorLabel", colorlabel);
- keyFile.set_boolean ("General", "InTrash", inTrash);
+ if (!pedited || pedited->general.rank) keyFile.set_integer ("General", "Rank", rank);
+ if (!pedited || pedited->general.colorlabel) keyFile.set_integer ("General", "ColorLabel", colorlabel);
+ if (!pedited || pedited->general.intrash) keyFile.set_boolean ("General", "InTrash", inTrash);
// save tonecurve:
- keyFile.set_boolean ("Exposure", "Auto", toneCurve.autoexp);
- keyFile.set_double ("Exposure", "Clip", toneCurve.clip);
- keyFile.set_double ("Exposure", "Compensation", toneCurve.expcomp);
- keyFile.set_integer ("Exposure", "Brightness", toneCurve.brightness);
- keyFile.set_integer ("Exposure", "Contrast", toneCurve.contrast);
- keyFile.set_integer ("Exposure", "Saturation", toneCurve.saturation);
- keyFile.set_integer ("Exposure", "Black", toneCurve.black);
- keyFile.set_integer ("Exposure", "HighlightCompr", toneCurve.hlcompr);
- keyFile.set_integer ("Exposure", "HighlightComprThreshold", toneCurve.hlcomprthresh);
- keyFile.set_integer ("Exposure", "ShadowCompr", toneCurve.shcompr);
- Glib::ArrayHandle tcurve = toneCurve.curve;
- keyFile.set_double_list("Exposure", "Curve", tcurve);
+ if (!pedited || pedited->toneCurve.autoexp) keyFile.set_boolean ("Exposure", "Auto", toneCurve.autoexp);
+ if (!pedited || pedited->toneCurve.clip) keyFile.set_double ("Exposure", "Clip", toneCurve.clip);
+ if (!pedited || pedited->toneCurve.expcomp) keyFile.set_double ("Exposure", "Compensation", toneCurve.expcomp);
+ if (!pedited || pedited->toneCurve.brightness) keyFile.set_integer ("Exposure", "Brightness", toneCurve.brightness);
+ if (!pedited || pedited->toneCurve.contrast) keyFile.set_integer ("Exposure", "Contrast", toneCurve.contrast);
+ if (!pedited || pedited->toneCurve.saturation) keyFile.set_integer ("Exposure", "Saturation", toneCurve.saturation);
+ if (!pedited || pedited->toneCurve.black) keyFile.set_integer ("Exposure", "Black", toneCurve.black);
+ if (!pedited || pedited->toneCurve.hlcompr) keyFile.set_integer ("Exposure", "HighlightCompr", toneCurve.hlcompr);
+ if (!pedited || pedited->toneCurve.hlcomprthresh) keyFile.set_integer ("Exposure", "HighlightComprThreshold", toneCurve.hlcomprthresh);
+ if (!pedited || pedited->toneCurve.shcompr) keyFile.set_integer ("Exposure", "ShadowCompr", toneCurve.shcompr);
+ if (!pedited || pedited->toneCurve.curve) {
+ Glib::ArrayHandle tcurve = toneCurve.curve;
+ keyFile.set_double_list("Exposure", "Curve", tcurve);
+ }
// save channel mixer
- Glib::ArrayHandle rmix (chmixer.red, 3, Glib::OWNERSHIP_NONE);
- Glib::ArrayHandle gmix (chmixer.green, 3, Glib::OWNERSHIP_NONE);
- Glib::ArrayHandle bmix (chmixer.blue, 3, Glib::OWNERSHIP_NONE);
- keyFile.set_integer_list("Channel Mixer", "Red", rmix);
- keyFile.set_integer_list("Channel Mixer", "Green", gmix);
- keyFile.set_integer_list("Channel Mixer", "Blue", bmix);
+ 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);
+ }
+ 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);
+ }
+ 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);
+ }
// save luma curve
- keyFile.set_integer ("Luminance Curve", "Brightness", labCurve.brightness);
- keyFile.set_integer ("Luminance Curve", "Contrast", labCurve.contrast);
- keyFile.set_integer ("Luminance Curve", "Saturation", labCurve.saturation);
- keyFile.set_boolean ("Luminance Curve", "AvoidColorClipping", labCurve.avoidclip);
- keyFile.set_boolean ("Luminance Curve", "SaturationLimiter", labCurve.enable_saturationlimiter);
- keyFile.set_double ("Luminance Curve", "SaturationLimit", labCurve.saturationlimit);
- Glib::ArrayHandle lcurve = labCurve.lcurve;
- Glib::ArrayHandle acurve = labCurve.acurve;
- Glib::ArrayHandle bcurve = labCurve.bcurve;
- keyFile.set_double_list("Luminance Curve", "LCurve", lcurve);
- keyFile.set_double_list("Luminance Curve", "aCurve", acurve);
- keyFile.set_double_list("Luminance Curve", "bCurve", bcurve);
+ if (!pedited || pedited->labCurve.brightness) keyFile.set_integer ("Luminance Curve", "Brightness", labCurve.brightness);
+ if (!pedited || pedited->labCurve.contrast) keyFile.set_integer ("Luminance Curve", "Contrast", labCurve.contrast);
+ if (!pedited || pedited->labCurve.saturation) keyFile.set_integer ("Luminance Curve", "Saturation", labCurve.saturation);
+ if (!pedited || pedited->labCurve.avoidclip) keyFile.set_boolean ("Luminance Curve", "AvoidColorClipping", labCurve.avoidclip);
+ if (!pedited || pedited->labCurve.enable_saturationlimiter) keyFile.set_boolean ("Luminance Curve", "SaturationLimiter", labCurve.enable_saturationlimiter);
+ if (!pedited || pedited->labCurve.saturationlimit) keyFile.set_double ("Luminance Curve", "SaturationLimit", labCurve.saturationlimit);
+ if (!pedited || pedited->labCurve.lcurve) {
+ Glib::ArrayHandle lcurve = labCurve.lcurve;
+ keyFile.set_double_list("Luminance Curve", "LCurve", lcurve);
+ }
+ if (!pedited || pedited->labCurve.acurve) {
+ Glib::ArrayHandle acurve = labCurve.acurve;
+ keyFile.set_double_list("Luminance Curve", "aCurve", acurve);
+ }
+ if (!pedited || pedited->labCurve.bcurve) {
+ Glib::ArrayHandle bcurve = labCurve.bcurve;
+ keyFile.set_double_list("Luminance Curve", "bCurve", bcurve);
+ }
// save sharpening
- keyFile.set_boolean ("Sharpening", "Enabled", sharpening.enabled);
- keyFile.set_string ("Sharpening", "Method", sharpening.method);
- keyFile.set_double ("Sharpening", "Radius", sharpening.radius);
- keyFile.set_integer ("Sharpening", "Amount", sharpening.amount);
- keyFile.set_integer ("Sharpening", "Threshold", sharpening.threshold);
- keyFile.set_boolean ("Sharpening", "OnlyEdges", sharpening.edgesonly);
- keyFile.set_double ("Sharpening", "EdgedetectionRadius", sharpening.edges_radius);
- keyFile.set_integer ("Sharpening", "EdgeTolerance", sharpening.edges_tolerance);
- keyFile.set_boolean ("Sharpening", "HalocontrolEnabled", sharpening.halocontrol);
- keyFile.set_integer ("Sharpening", "HalocontrolAmount", sharpening.halocontrol_amount);
- keyFile.set_double ("Sharpening", "DeconvRadius", sharpening.deconvradius);
- keyFile.set_integer ("Sharpening", "DeconvAmount", sharpening.deconvamount);
- keyFile.set_integer ("Sharpening", "DeconvDamping", sharpening.deconvdamping);
- keyFile.set_integer ("Sharpening", "DeconvIterations", sharpening.deconviter);
+ if (!pedited || pedited->sharpening.enabled) keyFile.set_boolean ("Sharpening", "Enabled", sharpening.enabled);
+ if (!pedited || pedited->sharpening.method) keyFile.set_string ("Sharpening", "Method", sharpening.method);
+ if (!pedited || pedited->sharpening.radius) keyFile.set_double ("Sharpening", "Radius", sharpening.radius);
+ if (!pedited || pedited->sharpening.amount) keyFile.set_integer ("Sharpening", "Amount", sharpening.amount);
+ if (!pedited || pedited->sharpening.threshold) keyFile.set_integer ("Sharpening", "Threshold", sharpening.threshold);
+ if (!pedited || pedited->sharpening.edgesonly) keyFile.set_boolean ("Sharpening", "OnlyEdges", sharpening.edgesonly);
+ if (!pedited || pedited->sharpening.edges_radius) keyFile.set_double ("Sharpening", "EdgedetectionRadius", sharpening.edges_radius);
+ if (!pedited || pedited->sharpening.edges_tolerance) keyFile.set_integer ("Sharpening", "EdgeTolerance", sharpening.edges_tolerance);
+ if (!pedited || pedited->sharpening.halocontrol) keyFile.set_boolean ("Sharpening", "HalocontrolEnabled", sharpening.halocontrol);
+ if (!pedited || pedited->sharpening.halocontrol_amount) keyFile.set_integer ("Sharpening", "HalocontrolAmount", sharpening.halocontrol_amount);
+ if (!pedited || pedited->sharpening.deconvradius) keyFile.set_double ("Sharpening", "DeconvRadius", sharpening.deconvradius);
+ if (!pedited || pedited->sharpening.deconvamount) keyFile.set_integer ("Sharpening", "DeconvAmount", sharpening.deconvamount);
+ if (!pedited || pedited->sharpening.deconvdamping) keyFile.set_integer ("Sharpening", "DeconvDamping", sharpening.deconvdamping);
+ if (!pedited || pedited->sharpening.deconviter) keyFile.set_integer ("Sharpening", "DeconvIterations", sharpening.deconviter);
// save vibrance
- keyFile.set_boolean ("Vibrance", "Enabled", vibrance.enabled);
- keyFile.set_integer ("Vibrance", "Pastels", vibrance.pastels);
- keyFile.set_integer ("Vibrance", "Saturated", vibrance.saturated);
- keyFile.set_integer ("Vibrance", "PSThreshold", vibrance.psthreshold);
- keyFile.set_boolean ("Vibrance", "ProtectSkins", vibrance.protectskins);
- keyFile.set_boolean ("Vibrance", "AvoidColorShift", vibrance.avoidcolorshift);
- keyFile.set_boolean ("Vibrance", "PastSatTog", vibrance.pastsattog);
+ if (!pedited || pedited->vibrance.enabled) keyFile.set_boolean ("Vibrance", "Enabled", vibrance.enabled);
+ if (!pedited || pedited->vibrance.pastels) keyFile.set_integer ("Vibrance", "Pastels", vibrance.pastels);
+ if (!pedited || pedited->vibrance.saturated) keyFile.set_integer ("Vibrance", "Saturated", vibrance.saturated);
+ if (!pedited || pedited->vibrance.psthreshold) keyFile.set_integer ("Vibrance", "PSThreshold", vibrance.psthreshold);
+ if (!pedited || pedited->vibrance.protectskins) keyFile.set_boolean ("Vibrance", "ProtectSkins", vibrance.protectskins);
+ if (!pedited || pedited->vibrance.avoidcolorshift) keyFile.set_boolean ("Vibrance", "AvoidColorShift", vibrance.avoidcolorshift);
+ if (!pedited || pedited->vibrance.pastsattog) keyFile.set_boolean ("Vibrance", "PastSatTog", vibrance.pastsattog);
//save edge sharpening
- keyFile.set_boolean ("SharpenEdge", "Enabled", sharpenEdge.enabled);
- keyFile.set_integer ("SharpenEdge", "Passes", sharpenEdge.passes);
- keyFile.set_double ("SharpenEdge", "Strength", sharpenEdge.amount);
- keyFile.set_boolean ("SharpenEdge", "ThreeChannels", sharpenEdge.threechannels);
+ if (!pedited || pedited->sharpenEdge.enabled) keyFile.set_boolean ("SharpenEdge", "Enabled", sharpenEdge.enabled);
+ if (!pedited || pedited->sharpenEdge.passes) keyFile.set_integer ("SharpenEdge", "Passes", sharpenEdge.passes);
+ if (!pedited || pedited->sharpenEdge.amount) keyFile.set_double ("SharpenEdge", "Strength", sharpenEdge.amount);
+ if (!pedited || pedited->sharpenEdge.threechannels) keyFile.set_boolean ("SharpenEdge", "ThreeChannels", sharpenEdge.threechannels);
//save micro-contrast sharpening
- keyFile.set_boolean ("SharpenMicro", "Enabled", sharpenMicro.enabled);
- keyFile.set_boolean ("SharpenMicro", "Matrix", sharpenMicro.matrix);
- keyFile.set_double ("SharpenMicro", "Strength", sharpenMicro.amount);
- keyFile.set_double ("SharpenMicro", "Uniformity", sharpenMicro.uniformity);
+ if (!pedited || pedited->sharpenMicro.enabled) keyFile.set_boolean ("SharpenMicro", "Enabled", sharpenMicro.enabled);
+ if (!pedited || pedited->sharpenMicro.matrix) keyFile.set_boolean ("SharpenMicro", "Matrix", sharpenMicro.matrix);
+ if (!pedited || pedited->sharpenMicro.amount) keyFile.set_double ("SharpenMicro", "Strength", sharpenMicro.amount);
+ if (!pedited || pedited->sharpenMicro.uniformity) keyFile.set_double ("SharpenMicro", "Uniformity", sharpenMicro.uniformity);
+/*
// save colorBoost
- keyFile.set_integer ("Color Boost", "Amount", colorBoost.amount);
- keyFile.set_boolean ("Color Boost", "AvoidColorClipping", colorBoost.avoidclip);
- keyFile.set_boolean ("Color Boost", "SaturationLimiter", colorBoost.enable_saturationlimiter);
- keyFile.set_double ("Color Boost", "SaturationLimit", colorBoost.saturationlimit);
+ if (!pedited || pedited->colorBoost.amount) keyFile.set_integer ("Color Boost", "Amount", colorBoost.amount);
+ if (!pedited || pedited->colorBoost.avoidclip) keyFile.set_boolean ("Color Boost", "AvoidColorClipping", colorBoost.avoidclip);
+ if (!pedited || pedited->colorBoost.enable_saturationlimiter) keyFile.set_boolean ("Color Boost", "SaturationLimiter", colorBoost.enable_saturationlimiter);
+ if (!pedited || pedited->colorBoost.saturationlimit) keyFile.set_double ("Color Boost", "SaturationLimit", colorBoost.saturationlimit);
+*/
// save wb
- keyFile.set_string ("White Balance", "Setting", wb.method);
- keyFile.set_integer ("White Balance", "Temperature", wb.temperature);
- keyFile.set_double ("White Balance", "Green", wb.green);
-
+ if (!pedited || pedited->wb.method) keyFile.set_string ("White Balance", "Setting", wb.method);
+ if (!pedited || pedited->wb.temperature) keyFile.set_integer ("White Balance", "Temperature", wb.temperature);
+ if (!pedited || pedited->wb.green) keyFile.set_double ("White Balance", "Green", wb.green);
+
+/*
// save colorShift
- keyFile.set_double ("Color Shift", "ChannelA", colorShift.a);
- keyFile.set_double ("Color Shift", "ChannelB", colorShift.b);
-
- // save impulseDenoise
- keyFile.set_boolean ("Impulse Denoising", "Enabled", impulseDenoise.enabled);
- keyFile.set_integer ("Impulse Denoising", "Threshold", impulseDenoise.thresh);
+ if (!pedited || pedited->colorShift.a) keyFile.set_double ("Color Shift", "ChannelA", colorShift.a);
+ if (!pedited || pedited->colorShift.b) keyFile.set_double ("Color Shift", "ChannelB", colorShift.b);
+*/
- // save defringe
- keyFile.set_boolean ("Defringing", "Enabled", defringe.enabled);
- keyFile.set_double ("Defringing", "Radius", defringe.radius);
- keyFile.set_integer ("Defringing", "Threshold", defringe.threshold);
-
- // save dirpyrDenoise
- keyFile.set_boolean ("Directional Pyramid Denoising", "Enabled", dirpyrDenoise.enabled);
- keyFile.set_integer ("Directional Pyramid Denoising", "Luma", dirpyrDenoise.luma);
- keyFile.set_integer ("Directional Pyramid Denoising", "Chroma", dirpyrDenoise.chroma);
- keyFile.set_double ("Directional Pyramid Denoising", "Gamma", dirpyrDenoise.gamma);
- Glib::ArrayHandle lumcurve = dirpyrDenoise.lumcurve;
- Glib::ArrayHandle chromcurve = dirpyrDenoise.chromcurve;
- keyFile.set_double_list("Directional Pyramid Denoising", "LumCurve", lumcurve);
- keyFile.set_double_list("Directional Pyramid Denoising", "ChromCurve", chromcurve);
+ // save impulseDenoise
+ if (!pedited || pedited->impulseDenoise.enabled) keyFile.set_boolean ("Impulse Denoising", "Enabled", impulseDenoise.enabled);
+ if (!pedited || pedited->impulseDenoise.thresh) keyFile.set_integer ("Impulse Denoising", "Threshold", impulseDenoise.thresh);
- //Save edgePreservingDecompositionUI.
- keyFile.set_boolean ("EPD", "Enabled", edgePreservingDecompositionUI.enabled);
- keyFile.set_double ("EPD", "Strength", edgePreservingDecompositionUI.Strength);
- keyFile.set_double ("EPD", "EdgeStopping", edgePreservingDecompositionUI.EdgeStopping);
- keyFile.set_double ("EPD", "Scale", edgePreservingDecompositionUI.Scale);
- keyFile.set_integer ("EPD", "ReweightingIterates", edgePreservingDecompositionUI.ReweightingIterates);
+ // save defringe
+ if (!pedited || pedited->defringe.enabled) keyFile.set_boolean ("Defringing", "Enabled", defringe.enabled);
+ if (!pedited || pedited->defringe.radius) keyFile.set_double ("Defringing", "Radius", defringe.radius);
+ if (!pedited || pedited->defringe.threshold) keyFile.set_integer ("Defringing", "Threshold", defringe.threshold);
+ // save dirpyrDenoise
+ if (!pedited || pedited->dirpyrDenoise.enabled) keyFile.set_boolean ("Directional Pyramid Denoising", "Enabled", dirpyrDenoise.enabled);
+ if (!pedited || pedited->dirpyrDenoise.luma) keyFile.set_integer ("Directional Pyramid Denoising", "Luma", dirpyrDenoise.luma);
+ if (!pedited || pedited->dirpyrDenoise.chroma) keyFile.set_integer ("Directional Pyramid Denoising", "Chroma", dirpyrDenoise.chroma);
+ if (!pedited || pedited->dirpyrDenoise.gamma) keyFile.set_double ("Directional Pyramid Denoising", "Gamma", dirpyrDenoise.gamma);
+
+ //Save edgePreservingDecompositionUI.
+ if (!pedited || pedited->edgePreservingDecompositionUI.enabled) keyFile.set_boolean ("EPD", "Enabled", edgePreservingDecompositionUI.enabled);
+ if (!pedited || pedited->edgePreservingDecompositionUI.Strength) keyFile.set_double ("EPD", "Strength", edgePreservingDecompositionUI.Strength);
+ if (!pedited || pedited->edgePreservingDecompositionUI.EdgeStopping) keyFile.set_double ("EPD", "EdgeStopping", edgePreservingDecompositionUI.EdgeStopping);
+ if (!pedited || pedited->edgePreservingDecompositionUI.Scale) keyFile.set_double ("EPD", "Scale", edgePreservingDecompositionUI.Scale);
+ if (!pedited || pedited->edgePreservingDecompositionUI.ReweightingIterates) keyFile.set_integer ("EPD", "ReweightingIterates", edgePreservingDecompositionUI.ReweightingIterates);
+
+/*
// save lumaDenoise
- keyFile.set_boolean ("Luminance Denoising", "Enabled", lumaDenoise.enabled);
- keyFile.set_double ("Luminance Denoising", "Radius", lumaDenoise.radius);
- keyFile.set_integer ("Luminance Denoising", "EdgeTolerance", lumaDenoise.edgetolerance);
+ if (!pedited || pedited->lumaDenoise.enabled) keyFile.set_boolean ("Luminance Denoising", "Enabled", lumaDenoise.enabled);
+ if (!pedited || pedited->lumaDenoise.radius) keyFile.set_double ("Luminance Denoising", "Radius", lumaDenoise.radius);
+ if (!pedited || pedited->lumaDenoise.edgetolerance) keyFile.set_integer ("Luminance Denoising", "EdgeTolerance", lumaDenoise.edgetolerance);
+*/
+/*
// save colorDenoise
- keyFile.set_boolean ("Chrominance Denoising", "Enabled", colorDenoise.enabled);
- keyFile.set_integer ("Chrominance Denoising", "Amount", colorDenoise.amount);
+ //if (!pedited || pedited->colorDenoise.enabled) keyFile.set_boolean ("Chrominance Denoising", "Enabled", colorDenoise.enabled);
+ if (!pedited || pedited->colorDenoise.amount) keyFile.set_integer ("Chrominance Denoising", "Amount", colorDenoise.amount);
+*/
// save sh
- keyFile.set_boolean ("Shadows & Highlights", "Enabled", sh.enabled);
- keyFile.set_boolean ("Shadows & Highlights", "HighQuality", sh.hq);
- keyFile.set_integer ("Shadows & Highlights", "Highlights", sh.highlights);
- keyFile.set_integer ("Shadows & Highlights", "HighlightTonalWidth", sh.htonalwidth);
- keyFile.set_integer ("Shadows & Highlights", "Shadows", sh.shadows);
- keyFile.set_integer ("Shadows & Highlights", "ShadowTonalWidth", sh.stonalwidth);
- keyFile.set_integer ("Shadows & Highlights", "LocalContrast", sh.localcontrast);
- keyFile.set_integer ("Shadows & Highlights", "Radius", sh.radius);
+ if (!pedited || pedited->sh.enabled) keyFile.set_boolean ("Shadows & Highlights", "Enabled", sh.enabled);
+ if (!pedited || pedited->sh.hq) keyFile.set_boolean ("Shadows & Highlights", "HighQuality", sh.hq);
+ if (!pedited || pedited->sh.highlights) keyFile.set_integer ("Shadows & Highlights", "Highlights", sh.highlights);
+ if (!pedited || pedited->sh.htonalwidth) keyFile.set_integer ("Shadows & Highlights", "HighlightTonalWidth", sh.htonalwidth);
+ if (!pedited || pedited->sh.shadows) keyFile.set_integer ("Shadows & Highlights", "Shadows", sh.shadows);
+ if (!pedited || pedited->sh.stonalwidth) keyFile.set_integer ("Shadows & Highlights", "ShadowTonalWidth", sh.stonalwidth);
+ if (!pedited || pedited->sh.localcontrast) keyFile.set_integer ("Shadows & Highlights", "LocalContrast", sh.localcontrast);
+ if (!pedited || pedited->sh.radius) keyFile.set_integer ("Shadows & Highlights", "Radius", sh.radius);
// save crop
- keyFile.set_boolean ("Crop", "Enabled", crop.enabled);
- keyFile.set_integer ("Crop", "X", crop.x);
- keyFile.set_integer ("Crop", "Y", crop.y);
- keyFile.set_integer ("Crop", "W", crop.w);
- keyFile.set_integer ("Crop", "H", crop.h);
- keyFile.set_boolean ("Crop", "FixedRatio", crop.fixratio);
- keyFile.set_string ("Crop", "Ratio", crop.ratio);
- keyFile.set_string ("Crop", "Orientation", crop.orientation);
- keyFile.set_string ("Crop", "Guide", crop.guide);
+ if (!pedited || pedited->crop.enabled) keyFile.set_boolean ("Crop", "Enabled", crop.enabled);
+ if (!pedited || pedited->crop.x) keyFile.set_integer ("Crop", "X", crop.x);
+ if (!pedited || pedited->crop.y) keyFile.set_integer ("Crop", "Y", crop.y);
+ if (!pedited || pedited->crop.w) keyFile.set_integer ("Crop", "W", crop.w);
+ if (!pedited || pedited->crop.h) keyFile.set_integer ("Crop", "H", crop.h);
+ if (!pedited || pedited->crop.fixratio) keyFile.set_boolean ("Crop", "FixedRatio", crop.fixratio);
+ if (!pedited || pedited->crop.ratio) keyFile.set_string ("Crop", "Ratio", crop.ratio);
+ if (!pedited || pedited->crop.orientation) keyFile.set_string ("Crop", "Orientation", crop.orientation);
+ if (!pedited || pedited->crop.guide) keyFile.set_string ("Crop", "Guide", crop.guide);
// save coarse
- keyFile.set_integer ("Coarse Transformation", "Rotate", coarse.rotate);
- keyFile.set_boolean ("Coarse Transformation", "HorizontalFlip", coarse.hflip);
- keyFile.set_boolean ("Coarse Transformation", "VerticalFlip", coarse.vflip);
+ if (!pedited || pedited->coarse.rotate) keyFile.set_integer ("Coarse Transformation", "Rotate", coarse.rotate);
+ if (!pedited || pedited->coarse.hflip) keyFile.set_boolean ("Coarse Transformation", "HorizontalFlip", coarse.hflip);
+ if (!pedited || pedited->coarse.vflip) keyFile.set_boolean ("Coarse Transformation", "VerticalFlip", coarse.vflip);
// save commonTrans
- keyFile.set_boolean ("Common Properties for Transformations", "AutoFill", commonTrans.autofill);
+ if (!pedited || pedited->commonTrans.autofill) keyFile.set_boolean ("Common Properties for Transformations", "AutoFill", commonTrans.autofill);
// save rotate
- keyFile.set_double ("Rotation", "Degree", rotate.degree);
+ if (!pedited || pedited->rotate.degree) keyFile.set_double ("Rotation", "Degree", rotate.degree);
// save distortion
- keyFile.set_double ("Distortion", "Amount", distortion.amount);
- keyFile.set_boolean ("Distortion", "UseLensFun", distortion.uselensfun);
+ if (!pedited || pedited->distortion.amount) keyFile.set_double ("Distortion", "Amount", distortion.amount);
+ if (!pedited || pedited->distortion.uselensfun) keyFile.set_boolean ("Distortion", "UseLensFun", distortion.uselensfun);
// save perspective correction
- keyFile.set_integer ("Perspective", "Horizontal", perspective.horizontal);
- keyFile.set_integer ("Perspective", "Vertical", perspective.vertical);
+ if (!pedited || pedited->perspective.horizontal) keyFile.set_integer ("Perspective", "Horizontal", perspective.horizontal);
+ if (!pedited || pedited->perspective.vertical) keyFile.set_integer ("Perspective", "Vertical", perspective.vertical);
// save C/A correction
- keyFile.set_double ("CACorrection", "Red", cacorrection.red);
- keyFile.set_double ("CACorrection", "Blue", cacorrection.blue);
+ if (!pedited || pedited->cacorrection.red) keyFile.set_double ("CACorrection", "Red", cacorrection.red);
+ if (!pedited || pedited->cacorrection.blue) keyFile.set_double ("CACorrection", "Blue", cacorrection.blue);
// save vignetting correction
- keyFile.set_integer ("Vignetting Correction", "Amount", vignetting.amount);
- keyFile.set_integer ("Vignetting Correction", "Radius", vignetting.radius);
- keyFile.set_integer ("Vignetting Correction", "Strength", vignetting.strength);
- keyFile.set_integer ("Vignetting Correction", "CenterX", vignetting.centerX);
- keyFile.set_integer ("Vignetting Correction", "CenterY", vignetting.centerY);
+ if (!pedited || pedited->vignetting.amount) keyFile.set_integer ("Vignetting Correction", "Amount", vignetting.amount);
+ if (!pedited || pedited->vignetting.radius) keyFile.set_integer ("Vignetting Correction", "Radius", vignetting.radius);
+ if (!pedited || pedited->vignetting.strength) keyFile.set_integer ("Vignetting Correction", "Strength", vignetting.strength);
+ if (!pedited || pedited->vignetting.centerX) keyFile.set_integer ("Vignetting Correction", "CenterX", vignetting.centerX);
+ if (!pedited || pedited->vignetting.centerY) keyFile.set_integer ("Vignetting Correction", "CenterY", vignetting.centerY);
// save highlight recovery settings
- keyFile.set_boolean ("HLRecovery", "Enabled", hlrecovery.enabled);
- keyFile.set_string ("HLRecovery", "Method", hlrecovery.method);
+ if (!pedited || pedited->hlrecovery.enabled) keyFile.set_boolean ("HLRecovery", "Enabled", hlrecovery.enabled);
+ if (!pedited || pedited->hlrecovery.method) keyFile.set_string ("HLRecovery", "Method", hlrecovery.method);
- keyFile.set_boolean ("Resize", "Enabled",resize.enabled);
- keyFile.set_double ("Resize", "Scale", resize.scale);
- keyFile.set_string ("Resize", "AppliesTo", resize.appliesTo);
- keyFile.set_string ("Resize", "Method", resize.method);
- keyFile.set_integer ("Resize", "DataSpecified", resize.dataspec);
- keyFile.set_integer ("Resize", "Width", resize.width);
- keyFile.set_integer ("Resize", "Height", resize.height);
+ if (!pedited || pedited->resize.enabled) keyFile.set_boolean ("Resize", "Enabled",resize.enabled);
+ if (!pedited || pedited->resize.scale) keyFile.set_double ("Resize", "Scale", resize.scale);
+ if (!pedited || pedited->resize.appliesTo) keyFile.set_string ("Resize", "AppliesTo", resize.appliesTo);
+ if (!pedited || pedited->resize.method) keyFile.set_string ("Resize", "Method", resize.method);
+ if (!pedited || pedited->resize.dataspec) keyFile.set_integer ("Resize", "DataSpecified", resize.dataspec);
+ if (!pedited || pedited->resize.width) keyFile.set_integer ("Resize", "Width", resize.width);
+ if (!pedited || pedited->resize.height) keyFile.set_integer ("Resize", "Height", resize.height);
// save color management settings
- keyFile.set_string ("Color Management", "InputProfile", icm.input);
- keyFile.set_boolean ("Color Management", "BlendCMSMatrix", icm.blendCMSMatrix);
- keyFile.set_string ("Color Management", "WorkingProfile", icm.working);
- keyFile.set_string ("Color Management", "OutputProfile", icm.output);
- keyFile.set_string ("Color Management", "Gammafree", icm.gamma);
- keyFile.set_boolean ("Color Management", "Freegamma", icm.freegamma);
- keyFile.set_double ("Color Management", "GammaValue", icm.gampos);
- keyFile.set_double ("Color Management", "GammaSlope", icm.slpos);
+ if (!pedited || pedited->icm.input) keyFile.set_string ("Color Management", "InputProfile", icm.input);
+ if (!pedited || pedited->icm.blendCMSMatrix) keyFile.set_boolean ("Color Management", "BlendCMSMatrix", icm.blendCMSMatrix);
+ if (!pedited || pedited->icm.working) keyFile.set_string ("Color Management", "WorkingProfile", icm.working);
+ if (!pedited || pedited->icm.output) keyFile.set_string ("Color Management", "OutputProfile", icm.output);
+ if (!pedited || pedited->icm.gamma) keyFile.set_string ("Color Management", "Gammafree", icm.gamma);
+ if (!pedited || pedited->icm.freegamma) keyFile.set_boolean ("Color Management", "Freegamma", icm.freegamma);
+ if (!pedited || pedited->icm.gampos) keyFile.set_double ("Color Management", "GammaValue", icm.gampos);
+ if (!pedited || pedited->icm.slpos) keyFile.set_double ("Color Management", "GammaSlope", icm.slpos);
- // save directional pyramid equalizer parameters
- keyFile.set_boolean ("Directional Pyramid Equalizer", "Enabled", dirpyrequalizer.enabled);
+ // save directional pyramid equalizer parameters
+ if (!pedited || pedited->dirpyrequalizer.enabled) keyFile.set_boolean ("Directional Pyramid Equalizer", "Enabled", dirpyrequalizer.enabled);
for(int i = 0; i < 5; i++)
{
std::stringstream ss;
ss << "Mult" << i;
- keyFile.set_double("Directional Pyramid Equalizer", ss.str(), dirpyrequalizer.mult[i]);
+ if (!pedited || pedited->dirpyrequalizer.mult[i]) keyFile.set_double("Directional Pyramid Equalizer", ss.str(), dirpyrequalizer.mult[i]);
}
-
+
// save hsv equalizer parameters
- //keyFile.set_boolean ("HSV Equalizer", "Enabled", hsvequalizer.enabled);
- //keyFile.set_string ("HSV Equalizer", "Channel", hsvequalizer.hsvchannel);
- Glib::ArrayHandle hcurve = hsvequalizer.hcurve;
- Glib::ArrayHandle scurve = hsvequalizer.scurve;
- Glib::ArrayHandle vcurve = hsvequalizer.vcurve;
- keyFile.set_double_list("HSV Equalizer", "HCurve", hcurve);
- keyFile.set_double_list("HSV Equalizer", "SCurve", scurve);
- keyFile.set_double_list("HSV Equalizer", "VCurve", vcurve);
+ if (!pedited || pedited->hsvequalizer.hcurve) {
+ Glib::ArrayHandle hcurve = hsvequalizer.hcurve;
+ keyFile.set_double_list("HSV Equalizer", "HCurve", hcurve);
+ }
+ if (!pedited || pedited->hsvequalizer.scurve) {
+ Glib::ArrayHandle scurve = hsvequalizer.scurve;
+ keyFile.set_double_list("HSV Equalizer", "SCurve", scurve);
+ }
+ if (!pedited || pedited->hsvequalizer.vcurve) {
+ Glib::ArrayHandle vcurve = hsvequalizer.vcurve;
+ keyFile.set_double_list("HSV Equalizer", "VCurve", vcurve);
+ }
- Glib::ArrayHandle RGBrcurve = rgbCurves.rcurve;
- Glib::ArrayHandle RGBgcurve = rgbCurves.gcurve;
- Glib::ArrayHandle RGBbcurve = rgbCurves.bcurve;
- keyFile.set_double_list("RGB Curves", "rCurve", RGBrcurve);
- keyFile.set_double_list("RGB Curves", "gCurve", RGBgcurve);
- keyFile.set_double_list("RGB Curves", "bCurve", RGBbcurve);
+ if (!pedited || pedited->rgbCurves.rcurve) {
+ Glib::ArrayHandle RGBrcurve = rgbCurves.rcurve;
+ keyFile.set_double_list("RGB Curves", "rCurve", RGBrcurve);
+ }
+ if (!pedited || pedited->rgbCurves.gcurve) {
+ Glib::ArrayHandle RGBgcurve = rgbCurves.gcurve;
+ keyFile.set_double_list("RGB Curves", "gCurve", RGBgcurve);
+ }
+ if (!pedited || pedited->rgbCurves.bcurve) {
+ Glib::ArrayHandle RGBbcurve = rgbCurves.bcurve;
+ keyFile.set_double_list("RGB Curves", "bCurve", RGBbcurve);
+ }
- // save RAW parameters
- keyFile.set_string ("RAW", "DarkFrame", raw.dark_frame );
- keyFile.set_boolean ("RAW", "DarkFrameAuto", raw.df_autoselect );
- keyFile.set_string ("RAW", "FlatFieldFile", raw.ff_file );
- keyFile.set_boolean ("RAW", "FlatFieldAutoSelect", raw.ff_AutoSelect );
- keyFile.set_integer ("RAW", "FlatFieldBlurRadius", raw.ff_BlurRadius );
- keyFile.set_string ("RAW", "FlatFieldBlurType", raw.ff_BlurType );
- keyFile.set_boolean ("RAW", "CA", raw.ca_autocorrect );
- keyFile.set_double ("RAW", "CARed", raw.cared );
- keyFile.set_double ("RAW", "CABlue", raw.cablue );
- keyFile.set_boolean ("RAW", "HotDeadPixels", raw.hotdeadpix_filt );
- keyFile.set_integer ("RAW", "HotDeadPixelThresh", raw.hotdeadpix_thresh );
- keyFile.set_integer ("RAW", "LineDenoise", raw.linenoise);
- keyFile.set_integer ("RAW", "GreenEqThreshold", raw.greenthresh);
- keyFile.set_integer ("RAW", "CcSteps", raw.ccSteps);
- keyFile.set_string ("RAW", "Method", raw.dmethod );
- keyFile.set_integer ("RAW", "DCBIterations", raw.dcb_iterations );
- keyFile.set_boolean ("RAW", "DCBEnhance", raw.dcb_enhance );
- keyFile.set_boolean ("RAW", "ALLEnhance", raw.all_enhance );
-
- keyFile.set_double ("RAW", "PreExposure", raw.expos );
- keyFile.set_double ("RAW", "PrePreserv", raw.preser );
- keyFile.set_double ("RAW", "PreBlackzero", raw.blackzero );
- keyFile.set_double ("RAW", "PreBlackone", raw.blackone );
- keyFile.set_double ("RAW", "PreBlacktwo", raw.blacktwo );
- keyFile.set_double ("RAW", "PreBlackthree", raw.blackthree );
- keyFile.set_boolean ("RAW", "PreTwoGreen", raw.twogreen );
+ // save raw parameters
+ if (!pedited || pedited->raw.darkFrame) keyFile.set_string ("RAW", "DarkFrame", raw.dark_frame );
+ if (!pedited || pedited->raw.dfAuto) keyFile.set_boolean ("RAW", "DarkFrameAuto", raw.df_autoselect );
+ if (!pedited || pedited->raw.ff_file) keyFile.set_string ("RAW", "FlatFieldFile", raw.ff_file );
+ if (!pedited || pedited->raw.ff_AutoSelect) keyFile.set_boolean ("RAW", "FlatFieldAutoSelect", raw.ff_AutoSelect );
+ if (!pedited || pedited->raw.ff_BlurRadius) keyFile.set_integer ("RAW", "FlatFieldBlurRadius", raw.ff_BlurRadius );
+ if (!pedited || pedited->raw.ff_BlurType) keyFile.set_string ("RAW", "FlatFieldBlurType", raw.ff_BlurType );
+ if (!pedited || pedited->raw.caCorrection) keyFile.set_boolean ("RAW", "CA", raw.ca_autocorrect );
+ if (!pedited || pedited->raw.caRed) keyFile.set_double ("RAW", "CARed", raw.cared );
+ if (!pedited || pedited->raw.caBlue) keyFile.set_double ("RAW", "CABlue", raw.cablue );
+ if (!pedited || pedited->raw.hotDeadPixelFilter) keyFile.set_boolean ("RAW", "HotDeadPixels", raw.hotdeadpix_filt );
+ if (!pedited || pedited->raw.hotDeadPixelThresh) keyFile.set_integer ("RAW", "HotDeadPixelThresh", raw.hotdeadpix_thresh );
+ if (!pedited || pedited->raw.linenoise) keyFile.set_integer ("RAW", "LineDenoise", raw.linenoise);
+ if (!pedited || pedited->raw.greenEq) keyFile.set_integer ("RAW", "GreenEqThreshold", raw.greenthresh);
+ if (!pedited || pedited->raw.ccSteps) keyFile.set_integer ("RAW", "CcSteps", raw.ccSteps);
+ if (!pedited || pedited->raw.dmethod) keyFile.set_string ("RAW", "Method", raw.dmethod );
+ if (!pedited || pedited->raw.dcbIterations) keyFile.set_integer ("RAW", "DCBIterations", raw.dcb_iterations );
+ if (!pedited || pedited->raw.dcbEnhance) keyFile.set_boolean ("RAW", "DCBEnhance", raw.dcb_enhance );
+ if (!pedited || pedited->raw.allEnhance) keyFile.set_boolean ("RAW", "ALLEnhance", raw.all_enhance );
- // exposition
+ // save raw exposition
+ if (!pedited || pedited->raw.exPos) keyFile.set_double ("RAW", "PreExposure", raw.expos );
+ if (!pedited || pedited->raw.exPreser) keyFile.set_double ("RAW", "PrePreserv", raw.preser );
+ if (!pedited || pedited->raw.exBlackzero) keyFile.set_double ("RAW", "PreBlackzero", raw.blackzero );
+ if (!pedited || pedited->raw.exBlackone) keyFile.set_double ("RAW", "PreBlackone", raw.blackone );
+ if (!pedited || pedited->raw.exBlacktwo) keyFile.set_double ("RAW", "PreBlacktwo", raw.blacktwo );
+ if (!pedited || pedited->raw.exBlackthree) keyFile.set_double ("RAW", "PreBlackthree", raw.blackthree );
+ if (!pedited || pedited->raw.exTwoGreen) keyFile.set_boolean ("RAW", "PreTwoGreen", raw.twogreen );
// save exif change list
- for (int i=0; i<(int)exif.size(); i++)
- keyFile.set_string ("Exif", exif[i].field, exif[i].value);
+ if (!pedited || pedited->exif) {
+ for (ExifPairs::const_iterator i=exif.begin(); i!=exif.end(); i++)
+ keyFile.set_string ("Exif", i->first, i->second);
+ }
// save iptc change list
- for (int i=0; i<(int)iptc.size(); i++) {
- Glib::ArrayHandle values = iptc[i].values;
- keyFile.set_string_list ("IPTC", iptc[i].field, values);
+ 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);
+ }
}
Glib::ustring sPParams = keyFile.to_data();
@@ -637,7 +664,7 @@ int ProcParams::write (Glib::ustring &fname, Glib::ustring &content) const {
int error = 0;
if (fname.length()) {
- FILE *f;
+ FILE *f;
f = safe_g_fopen (fname, "wt");
if (f==NULL)
@@ -650,11 +677,13 @@ int ProcParams::write (Glib::ustring &fname, Glib::ustring &content) const {
return error;
}
-int ProcParams::load (Glib::ustring fname) {
+int ProcParams::load (Glib::ustring fname, ParamsEdited* pedited) {
SafeKeyFile keyFile;
try {
- setDefaults ();
+ //setDefaults ();
+ if (pedited)
+ pedited->set(false);
FILE* f = safe_g_fopen (fname, "rt");
if (!f)
@@ -679,34 +708,39 @@ if (keyFile.has_group ("Version")) {
//printf("ProcParams::load called ppVersion=%i\n",ppVersion);
if (keyFile.has_group ("General")) {
- if (keyFile.has_key ("General", "Rank")) rank = keyFile.get_integer ("General", "Rank");
- if (keyFile.has_key ("General", "ColorLabel")) colorlabel = keyFile.get_integer ("General", "ColorLabel");
- if (keyFile.has_key ("General", "InTrash")) inTrash = keyFile.get_boolean ("General", "InTrash");
+ if (keyFile.has_key ("General", "Rank")) { rank = keyFile.get_integer ("General", "Rank"); if (pedited) pedited->general.rank = true; }
+ if (keyFile.has_key ("General", "ColorLabel")) { colorlabel = keyFile.get_integer ("General", "ColorLabel"); if (pedited) pedited->general.colorlabel = true; }
+ if (keyFile.has_key ("General", "InTrash")) { inTrash = keyFile.get_boolean ("General", "InTrash"); if (pedited) pedited->general.intrash = true; }
}
if (keyFile.has_group ("Exposure")) {
- if (ppVersiontoneCurve.autoexp = true; }
- if (keyFile.has_key ("Exposure", "Clip")) toneCurve.clip = keyFile.get_double ("Exposure", "Clip");
- if (keyFile.has_key ("Exposure", "Compensation")) toneCurve.expcomp = keyFile.get_double ("Exposure", "Compensation");
- if (keyFile.has_key ("Exposure", "Brightness")) toneCurve.brightness = keyFile.get_integer ("Exposure", "Brightness");
- if (keyFile.has_key ("Exposure", "Contrast")) toneCurve.contrast = keyFile.get_integer ("Exposure", "Contrast");
- if (keyFile.has_key ("Exposure", "Saturation")) toneCurve.saturation = keyFile.get_integer ("Exposure", "Saturation");
- if (keyFile.has_key ("Exposure", "Black")) toneCurve.black = keyFile.get_integer ("Exposure", "Black");
- if (keyFile.has_key ("Exposure", "HighlightCompr")) toneCurve.hlcompr = keyFile.get_integer ("Exposure", "HighlightCompr");
- if (keyFile.has_key ("Exposure", "HighlightComprThreshold")) toneCurve.hlcomprthresh = keyFile.get_integer ("Exposure", "HighlightComprThreshold");
- if (keyFile.has_key ("Exposure", "ShadowCompr")) toneCurve.shcompr = keyFile.get_integer ("Exposure", "ShadowCompr");
+ if (keyFile.has_key ("Exposure", "Clip")) { toneCurve.clip = keyFile.get_double ("Exposure", "Clip"); if (pedited) pedited->toneCurve.clip = true; }
+ if (keyFile.has_key ("Exposure", "Compensation")) { toneCurve.expcomp = keyFile.get_double ("Exposure", "Compensation"); if (pedited) pedited->toneCurve.expcomp = true; }
+ if (keyFile.has_key ("Exposure", "Brightness")) { toneCurve.brightness = keyFile.get_integer ("Exposure", "Brightness"); if (pedited) pedited->toneCurve.brightness = true; }
+ if (keyFile.has_key ("Exposure", "Contrast")) { toneCurve.contrast = keyFile.get_integer ("Exposure", "Contrast"); if (pedited) pedited->toneCurve.contrast = true; }
+ if (keyFile.has_key ("Exposure", "Saturation")) { toneCurve.saturation = keyFile.get_integer ("Exposure", "Saturation"); if (pedited) pedited->toneCurve.saturation = true; }
+ if (keyFile.has_key ("Exposure", "Black")) { toneCurve.black = keyFile.get_integer ("Exposure", "Black"); if (pedited) pedited->toneCurve.black = true; }
+ if (keyFile.has_key ("Exposure", "HighlightCompr")) { toneCurve.hlcompr = keyFile.get_integer ("Exposure", "HighlightCompr"); if (pedited) pedited->toneCurve.hlcompr = true; }
+ if (keyFile.has_key ("Exposure", "HighlightComprThreshold")) { toneCurve.hlcomprthresh = keyFile.get_integer ("Exposure", "HighlightComprThreshold"); if (pedited) pedited->toneCurve.hlcomprthresh = true; }
+ if (keyFile.has_key ("Exposure", "ShadowCompr")) { toneCurve.shcompr = keyFile.get_integer ("Exposure", "ShadowCompr"); if (pedited) pedited->toneCurve.shcompr = true; }
if (toneCurve.shcompr > 100) toneCurve.shcompr = 100; // older pp3 files can have values above 100.
if (ppVersion>200)
- if (keyFile.has_key ("Exposure", "Curve")) toneCurve.curve = keyFile.get_double_list ("Exposure", "Curve");
+ if (keyFile.has_key ("Exposure", "Curve")) { toneCurve.curve = keyFile.get_double_list ("Exposure", "Curve"); if (pedited) pedited->toneCurve.curve = true; }
}
// load channel mixer curve
if (keyFile.has_group ("Channel Mixer")) {
if (keyFile.has_key ("Channel Mixer", "Red") && keyFile.has_key ("Channel Mixer", "Green") && keyFile.has_key ("Channel Mixer", "Blue")) {
+ if (pedited) {
+ pedited->chmixer.red[0] = pedited->chmixer.red[1] = pedited->chmixer.red[2] = true;
+ pedited->chmixer.green[0] = pedited->chmixer.green[1] = pedited->chmixer.green[2] = true;
+ pedited->chmixer.blue[0] = pedited->chmixer.blue[1] = pedited->chmixer.blue[2] = true;
+ }
Glib::ArrayHandle rmix = keyFile.get_integer_list ("Channel Mixer", "Red");
Glib::ArrayHandle gmix = keyFile.get_integer_list ("Channel Mixer", "Green");
Glib::ArrayHandle bmix = keyFile.get_integer_list ("Channel Mixer", "Blue");
@@ -718,313 +752,339 @@ if (keyFile.has_group ("Channel Mixer")) {
// load luma curve
if (keyFile.has_group ("Luminance Curve")) {
- if (keyFile.has_key ("Luminance Curve", "Brightness")) labCurve.brightness = keyFile.get_integer ("Luminance Curve", "Brightness");
- if (keyFile.has_key ("Luminance Curve", "Contrast")) labCurve.contrast = keyFile.get_integer ("Luminance Curve", "Contrast");
- if (keyFile.has_key ("Luminance Curve", "Saturation")) labCurve.saturation = keyFile.get_integer ("Luminance Curve", "Saturation");
- if (keyFile.has_key ("Luminance Curve", "AvoidColorClipping")) labCurve.avoidclip = keyFile.get_boolean ("Luminance Curve", "AvoidColorClipping");
- if (keyFile.has_key ("Luminance Curve", "SaturationLimiter")) labCurve.enable_saturationlimiter= keyFile.get_boolean ("Luminance Curve", "SaturationLimiter");
- if (keyFile.has_key ("Luminance Curve", "SaturationLimit")) labCurve.saturationlimit = keyFile.get_double ("Luminance Curve", "SaturationLimit");
- if (keyFile.has_key ("Luminance Curve", "LCurve")) labCurve.lcurve = keyFile.get_double_list ("Luminance Curve", "LCurve");
- if (keyFile.has_key ("Luminance Curve", "aCurve")) labCurve.acurve = keyFile.get_double_list ("Luminance Curve", "aCurve");
- if (keyFile.has_key ("Luminance Curve", "bCurve")) labCurve.bcurve = keyFile.get_double_list ("Luminance Curve", "bCurve");
+ if (keyFile.has_key ("Luminance Curve", "Brightness")) { labCurve.brightness = keyFile.get_integer ("Luminance Curve", "Brightness"); if (pedited) pedited->labCurve.brightness = true; }
+ if (keyFile.has_key ("Luminance Curve", "Contrast")) { labCurve.contrast = keyFile.get_integer ("Luminance Curve", "Contrast"); if (pedited) pedited->labCurve.contrast = true; }
+ if (keyFile.has_key ("Luminance Curve", "Saturation")) { labCurve.saturation = keyFile.get_integer ("Luminance Curve", "Saturation"); if (pedited) pedited->labCurve.saturation = true; }
+ if (keyFile.has_key ("Luminance Curve", "AvoidColorClipping")) { labCurve.avoidclip = keyFile.get_boolean ("Luminance Curve", "AvoidColorClipping"); if (pedited) pedited->labCurve.avoidclip = true; }
+ if (keyFile.has_key ("Luminance Curve", "SaturationLimiter")) { labCurve.enable_saturationlimiter = keyFile.get_boolean ("Luminance Curve", "SaturationLimiter"); if (pedited) pedited->labCurve.enable_saturationlimiter = true; }
+ if (keyFile.has_key ("Luminance Curve", "SaturationLimit")) { labCurve.saturationlimit = keyFile.get_double ("Luminance Curve", "SaturationLimit"); if (pedited) pedited->labCurve.saturationlimit = true; }
+ if (keyFile.has_key ("Luminance Curve", "LCurve")) { labCurve.lcurve = keyFile.get_double_list ("Luminance Curve", "LCurve"); if (pedited) pedited->labCurve.lcurve = true; }
+ if (keyFile.has_key ("Luminance Curve", "aCurve")) { labCurve.acurve = keyFile.get_double_list ("Luminance Curve", "aCurve"); if (pedited) pedited->labCurve.acurve = true; }
+ if (keyFile.has_key ("Luminance Curve", "bCurve")) { labCurve.bcurve = keyFile.get_double_list ("Luminance Curve", "bCurve"); if (pedited) pedited->labCurve.bcurve = true; }
}
// load sharpening
-if (keyFile.has_group ("Sharpening")) {
- if (keyFile.has_key ("Sharpening", "Enabled")) sharpening.enabled = keyFile.get_boolean ("Sharpening", "Enabled");
- if (keyFile.has_key ("Sharpening", "Radius")) sharpening.radius = keyFile.get_double ("Sharpening", "Radius");
- if (keyFile.has_key ("Sharpening", "Amount")) sharpening.amount = keyFile.get_integer ("Sharpening", "Amount");
- if (keyFile.has_key ("Sharpening", "Threshold")) sharpening.threshold = keyFile.get_integer ("Sharpening", "Threshold");
- if (keyFile.has_key ("Sharpening", "OnlyEdges")) sharpening.edgesonly = keyFile.get_boolean ("Sharpening", "OnlyEdges");
- if (keyFile.has_key ("Sharpening", "EdgedetectionRadius")) sharpening.edges_radius = keyFile.get_double ("Sharpening", "EdgedetectionRadius");
- if (keyFile.has_key ("Sharpening", "EdgeTolerance")) sharpening.edges_tolerance = keyFile.get_integer ("Sharpening", "EdgeTolerance");
- if (keyFile.has_key ("Sharpening", "HalocontrolEnabled")) sharpening.halocontrol = keyFile.get_boolean ("Sharpening", "HalocontrolEnabled");
- if (keyFile.has_key ("Sharpening", "HalocontrolAmount")) sharpening.halocontrol_amount = keyFile.get_integer ("Sharpening", "HalocontrolAmount");
- if (keyFile.has_key ("Sharpening", "Method")) sharpening.method = keyFile.get_string ("Sharpening", "Method");
- if (keyFile.has_key ("Sharpening", "DeconvRadius")) sharpening.deconvradius = keyFile.get_double ("Sharpening", "DeconvRadius");
- if (keyFile.has_key ("Sharpening", "DeconvAmount")) sharpening.deconvamount = keyFile.get_integer ("Sharpening", "DeconvAmount");
- if (keyFile.has_key ("Sharpening", "DeconvDamping")) sharpening.deconvdamping = keyFile.get_integer ("Sharpening", "DeconvDamping");
- if (keyFile.has_key ("Sharpening", "DeconvIterations")) sharpening.deconviter = keyFile.get_integer ("Sharpening", "DeconvIterations");
+if (keyFile.has_group ("Sharpening")) {
+ if (keyFile.has_key ("Sharpening", "Enabled")) { sharpening.enabled = keyFile.get_boolean ("Sharpening", "Enabled"); if (pedited) pedited->sharpening.enabled = true; }
+ if (keyFile.has_key ("Sharpening", "Radius")) { sharpening.radius = keyFile.get_double ("Sharpening", "Radius"); if (pedited) pedited->sharpening.radius = true; }
+ if (keyFile.has_key ("Sharpening", "Amount")) { sharpening.amount = keyFile.get_integer ("Sharpening", "Amount"); if (pedited) pedited->sharpening.amount = true; }
+ if (keyFile.has_key ("Sharpening", "Threshold")) { sharpening.threshold = keyFile.get_integer ("Sharpening", "Threshold"); if (pedited) pedited->sharpening.threshold = true; }
+ if (keyFile.has_key ("Sharpening", "OnlyEdges")) { sharpening.edgesonly = keyFile.get_boolean ("Sharpening", "OnlyEdges"); if (pedited) pedited->sharpening.edgesonly = true; }
+ if (keyFile.has_key ("Sharpening", "EdgedetectionRadius")) { sharpening.edges_radius = keyFile.get_double ("Sharpening", "EdgedetectionRadius"); if (pedited) pedited->sharpening.edges_radius = true; }
+ if (keyFile.has_key ("Sharpening", "EdgeTolerance")) { sharpening.edges_tolerance = keyFile.get_integer ("Sharpening", "EdgeTolerance"); if (pedited) pedited->sharpening.edges_tolerance = true; }
+ if (keyFile.has_key ("Sharpening", "HalocontrolEnabled")) { sharpening.halocontrol = keyFile.get_boolean ("Sharpening", "HalocontrolEnabled"); if (pedited) pedited->sharpening.halocontrol = true; }
+ if (keyFile.has_key ("Sharpening", "HalocontrolAmount")) { sharpening.halocontrol_amount = keyFile.get_integer ("Sharpening", "HalocontrolAmount"); if (pedited) pedited->sharpening.halocontrol_amount = true; }
+ if (keyFile.has_key ("Sharpening", "Method")) { sharpening.method = keyFile.get_string ("Sharpening", "Method"); if (pedited) pedited->sharpening.method = true; }
+ if (keyFile.has_key ("Sharpening", "DeconvRadius")) { sharpening.deconvradius = keyFile.get_double ("Sharpening", "DeconvRadius"); if (pedited) pedited->sharpening.deconvradius = true; }
+ if (keyFile.has_key ("Sharpening", "DeconvAmount")) { sharpening.deconvamount = keyFile.get_integer ("Sharpening", "DeconvAmount"); if (pedited) pedited->sharpening.deconvamount = true; }
+ if (keyFile.has_key ("Sharpening", "DeconvDamping")) { sharpening.deconvdamping = keyFile.get_integer ("Sharpening", "DeconvDamping"); if (pedited) pedited->sharpening.deconvdamping = true; }
+ if (keyFile.has_key ("Sharpening", "DeconvIterations")) { sharpening.deconviter = keyFile.get_integer ("Sharpening", "DeconvIterations"); if (pedited) pedited->sharpening.deconviter = true; }
}
// load edge sharpening
if (keyFile.has_group ("SharpenEdge")) {
- if (keyFile.has_key ("SharpenEdge", "Enabled")) sharpenEdge.enabled = keyFile.get_boolean ("SharpenEdge", "Enabled");
- if (keyFile.has_key ("SharpenEdge", "Passes")) sharpenEdge.passes = keyFile.get_integer ("SharpenEdge", "Passes");
- if (keyFile.has_key ("SharpenEdge", "Strength")) sharpenEdge.amount = keyFile.get_double ("SharpenEdge", "Strength");
- if (keyFile.has_key ("SharpenEdge", "ThreeChannels")) sharpenEdge.threechannels = keyFile.get_boolean ("SharpenEdge", "ThreeChannels");
+ if (keyFile.has_key ("SharpenEdge", "Enabled")) { sharpenEdge.enabled = keyFile.get_boolean ("SharpenEdge", "Enabled"); if (pedited) pedited->sharpenEdge.enabled = true; }
+ if (keyFile.has_key ("SharpenEdge", "Passes")) { sharpenEdge.passes = keyFile.get_integer ("SharpenEdge", "Passes"); if (pedited) pedited->sharpenEdge.passes = true; }
+ if (keyFile.has_key ("SharpenEdge", "Strength")) { sharpenEdge.amount = keyFile.get_double ("SharpenEdge", "Strength"); if (pedited) pedited->sharpenEdge.amount = true; }
+ if (keyFile.has_key ("SharpenEdge", "ThreeChannels")) { sharpenEdge.threechannels = keyFile.get_boolean ("SharpenEdge", "ThreeChannels"); if (pedited) pedited->sharpenEdge.threechannels = true; }
}
// load micro-contrast sharpening
if (keyFile.has_group ("SharpenMicro")) {
- if (keyFile.has_key ("SharpenMicro", "Enabled")) sharpenMicro.enabled = keyFile.get_boolean ("SharpenMicro", "Enabled");
- if (keyFile.has_key ("SharpenMicro", "Matrix")) sharpenMicro.matrix = keyFile.get_boolean ("SharpenMicro", "Matrix");
- if (keyFile.has_key ("SharpenMicro", "Strength")) sharpenMicro.amount = keyFile.get_double ("SharpenMicro", "Strength");
- if (keyFile.has_key ("SharpenMicro", "Uniformity")) sharpenMicro.uniformity = keyFile.get_double ("SharpenMicro", "Uniformity");
+ if (keyFile.has_key ("SharpenMicro", "Enabled")) { sharpenMicro.enabled = keyFile.get_boolean ("SharpenMicro", "Enabled"); if (pedited) pedited->sharpenMicro.enabled = true; }
+ if (keyFile.has_key ("SharpenMicro", "Matrix")) { sharpenMicro.matrix = keyFile.get_boolean ("SharpenMicro", "Matrix"); if (pedited) pedited->sharpenMicro.matrix = true; }
+ if (keyFile.has_key ("SharpenMicro", "Strength")) { sharpenMicro.amount = keyFile.get_double ("SharpenMicro", "Strength"); if (pedited) pedited->sharpenMicro.amount = true; }
+ if (keyFile.has_key ("SharpenMicro", "Uniformity")) { sharpenMicro.uniformity = keyFile.get_double ("SharpenMicro", "Uniformity"); if (pedited) pedited->sharpenMicro.uniformity = true; }
}
// load vibrance
if (keyFile.has_group ("Vibrance")) {
- if (keyFile.has_key ("Vibrance", "Enabled")) vibrance.enabled = keyFile.get_boolean ("Vibrance", "Enabled");
- if (keyFile.has_key ("Vibrance", "Pastels")) vibrance.pastels = keyFile.get_integer ("Vibrance", "Pastels");
- if (keyFile.has_key ("Vibrance", "Saturated")) vibrance.saturated = keyFile.get_integer ("Vibrance", "Saturated");
- if (keyFile.has_key ("Vibrance", "PSThreshold")) vibrance.psthreshold = keyFile.get_integer ("Vibrance", "PSThreshold");
- if (keyFile.has_key ("Vibrance", "ProtectSkins")) vibrance.protectskins = keyFile.get_boolean ("Vibrance", "ProtectSkins");
- if (keyFile.has_key ("Vibrance", "AvoidColorShift")) vibrance.avoidcolorshift = keyFile.get_boolean ("Vibrance", "AvoidColorShift");
- if (keyFile.has_key ("Vibrance", "PastSatTog")) vibrance.pastsattog = keyFile.get_boolean ("Vibrance", "PastSatTog");
+ if (keyFile.has_key ("Vibrance", "Enabled")) { vibrance.enabled = keyFile.get_boolean ("Vibrance", "Enabled"); if (pedited) pedited->vibrance.enabled = true; }
+ if (keyFile.has_key ("Vibrance", "Pastels")) { vibrance.pastels = keyFile.get_integer ("Vibrance", "Pastels"); if (pedited) pedited->vibrance.pastels = true; }
+ if (keyFile.has_key ("Vibrance", "Saturated")) { vibrance.saturated = keyFile.get_integer ("Vibrance", "Saturated"); if (pedited) pedited->vibrance.saturated = true; }
+ if (keyFile.has_key ("Vibrance", "PSThreshold")) { vibrance.psthreshold = keyFile.get_integer ("Vibrance", "PSThreshold"); if (pedited) pedited->vibrance.psthreshold = true; }
+ if (keyFile.has_key ("Vibrance", "ProtectSkins")) { vibrance.protectskins = keyFile.get_boolean ("Vibrance", "ProtectSkins"); if (pedited) pedited->vibrance.protectskins = true; }
+ if (keyFile.has_key ("Vibrance", "AvoidColorShift")) { vibrance.avoidcolorshift = keyFile.get_boolean ("Vibrance", "AvoidColorShift"); if (pedited) pedited->vibrance.avoidcolorshift = true; }
+ if (keyFile.has_key ("Vibrance", "PastSatTog")) { vibrance.pastsattog = keyFile.get_boolean ("Vibrance", "PastSatTog"); if (pedited) pedited->vibrance.pastsattog = true; }
}
// load colorBoost
-if (keyFile.has_group ("Color Boost")) {
- if (keyFile.has_key ("Color Boost", "Amount")) colorBoost.amount = keyFile.get_integer ("Color Boost", "Amount");
+/*if (keyFile.has_group ("Color Boost")) {
+ if (keyFile.has_key ("Color Boost", "Amount")) { colorBoost.amount = keyFile.get_integer ("Color Boost", "Amount"); if (pedited) pedited->colorBoost.amount = true; }
else {
int a=0, b=0;
- if (keyFile.has_key ("Color Boost", "ChannelA")) a = keyFile.get_integer ("Color Boost", "ChannelA");
- if (keyFile.has_key ("Color Boost", "ChannelB")) b = keyFile.get_integer ("Color Boost", "ChannelB");
+ if (keyFile.has_key ("Color Boost", "ChannelA")) { a = keyFile.get_integer ("Color Boost", "ChannelA"); }
+ if (keyFile.has_key ("Color Boost", "ChannelB")) { b = keyFile.get_integer ("Color Boost", "ChannelB"); }
colorBoost.amount = (a+b) / 2;
+ if (pedited) pedited->colorBoost.amount = true;
}
- if (keyFile.has_key ("Color Boost", "AvoidColorClipping")) colorBoost.avoidclip = keyFile.get_boolean ("Color Boost", "AvoidColorClipping");
- if (keyFile.has_key ("Color Boost", "SaturationLimiter")) colorBoost.enable_saturationlimiter= keyFile.get_boolean ("Color Boost", "SaturationLimiter");
- if (keyFile.has_key ("Color Boost", "SaturationLimit")) colorBoost.saturationlimit = keyFile.get_double ("Color Boost", "SaturationLimit");
-}
+ if (keyFile.has_key ("Color Boost", "AvoidColorClipping")) { colorBoost.avoidclip = keyFile.get_boolean ("Color Boost", "AvoidColorClipping"); if (pedited) pedited->colorBoost.avoidclip = true; }
+ if (keyFile.has_key ("Color Boost", "SaturationLimiter")) { colorBoost.enable_saturationlimiter= keyFile.get_boolean ("Color Boost", "SaturationLimiter"); if (pedited) pedited->colorBoost.enable_saturationlimiter = true; }
+ if (keyFile.has_key ("Color Boost", "SaturationLimit")) { colorBoost.saturationlimit = keyFile.get_double ("Color Boost", "SaturationLimit"); if (pedited) pedited->colorBoost.saturationlimit = true; }
+}*/
// load wb
-if (keyFile.has_group ("White Balance")) {
- if (keyFile.has_key ("White Balance", "Setting")) wb.method = keyFile.get_string ("White Balance", "Setting");
- if (keyFile.has_key ("White Balance", "Temperature")) wb.temperature = keyFile.get_integer ("White Balance", "Temperature");
- if (keyFile.has_key ("White Balance", "Green")) wb.green = keyFile.get_double ("White Balance", "Green");
+if (keyFile.has_group ("White Balance")) {
+ if (keyFile.has_key ("White Balance", "Setting")) { wb.method = keyFile.get_string ("White Balance", "Setting"); if (pedited) pedited->wb.method = true; }
+ if (keyFile.has_key ("White Balance", "Temperature")) { wb.temperature = keyFile.get_integer ("White Balance", "Temperature"); if (pedited) pedited->wb.temperature = true; }
+ if (keyFile.has_key ("White Balance", "Green")) { wb.green = keyFile.get_double ("White Balance", "Green"); if (pedited) pedited->wb.green = true; }
}
// load colorShift
-if (keyFile.has_group ("Color Shift")) {
- if (keyFile.has_key ("Color Shift", "ChannelA")) colorShift.a = keyFile.get_double ("Color Shift", "ChannelA");
- if (keyFile.has_key ("Color Shift", "ChannelB")) colorShift.b = keyFile.get_double ("Color Shift", "ChannelB");
-}
+/*if (keyFile.has_group ("Color Shift")) {
+ if (keyFile.has_key ("Color Shift", "ChannelA")) { colorShift.a = keyFile.get_double ("Color Shift", "ChannelA"); if (pedited) pedited->colorShift.a = true; }
+ if (keyFile.has_key ("Color Shift", "ChannelB")) { colorShift.b = keyFile.get_double ("Color Shift", "ChannelB"); if (pedited) pedited->colorShift.b = true; }
+}*/
// load defringe
-if (keyFile.has_group ("Defringing")) {
- if (keyFile.has_key ("Defringing", "Enabled")) defringe.enabled = keyFile.get_boolean ("Defringing", "Enabled");
- if (keyFile.has_key ("Defringing", "Radius")) defringe.radius = keyFile.get_double ("Defringing", "Radius");
- if (keyFile.has_key ("Defringing", "Threshold")) defringe.threshold = keyFile.get_integer ("Defringing", "Threshold");
+if (keyFile.has_group ("Defringing")) {
+ if (keyFile.has_key ("Defringing", "Enabled")) { defringe.enabled = keyFile.get_boolean ("Defringing", "Enabled"); if (pedited) pedited->defringe.enabled = true; }
+ if (keyFile.has_key ("Defringing", "Radius")) { defringe.radius = keyFile.get_double ("Defringing", "Radius"); if (pedited) pedited->defringe.radius = true; }
+ if (keyFile.has_key ("Defringing", "Threshold")) { defringe.threshold = keyFile.get_integer ("Defringing", "Threshold"); if (pedited) pedited->defringe.threshold = true; }
}
// load impulseDenoise
-if (keyFile.has_group ("Impulse Denoising")) {
- if (keyFile.has_key ("Impulse Denoising", "Enabled")) impulseDenoise.enabled = keyFile.get_boolean ("Impulse Denoising", "Enabled");
- if (keyFile.has_key ("Impulse Denoising", "Threshold")) impulseDenoise.thresh = keyFile.get_integer ("Impulse Denoising", "Threshold");
+if (keyFile.has_group ("Impulse Denoising")) {
+ if (keyFile.has_key ("Impulse Denoising", "Enabled")) { impulseDenoise.enabled = keyFile.get_boolean ("Impulse Denoising", "Enabled"); if (pedited) pedited->impulseDenoise.enabled = true; }
+ if (keyFile.has_key ("Impulse Denoising", "Threshold")) { impulseDenoise.thresh = keyFile.get_integer ("Impulse Denoising", "Threshold"); if (pedited) pedited->impulseDenoise.thresh = true; }
}
// load dirpyrDenoise
-if (keyFile.has_group ("Directional Pyramid Denoising")) {
- if (keyFile.has_key ("Directional Pyramid Denoising", "Enabled")) dirpyrDenoise.enabled = keyFile.get_boolean ("Directional Pyramid Denoising", "Enabled");
- if (keyFile.has_key ("Directional Pyramid Denoising", "Luma")) dirpyrDenoise.luma = keyFile.get_integer ("Directional Pyramid Denoising", "Luma");
- if (keyFile.has_key ("Directional Pyramid Denoising", "Chroma")) dirpyrDenoise.chroma = keyFile.get_integer ("Directional Pyramid Denoising", "Chroma");
- if (keyFile.has_key ("Directional Pyramid Denoising", "Gamma")) dirpyrDenoise.gamma = keyFile.get_double ("Directional Pyramid Denoising", "Gamma");
- if (keyFile.has_key ("Directional Pyramid Denoising", "LumCurve")) dirpyrDenoise.lumcurve = keyFile.get_double_list ("Directional Pyramid Denoising", "LumCurve");
- if (keyFile.has_key ("Directional Pyramid Denoising", "ChromCurve")) dirpyrDenoise.chromcurve = keyFile.get_double_list ("Directional Pyramid Denoising", "ChromCurve");
+if (keyFile.has_group ("Directional Pyramid Denoising")) {
+ if (keyFile.has_key ("Directional Pyramid Denoising", "Enabled")) { dirpyrDenoise.enabled = keyFile.get_boolean ("Directional Pyramid Denoising", "Enabled"); if (pedited) pedited->dirpyrDenoise.enabled = true; }
+ if (keyFile.has_key ("Directional Pyramid Denoising", "Luma")) { dirpyrDenoise.luma = keyFile.get_integer ("Directional Pyramid Denoising", "Luma"); if (pedited) pedited->dirpyrDenoise.luma = true; }
+ if (keyFile.has_key ("Directional Pyramid Denoising", "Chroma")) { dirpyrDenoise.chroma = keyFile.get_integer ("Directional Pyramid Denoising", "Chroma"); if (pedited) pedited->dirpyrDenoise.chroma = true; }
+ if (keyFile.has_key ("Directional Pyramid Denoising", "Gamma")) { dirpyrDenoise.gamma = keyFile.get_double ("Directional Pyramid Denoising", "Gamma"); if (pedited) pedited->dirpyrDenoise.gamma = true; }
}
//Load EPD.
-if (keyFile.has_group ("EPD")) {
- if(keyFile.has_key("EPD", "Enabled")) edgePreservingDecompositionUI.enabled = keyFile.get_boolean ("EPD", "Enabled");
- if(keyFile.has_key("EPD", "Strength")) edgePreservingDecompositionUI.Strength = keyFile.get_double ("EPD", "Strength");
- if(keyFile.has_key("EPD", "EdgeStopping")) edgePreservingDecompositionUI.EdgeStopping = keyFile.get_double ("EPD", "EdgeStopping");
- if(keyFile.has_key("EPD", "Scale")) edgePreservingDecompositionUI.Scale = keyFile.get_double ("EPD", "Scale");
- if(keyFile.has_key("EPD", "ReweightingIterates")) edgePreservingDecompositionUI.ReweightingIterates = keyFile.get_integer ("EPD", "ReweightingIterates");
+if (keyFile.has_group ("EPD")) {
+ if(keyFile.has_key("EPD", "Enabled")) { edgePreservingDecompositionUI.enabled = keyFile.get_boolean ("EPD", "Enabled"); if (pedited) pedited->edgePreservingDecompositionUI.enabled = true; }
+ if(keyFile.has_key("EPD", "Strength")) { edgePreservingDecompositionUI.Strength = keyFile.get_double ("EPD", "Strength"); if (pedited) pedited->edgePreservingDecompositionUI.Strength = true; }
+ if(keyFile.has_key("EPD", "EdgeStopping")) { edgePreservingDecompositionUI.EdgeStopping = keyFile.get_double ("EPD", "EdgeStopping"); if (pedited) pedited->edgePreservingDecompositionUI.EdgeStopping = true; }
+ if(keyFile.has_key("EPD", "Scale")) { edgePreservingDecompositionUI.Scale = keyFile.get_double ("EPD", "Scale"); if (pedited) pedited->edgePreservingDecompositionUI.Scale = true; }
+ if(keyFile.has_key("EPD", "ReweightingIterates")) { edgePreservingDecompositionUI.ReweightingIterates = keyFile.get_integer ("EPD", "ReweightingIterates"); if (pedited) pedited->edgePreservingDecompositionUI.ReweightingIterates = true; }
}
// load lumaDenoise
-if (keyFile.has_group ("Luminance Denoising")) {
- if (keyFile.has_key ("Luminance Denoising", "Enabled")) lumaDenoise.enabled = keyFile.get_boolean ("Luminance Denoising", "Enabled");
- if (keyFile.has_key ("Luminance Denoising", "Radius")) lumaDenoise.radius = keyFile.get_double ("Luminance Denoising", "Radius");
- if (keyFile.has_key ("Luminance Denoising", "EdgeTolerance")) lumaDenoise.edgetolerance = keyFile.get_integer ("Luminance Denoising", "EdgeTolerance");
-}
+/*if (keyFile.has_group ("Luminance Denoising")) {
+ if (keyFile.has_key ("Luminance Denoising", "Enabled")) { lumaDenoise.enabled = keyFile.get_boolean ("Luminance Denoising", "Enabled"); if (pedited) pedited->lumaDenoise.enabled = true; }
+ if (keyFile.has_key ("Luminance Denoising", "Radius")) { lumaDenoise.radius = keyFile.get_double ("Luminance Denoising", "Radius"); if (pedited) pedited->lumaDenoise.radius = true; }
+ if (keyFile.has_key ("Luminance Denoising", "EdgeTolerance")) { lumaDenoise.edgetolerance = keyFile.get_integer ("Luminance Denoising", "EdgeTolerance"); if (pedited) pedited->lumaDenoise.edgetolerance = true; }
+}*/
// load colorDenoise
-if (keyFile.has_group ("Chrominance Denoising")) {
- if (keyFile.has_key ("Chrominance Denoising", "Enabled")) colorDenoise.enabled = keyFile.get_boolean ("Chrominance Denoising", "Enabled");
- if (keyFile.has_key ("Chrominance Denoising", "Radius")) colorDenoise.amount = 10*keyFile.get_double ("Chrominance Denoising", "Radius");
- else if (keyFile.has_key ("Chrominance Denoising", "Amount")) colorDenoise.amount = keyFile.get_integer ("Chrominance Denoising", "Amount");
-}
+/*if (keyFile.has_group ("Chrominance Denoising")) {
+ if (keyFile.has_key ("Chrominance Denoising", "Enabled")) { colorDenoise.enabled = keyFile.get_boolean ("Chrominance Denoising", "Enabled"); if (pedited) pedited->colorDenoise.enabled = true; }
+ // WARNING: radius doesn't exist anymore; is there any compatibility issue that require to keep the following line?
+ if (keyFile.has_key ("Chrominance Denoising", "Radius")) { colorDenoise.amount = 10*keyFile.get_double ("Chrominance Denoising", "Radius"); }
+ if (keyFile.has_key ("Chrominance Denoising", "Amount")) { colorDenoise.amount = keyFile.get_integer ("Chrominance Denoising", "Amount"); if (pedited) pedited->colorDenoise.amount = true; }
+}*/
// load sh
-if (keyFile.has_group ("Shadows & Highlights")) {
- if (keyFile.has_key ("Shadows & Highlights", "Enabled")) sh.enabled = keyFile.get_boolean ("Shadows & Highlights", "Enabled");
- if (keyFile.has_key ("Shadows & Highlights", "HighQuality")) sh.hq = keyFile.get_boolean ("Shadows & Highlights", "HighQuality");
- if (keyFile.has_key ("Shadows & Highlights", "Highlights")) sh.highlights = keyFile.get_integer ("Shadows & Highlights", "Highlights");
- if (keyFile.has_key ("Shadows & Highlights", "HighlightTonalWidth")) sh.htonalwidth = keyFile.get_integer ("Shadows & Highlights", "HighlightTonalWidth");
- if (keyFile.has_key ("Shadows & Highlights", "Shadows")) sh.shadows = keyFile.get_integer ("Shadows & Highlights", "Shadows");
- if (keyFile.has_key ("Shadows & Highlights", "ShadowTonalWidth")) sh.stonalwidth = keyFile.get_integer ("Shadows & Highlights", "ShadowTonalWidth");
- if (keyFile.has_key ("Shadows & Highlights", "LocalContrast")) sh.localcontrast = keyFile.get_integer ("Shadows & Highlights", "LocalContrast");
- if (keyFile.has_key ("Shadows & Highlights", "Radius")) sh.radius = keyFile.get_integer ("Shadows & Highlights", "Radius");
+if (keyFile.has_group ("Shadows & Highlights")) {
+ if (keyFile.has_key ("Shadows & Highlights", "Enabled")) { sh.enabled = keyFile.get_boolean ("Shadows & Highlights", "Enabled"); if (pedited) pedited->sh.enabled = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "HighQuality")) { sh.hq = keyFile.get_boolean ("Shadows & Highlights", "HighQuality"); if (pedited) pedited->sh.hq = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "Highlights")) { sh.highlights = keyFile.get_integer ("Shadows & Highlights", "Highlights"); if (pedited) pedited->sh.highlights = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "HighlightTonalWidth")) { sh.htonalwidth = keyFile.get_integer ("Shadows & Highlights", "HighlightTonalWidth"); if (pedited) pedited->sh.htonalwidth = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "Shadows")) { sh.shadows = keyFile.get_integer ("Shadows & Highlights", "Shadows"); if (pedited) pedited->sh.shadows = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "ShadowTonalWidth")) { sh.stonalwidth = keyFile.get_integer ("Shadows & Highlights", "ShadowTonalWidth"); if (pedited) pedited->sh.stonalwidth = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "LocalContrast")) { sh.localcontrast = keyFile.get_integer ("Shadows & Highlights", "LocalContrast"); if (pedited) pedited->sh.localcontrast = true; }
+ if (keyFile.has_key ("Shadows & Highlights", "Radius")) { sh.radius = keyFile.get_integer ("Shadows & Highlights", "Radius"); if (pedited) pedited->sh.radius = true; }
}
// load crop
-if (keyFile.has_group ("Crop")) {
- if (keyFile.has_key ("Crop", "Enabled")) crop.enabled = keyFile.get_boolean ("Crop", "Enabled");
- if (keyFile.has_key ("Crop", "X")) crop.x = keyFile.get_integer ("Crop", "X");
- if (keyFile.has_key ("Crop", "Y")) crop.y = keyFile.get_integer ("Crop", "Y");
- if (keyFile.has_key ("Crop", "W")) crop.w = keyFile.get_integer ("Crop", "W");
- if (keyFile.has_key ("Crop", "H")) crop.h = keyFile.get_integer ("Crop", "H");
- if (keyFile.has_key ("Crop", "FixedRatio")) crop.fixratio = keyFile.get_boolean ("Crop", "FixedRatio");
- if (keyFile.has_key ("Crop", "Ratio")){
- crop.ratio = keyFile.get_string ("Crop", "Ratio");
- //backwards compatibility for crop.ratio
- if (crop.ratio=="DIN") crop.ratio = "1.414 - DIN EN ISO 216";
- if (crop.ratio=="8.5:11") crop.ratio = "8.5:11 - US Letter";
- if (crop.ratio=="11:17") crop.ratio = "11:17 - Tabloid";
+if (keyFile.has_group ("Crop")) {
+ if (keyFile.has_key ("Crop", "Enabled")) { crop.enabled = keyFile.get_boolean ("Crop", "Enabled"); if (pedited) pedited->crop.enabled = true; }
+ if (keyFile.has_key ("Crop", "X")) { crop.x = keyFile.get_integer ("Crop", "X"); if (pedited) pedited->crop.x = true; }
+ if (keyFile.has_key ("Crop", "Y")) { crop.y = keyFile.get_integer ("Crop", "Y"); if (pedited) pedited->crop.y = true; }
+ if (keyFile.has_key ("Crop", "W")) { crop.w = keyFile.get_integer ("Crop", "W"); if (pedited) pedited->crop.w = true; }
+ if (keyFile.has_key ("Crop", "H")) { crop.h = keyFile.get_integer ("Crop", "H"); if (pedited) pedited->crop.h = true; }
+ if (keyFile.has_key ("Crop", "FixedRatio")) { crop.fixratio = keyFile.get_boolean ("Crop", "FixedRatio"); if (pedited) pedited->crop.fixratio = true; }
+ if (keyFile.has_key ("Crop", "Ratio")) {
+ crop.ratio = keyFile.get_string ("Crop", "Ratio");
+ if (pedited) pedited->crop.ratio = true;
+ //backwards compatibility for crop.ratio
+ if (crop.ratio=="DIN") crop.ratio = "1.414 - DIN EN ISO 216";
+ if (crop.ratio=="8.5:11") crop.ratio = "8.5:11 - US Letter";
+ if (crop.ratio=="11:17") crop.ratio = "11:17 - Tabloid";
}
- if (keyFile.has_key ("Crop", "Orientation"))crop.orientation= keyFile.get_string ("Crop", "Orientation");
- if (keyFile.has_key ("Crop", "Guide")) crop.guide = keyFile.get_string ("Crop", "Guide");
+ if (keyFile.has_key ("Crop", "Orientation")) { crop.orientation= keyFile.get_string ("Crop", "Orientation"); if (pedited) pedited->crop.orientation = true; }
+ if (keyFile.has_key ("Crop", "Guide")) { crop.guide = keyFile.get_string ("Crop", "Guide"); if (pedited) pedited->crop.guide = true; }
}
// load coarse
-if (keyFile.has_group ("Coarse Transformation")) {
- if (keyFile.has_key ("Coarse Transformation", "Rotate")) coarse.rotate = keyFile.get_integer ("Coarse Transformation", "Rotate");
- if (keyFile.has_key ("Coarse Transformation", "HorizontalFlip")) coarse.hflip = keyFile.get_boolean ("Coarse Transformation", "HorizontalFlip");
- if (keyFile.has_key ("Coarse Transformation", "VerticalFlip")) coarse.vflip = keyFile.get_boolean ("Coarse Transformation", "VerticalFlip");
+if (keyFile.has_group ("Coarse Transformation")) {
+ if (keyFile.has_key ("Coarse Transformation", "Rotate")) { coarse.rotate = keyFile.get_integer ("Coarse Transformation", "Rotate"); if (pedited) pedited->coarse.rotate = true; }
+ if (keyFile.has_key ("Coarse Transformation", "HorizontalFlip")) { coarse.hflip = keyFile.get_boolean ("Coarse Transformation", "HorizontalFlip"); if (pedited) pedited->coarse.hflip = true; }
+ if (keyFile.has_key ("Coarse Transformation", "VerticalFlip")) { coarse.vflip = keyFile.get_boolean ("Coarse Transformation", "VerticalFlip"); if (pedited) pedited->coarse.vflip = true; }
}
// load rotate
-if (keyFile.has_group ("Rotation")) {
- if (keyFile.has_key ("Rotation", "Degree")) rotate.degree = keyFile.get_double ("Rotation", "Degree");
+if (keyFile.has_group ("Rotation")) {
+ if (keyFile.has_key ("Rotation", "Degree")) { rotate.degree = keyFile.get_double ("Rotation", "Degree"); if (pedited) pedited->rotate.degree = true; }
}
- // load commonTrans
+ // load commonTrans
if (keyFile.has_group ("Common Properties for Transformations")) {
- if (keyFile.has_key ("Common Properties for Transformations", "AutoFill")) commonTrans.autofill = keyFile.get_boolean ("Common Properties for Transformations", "AutoFill");
+ if (keyFile.has_key ("Common Properties for Transformations", "AutoFill")) { commonTrans.autofill = keyFile.get_boolean ("Common Properties for Transformations", "AutoFill"); if (pedited) pedited->commonTrans.autofill = true; }
}
// load distortion
-if (keyFile.has_group ("Distortion")) {
- if (keyFile.has_key ("Distortion", "Amount")) distortion.amount = keyFile.get_double ("Distortion", "Amount");
- if (keyFile.has_key ("Distortion", "UseLensFun")) distortion.uselensfun = keyFile.get_boolean ("Distortion", "UseLensFun");
+if (keyFile.has_group ("Distortion")) {
+ if (keyFile.has_key ("Distortion", "Amount")) { distortion.amount = keyFile.get_double ("Distortion", "Amount"); if (pedited) pedited->distortion.amount = true; }
+ if (keyFile.has_key ("Distortion", "UseLensFun")) { distortion.uselensfun = keyFile.get_boolean ("Distortion", "UseLensFun"); if (pedited) pedited->distortion.uselensfun = true; }
}
- // load perspective correction
+ // load perspective correction
if (keyFile.has_group ("Perspective")) {
- if (keyFile.has_key ("Perspective", "Horizontal")) perspective.horizontal = keyFile.get_integer ("Perspective", "Horizontal");
- if (keyFile.has_key ("Perspective", "Vertical")) perspective.vertical = keyFile.get_integer ("Perspective", "Vertical");
+ if (keyFile.has_key ("Perspective", "Horizontal")) { perspective.horizontal = keyFile.get_integer ("Perspective", "Horizontal"); if (pedited) pedited->perspective.horizontal = true; }
+ if (keyFile.has_key ("Perspective", "Vertical")) { perspective.vertical = keyFile.get_integer ("Perspective", "Vertical"); if (pedited) pedited->perspective.vertical = true; }
}
// load c/a correction
-if (keyFile.has_group ("CACorrection")) {
- if (keyFile.has_key ("CACorrection", "Red")) cacorrection.red = keyFile.get_double ("CACorrection", "Red");
- if (keyFile.has_key ("CACorrection", "Blue")) cacorrection.blue = keyFile.get_double ("CACorrection", "Blue");
+if (keyFile.has_group ("CACorrection")) {
+ if (keyFile.has_key ("CACorrection", "Red")) { cacorrection.red = keyFile.get_double ("CACorrection", "Red"); if (pedited) pedited->cacorrection.red = true; }
+ if (keyFile.has_key ("CACorrection", "Blue")) { cacorrection.blue = keyFile.get_double ("CACorrection", "Blue"); if (pedited) pedited->cacorrection.blue = true; }
}
// load vignetting correction
-if (keyFile.has_group ("Vignetting Correction")) {
- if (keyFile.has_key ("Vignetting Correction", "Amount")) vignetting.amount = keyFile.get_integer ("Vignetting Correction", "Amount");
- if (keyFile.has_key ("Vignetting Correction", "Radius")) vignetting.radius = keyFile.get_integer ("Vignetting Correction", "Radius");
- if (keyFile.has_key ("Vignetting Correction", "Strength")) vignetting.strength = keyFile.get_integer ("Vignetting Correction", "Strength");
- if (keyFile.has_key ("Vignetting Correction", "CenterX")) vignetting.centerX = keyFile.get_integer ("Vignetting Correction", "CenterX");
- if (keyFile.has_key ("Vignetting Correction", "CenterY")) vignetting.centerY = keyFile.get_integer ("Vignetting Correction", "CenterY");
+if (keyFile.has_group ("Vignetting Correction")) {
+ if (keyFile.has_key ("Vignetting Correction", "Amount")) { vignetting.amount = keyFile.get_integer ("Vignetting Correction", "Amount"); if (pedited) pedited->vignetting.amount = true; }
+ if (keyFile.has_key ("Vignetting Correction", "Radius")) { vignetting.radius = keyFile.get_integer ("Vignetting Correction", "Radius"); if (pedited) pedited->vignetting.radius = true; }
+ if (keyFile.has_key ("Vignetting Correction", "Strength")) { vignetting.strength = keyFile.get_integer ("Vignetting Correction", "Strength"); if (pedited) pedited->vignetting.strength = true; }
+ if (keyFile.has_key ("Vignetting Correction", "CenterX")) { vignetting.centerX = keyFile.get_integer ("Vignetting Correction", "CenterX"); if (pedited) pedited->vignetting.centerX = true; }
+ if (keyFile.has_key ("Vignetting Correction", "CenterY")) { vignetting.centerY = keyFile.get_integer ("Vignetting Correction", "CenterY"); if (pedited) pedited->vignetting.centerY = true; }
}
// load highlight recovery settings
-if (keyFile.has_group ("HLRecovery")) {
- if (keyFile.has_key ("HLRecovery", "Enabled")) hlrecovery.enabled = keyFile.get_boolean ("HLRecovery", "Enabled");
- if (keyFile.has_key ("HLRecovery", "Method")) hlrecovery.method = keyFile.get_string ("HLRecovery", "Method");
+if (keyFile.has_group ("HLRecovery")) {
+ if (keyFile.has_key ("HLRecovery", "Enabled")) { hlrecovery.enabled = keyFile.get_boolean ("HLRecovery", "Enabled"); if (pedited) pedited->hlrecovery.enabled = true; }
+ if (keyFile.has_key ("HLRecovery", "Method")) { hlrecovery.method = keyFile.get_string ("HLRecovery", "Method"); if (pedited) pedited->hlrecovery.method = true; }
}
// load resize settings
-if (keyFile.has_group ("Resize")) {
- if (keyFile.has_key ("Resize", "Enabled")) resize.enabled = keyFile.get_boolean ("Resize", "Enabled");
- if (keyFile.has_key ("Resize", "Scale")) resize.scale = keyFile.get_double ("Resize", "Scale");
- if (keyFile.has_key ("Resize", "AppliesTo")) resize.appliesTo = keyFile.get_string ("Resize", "AppliesTo");
- if (keyFile.has_key ("Resize", "Method")) resize.method = keyFile.get_string ("Resize", "Method");
- if (keyFile.has_key ("Resize", "DataSpecified")) resize.dataspec = keyFile.get_integer ("Resize", "DataSpecified");
- if (keyFile.has_key ("Resize", "Width")) resize.width = keyFile.get_integer ("Resize", "Width");
- if (keyFile.has_key ("Resize", "Height")) resize.height = keyFile.get_integer ("Resize", "Height");
+if (keyFile.has_group ("Resize")) {
+ if (keyFile.has_key ("Resize", "Enabled")) { resize.enabled = keyFile.get_boolean ("Resize", "Enabled"); if (pedited) pedited->resize.enabled = true; }
+ if (keyFile.has_key ("Resize", "Scale")) { resize.scale = keyFile.get_double ("Resize", "Scale"); if (pedited) pedited->resize.scale = true; }
+ if (keyFile.has_key ("Resize", "AppliesTo")) { resize.appliesTo = keyFile.get_string ("Resize", "AppliesTo"); if (pedited) pedited->resize.appliesTo = true; }
+ if (keyFile.has_key ("Resize", "Method")) { resize.method = keyFile.get_string ("Resize", "Method"); if (pedited) pedited->resize.method = true; }
+ if (keyFile.has_key ("Resize", "DataSpecified")) { resize.dataspec = keyFile.get_integer ("Resize", "DataSpecified"); if (pedited) pedited->resize.dataspec = true; }
+ if (keyFile.has_key ("Resize", "Width")) { resize.width = keyFile.get_integer ("Resize", "Width"); if (pedited) pedited->resize.width = true; }
+ if (keyFile.has_key ("Resize", "Height")) { resize.height = keyFile.get_integer ("Resize", "Height"); if (pedited) pedited->resize.height = true; }
}
// load color management settings
-if (keyFile.has_group ("Color Management")) {
- if (keyFile.has_key ("Color Management", "InputProfile")) icm.input = keyFile.get_string ("Color Management", "InputProfile");
- if (keyFile.has_key ("Color Management", "BlendCMSMatrix")) icm.blendCMSMatrix = keyFile.get_boolean ("Color Management", "BlendCMSMatrix");
- if (keyFile.has_key ("Color Management", "WorkingProfile")) icm.working = keyFile.get_string ("Color Management", "WorkingProfile");
- if (keyFile.has_key ("Color Management", "OutputProfile")) icm.output = keyFile.get_string ("Color Management", "OutputProfile");
- if (keyFile.has_key ("Color Management", "Gammafree")) icm.gamma = keyFile.get_string ("Color Management", "Gammafree");
- if (keyFile.has_key ("Color Management", "Freegamma")) icm.freegamma = keyFile.get_boolean ("Color Management", "Freegamma");
- if (keyFile.has_key ("Color Management", "GammaVal")) icm.gampos = keyFile.get_double ("Color Management", "GammaVal");
- if (keyFile.has_key ("Color Management", "GammaSlope")) icm.slpos = keyFile.get_double ("Color Management", "GammaSlope");
-
+if (keyFile.has_group ("Color Management")) {
+ if (keyFile.has_key ("Color Management", "InputProfile")) { icm.input = keyFile.get_string ("Color Management", "InputProfile"); if (pedited) pedited->icm.input = true; }
+ if (keyFile.has_key ("Color Management", "BlendCMSMatrix")) { icm.blendCMSMatrix = keyFile.get_boolean ("Color Management", "BlendCMSMatrix"); if (pedited) pedited->icm.blendCMSMatrix = true; }
+ if (keyFile.has_key ("Color Management", "WorkingProfile")) { icm.working = keyFile.get_string ("Color Management", "WorkingProfile"); if (pedited) pedited->icm.working = true; }
+ if (keyFile.has_key ("Color Management", "OutputProfile")) { icm.output = keyFile.get_string ("Color Management", "OutputProfile"); if (pedited) pedited->icm.output = true; }
+ if (keyFile.has_key ("Color Management", "Gammafree")) { icm.gamma = keyFile.get_string ("Color Management", "Gammafree"); if (pedited) pedited->icm.gamfree = true; }
+ if (keyFile.has_key ("Color Management", "Freegamma")) { icm.freegamma = keyFile.get_boolean ("Color Management", "Freegamma"); if (pedited) pedited->icm.freegamma = true; }
+ if (keyFile.has_key ("Color Management", "GammaVal")) { icm.gampos = keyFile.get_double ("Color Management", "GammaVal"); if (pedited) pedited->icm.gamma = true; }
+ if (keyFile.has_key ("Color Management", "GammaSlope")) { icm.slpos = keyFile.get_double ("Color Management", "GammaSlope"); if (pedited) pedited->icm.slpos = true; }
+
}
- // load directional pyramid equalizer parameters
+ // load directional pyramid equalizer parameters
if (keyFile.has_group ("Directional Pyramid Equalizer")) {
- if (keyFile.has_key ("Directional Pyramid Equalizer", "Enabled")) dirpyrequalizer.enabled = keyFile.get_boolean ("Directional Pyramid Equalizer", "Enabled");
- for(int i = 0; i < 5; i ++)
- {
- 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", "Enabled")) { dirpyrequalizer.enabled = keyFile.get_boolean ("Directional Pyramid Equalizer", "Enabled"); if (pedited) pedited->dirpyrequalizer.enabled = true; }
+ for(int i = 0; i < 5; i ++) {
+ 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 (pedited) pedited->dirpyrequalizer.mult[i] = true; }
+ }
}
- // load HSV equalizer parameters
+ // load HSV equalizer parameters
if (keyFile.has_group ("HSV Equalizer")) {
- if (ppVersion>=300) {
- if (keyFile.has_key ("HSV Equalizer", "HCurve")) hsvequalizer.hcurve = keyFile.get_double_list ("HSV Equalizer", "HCurve");
- if (keyFile.has_key ("HSV Equalizer", "SCurve")) hsvequalizer.scurve = keyFile.get_double_list ("HSV Equalizer", "SCurve");
- if (keyFile.has_key ("HSV Equalizer", "VCurve")) hsvequalizer.vcurve = keyFile.get_double_list ("HSV Equalizer", "VCurve");
- }
+ if (ppVersion>=300) {
+ if (keyFile.has_key ("HSV Equalizer", "HCurve")) { hsvequalizer.hcurve = keyFile.get_double_list ("HSV Equalizer", "HCurve"); if (pedited) pedited->hsvequalizer.hcurve = true; }
+ if (keyFile.has_key ("HSV Equalizer", "SCurve")) { hsvequalizer.scurve = keyFile.get_double_list ("HSV Equalizer", "SCurve"); if (pedited) pedited->hsvequalizer.scurve = true; }
+ if (keyFile.has_key ("HSV Equalizer", "VCurve")) { hsvequalizer.vcurve = keyFile.get_double_list ("HSV Equalizer", "VCurve"); if (pedited) pedited->hsvequalizer.vcurve = true; }
+ }
}
- // load RGB curves
+ // load RGB curves
if (keyFile.has_group ("RGB Curves")) {
- if (keyFile.has_key ("RGB Curves", "rCurve")) rgbCurves.rcurve = keyFile.get_double_list ("RGB Curves", "rCurve");
- if (keyFile.has_key ("RGB Curves", "gCurve")) rgbCurves.gcurve = keyFile.get_double_list ("RGB Curves", "gCurve");
- if (keyFile.has_key ("RGB Curves", "bCurve")) rgbCurves.bcurve = keyFile.get_double_list ("RGB Curves", "bCurve");
+ if (keyFile.has_key ("RGB Curves", "rCurve")) { rgbCurves.rcurve = keyFile.get_double_list ("RGB Curves", "rCurve"); if (pedited) pedited->rgbCurves.rcurve = true; }
+ if (keyFile.has_key ("RGB Curves", "gCurve")) { rgbCurves.gcurve = keyFile.get_double_list ("RGB Curves", "gCurve"); if (pedited) pedited->rgbCurves.gcurve = true; }
+ if (keyFile.has_key ("RGB Curves", "bCurve")) { rgbCurves.bcurve = keyFile.get_double_list ("RGB Curves", "bCurve"); if (pedited) pedited->rgbCurves.bcurve = true; }
}
- // load raw settings
+ // load raw settings
if (keyFile.has_group ("RAW")) {
- if (keyFile.has_key ("RAW", "DarkFrame")) raw.dark_frame = keyFile.get_string ("RAW", "DarkFrame" );
- if (keyFile.has_key ("RAW", "DarkFrameAuto")) raw.df_autoselect = keyFile.get_boolean ("RAW", "DarkFrameAuto" );
- if (keyFile.has_key ("RAW", "FlatFieldFile")) raw.ff_file = keyFile.get_string ("RAW", "FlatFieldFile" );
- if (keyFile.has_key ("RAW", "FlatFieldAutoSelect")) raw.ff_AutoSelect = keyFile.get_boolean ("RAW", "FlatFieldAutoSelect" );
- if (keyFile.has_key ("RAW", "FlatFieldBlurRadius")) raw.ff_BlurRadius = keyFile.get_integer ("RAW", "FlatFieldBlurRadius" );
- if (keyFile.has_key ("RAW", "FlatFieldBlurType")) raw.ff_BlurType = keyFile.get_string ("RAW", "FlatFieldBlurType" );
- if (keyFile.has_key ("RAW", "CA")) raw.ca_autocorrect = keyFile.get_boolean ("RAW", "CA" );
- if (keyFile.has_key ("RAW", "CARed")) raw.cared = keyFile.get_double ("RAW", "CARed" );
- if (keyFile.has_key ("RAW", "CABlue")) raw.cablue = keyFile.get_double ("RAW", "CABlue" );
- if (keyFile.has_key ("RAW", "HotDeadPixels")) raw.hotdeadpix_filt = keyFile.get_boolean ("RAW", "HotDeadPixels" );
- if (keyFile.has_key ("RAW", "HotDeadPixelThresh")) raw.hotdeadpix_thresh = keyFile.get_integer ("RAW", "HotDeadPixelThresh" );
- if (keyFile.has_key ("RAW", "LineDenoise")) raw.linenoise = keyFile.get_integer ("RAW", "LineDenoise" );
- if (keyFile.has_key ("RAW", "GreenEqThreshold")) raw.greenthresh= keyFile.get_integer ("RAW", "GreenEqThreshold");
- if (keyFile.has_key ("RAW", "CcSteps")) raw.ccSteps = keyFile.get_integer ("RAW", "CcSteps");
- if (keyFile.has_key ("RAW", "Method")) raw.dmethod = keyFile.get_string ("RAW", "Method");
- if (keyFile.has_key ("RAW", "DCBIterations")) raw.dcb_iterations = keyFile.get_integer("RAW", "DCBIterations");
- if (keyFile.has_key ("RAW", "DCBEnhance")) raw.dcb_enhance =keyFile.get_boolean("RAW", "DCBEnhance");
- if (keyFile.has_key ("RAW", "ALLEnhance")) raw.all_enhance =keyFile.get_boolean("RAW", "ALLEnhance");
-
- if (keyFile.has_key ("RAW", "PreExposure")) raw.expos =keyFile.get_double("RAW", "PreExposure");
- if (keyFile.has_key ("RAW", "PrePreserv")) raw.preser =keyFile.get_double("RAW", "PrePreserv");
- if (keyFile.has_key ("RAW", "PreBlackzero")) raw.blackzero =keyFile.get_double("RAW", "PreBlackzero");
- if (keyFile.has_key ("RAW", "PreBlackone")) raw.blackone =keyFile.get_double("RAW", "PreBlackone");
- if (keyFile.has_key ("RAW", "PreBlacktwo")) raw.blacktwo =keyFile.get_double("RAW", "PreBlacktwo");
- if (keyFile.has_key ("RAW", "PreBlackthree")) raw.blackthree =keyFile.get_double("RAW", "PreBlackthree");
- if (keyFile.has_key ("RAW", "PreTwoGreen")) raw.twogreen =keyFile.get_boolean("RAW", "PreTwoGreen");
-
+ if (keyFile.has_key ("RAW", "DarkFrame")) { raw.dark_frame = keyFile.get_string ("RAW", "DarkFrame" ); if (pedited) pedited->raw.darkFrame = true; }
+ if (keyFile.has_key ("RAW", "DarkFrameAuto")) { raw.df_autoselect = keyFile.get_boolean ("RAW", "DarkFrameAuto" ); if (pedited) pedited->raw.dfAuto = true; }
+ if (keyFile.has_key ("RAW", "FlatFieldFile")) { raw.ff_file = keyFile.get_string ("RAW", "FlatFieldFile" ); if (pedited) pedited->raw.ff_file = true; }
+ if (keyFile.has_key ("RAW", "FlatFieldAutoSelect")) { raw.ff_AutoSelect = keyFile.get_boolean ("RAW", "FlatFieldAutoSelect" ); if (pedited) pedited->raw.ff_AutoSelect = true; }
+ if (keyFile.has_key ("RAW", "FlatFieldBlurRadius")) { raw.ff_BlurRadius = keyFile.get_integer ("RAW", "FlatFieldBlurRadius" ); if (pedited) pedited->raw.ff_BlurRadius = true; }
+ if (keyFile.has_key ("RAW", "FlatFieldBlurType")) { raw.ff_BlurType = keyFile.get_string ("RAW", "FlatFieldBlurType" ); if (pedited) pedited->raw.ff_BlurType = true; }
+ if (keyFile.has_key ("RAW", "CA")) { raw.ca_autocorrect = keyFile.get_boolean ("RAW", "CA" ); if (pedited) pedited->raw.caCorrection = true; }
+ if (keyFile.has_key ("RAW", "CARed")) { raw.cared = keyFile.get_double ("RAW", "CARed" ); if (pedited) pedited->raw.caRed = true; }
+ if (keyFile.has_key ("RAW", "CABlue")) { raw.cablue = keyFile.get_double ("RAW", "CABlue" ); if (pedited) pedited->raw.caBlue = true; }
+ if (keyFile.has_key ("RAW", "HotDeadPixels")) { raw.hotdeadpix_filt = keyFile.get_boolean ("RAW", "HotDeadPixels" ); if (pedited) pedited->raw.hotDeadPixelFilter = true; }
+ if (keyFile.has_key ("RAW", "HotDeadPixelThresh")) { raw.hotdeadpix_thresh = keyFile.get_integer ("RAW", "HotDeadPixelThresh" ); if (pedited) pedited->raw.hotDeadPixelThresh = true; }
+ if (keyFile.has_key ("RAW", "LineDenoise")) { raw.linenoise = keyFile.get_integer ("RAW", "LineDenoise" ); if (pedited) pedited->raw.linenoise = true; }
+ if (keyFile.has_key ("RAW", "GreenEqThreshold")) { raw.greenthresh= keyFile.get_integer ("RAW", "GreenEqThreshold"); if (pedited) pedited->raw.greenEq = true; }
+ if (keyFile.has_key ("RAW", "CcSteps")) { raw.ccSteps = keyFile.get_integer ("RAW", "CcSteps"); if (pedited) pedited->raw.ccSteps = true; }
+ if (keyFile.has_key ("RAW", "Method")) { raw.dmethod = keyFile.get_string ("RAW", "Method"); if (pedited) pedited->raw.dmethod = true; }
+ if (keyFile.has_key ("RAW", "DCBIterations")) { raw.dcb_iterations = keyFile.get_integer("RAW", "DCBIterations"); if (pedited) pedited->raw.dcbIterations = true; }
+ if (keyFile.has_key ("RAW", "DCBEnhance")) { raw.dcb_enhance =keyFile.get_boolean("RAW", "DCBEnhance"); if (pedited) pedited->raw.dcbEnhance = true; }
+ if (keyFile.has_key ("RAW", "ALLEnhance")) { raw.all_enhance =keyFile.get_boolean("RAW", "ALLEnhance"); if (pedited) pedited->raw.allEnhance = true; }
+
+ if (keyFile.has_key ("RAW", "PreExposure")) { raw.expos =keyFile.get_double("RAW", "PreExposure"); if (pedited) pedited->raw.exPos = true; }
+ if (keyFile.has_key ("RAW", "PrePreserv")) { raw.preser =keyFile.get_double("RAW", "PrePreserv"); if (pedited) pedited->raw.exPreser = true; }
+ if (keyFile.has_key ("RAW", "PreBlackzero")) { raw.blackzero =keyFile.get_double("RAW", "PreBlackzero"); if (pedited) pedited->raw.exBlackzero = true; }
+ if (keyFile.has_key ("RAW", "PreBlackone")) { raw.blackone =keyFile.get_double("RAW", "PreBlackone"); if (pedited) pedited->raw.exBlackone = true; }
+ if (keyFile.has_key ("RAW", "PreBlacktwo")) { raw.blacktwo =keyFile.get_double("RAW", "PreBlacktwo"); if (pedited) pedited->raw.exBlacktwo = true; }
+ if (keyFile.has_key ("RAW", "PreBlackthree")) { raw.blackthree =keyFile.get_double("RAW", "PreBlackthree"); if (pedited) pedited->raw.exBlackthree = true; }
+ if (keyFile.has_key ("RAW", "PreTwoGreen")) { raw.twogreen =keyFile.get_boolean("RAW", "PreTwoGreen"); if (pedited) pedited->raw.exTwoGreen = true; }
+
}
// load exif change settings
if (keyFile.has_group ("Exif")) {
std::vector keys = keyFile.get_keys ("Exif");
- exif.resize (keys.size());
for (int i=0; i<(int)keys.size(); i++) {
- exif[i].field = keys[i];
- exif[i].value = keyFile.get_string ("Exif", keys[i]);
+ Glib::ustring tmpStr = keyFile.get_string ("Exif", keys[i]);
+ exif[keys[i]] = keyFile.get_string ("Exif", keys[i]);
+ if (pedited) pedited->exif = true;
}
}
- // load iptc change settings
+ /*
+ * Load iptc change settings
+ *
+ * Existing values are preserved, and the stored values
+ * are added to the list. To reset a field, the user has to
+ * save the profile with the field leaved empty, but still
+ * terminated by a semi-column ";"
+ *
+ * Please note that the old Keywords and SupplementalCategories
+ * tag content is fully replaced by the new one,
+ * i.e. they don't merge
+ */
if (keyFile.has_group ("IPTC")) {
std::vector keys = keyFile.get_keys ("IPTC");
- iptc.resize (keys.size());
- for (int i=0; i<(int)keys.size(); i++) {
- iptc[i].field = keys[i];
- iptc[i].values = keyFile.get_string_list ("IPTC", keys[i]);
+ IPTCPairs::iterator element;
+ for (unsigned int i=0; isecond.clear();
+ }
+
+ // TODO: look out if merging Keywords and SupplementalCategories from the procparams chain would be interesting
+ std::vector currIptc = keyFile.get_string_list ("IPTC", keys[i]);
+ for (
+ std::vector::iterator currLoadedTagValue=currIptc.begin();
+ currLoadedTagValue!=currIptc.end();
+ currLoadedTagValue++)
+ {
+ iptc[keys[i]].push_back(currLoadedTagValue->data());
+ }
+ if (pedited) pedited->iptc = true;
}
}
@@ -1054,15 +1114,15 @@ bool operator==(const DirPyrEqualizerParams & a, const DirPyrEqualizerParams & b
return true;
}
-bool operator==(const ExifPair& a, const ExifPair& b) {
+/*bool operator==(const ExifPairs& a, const ExifPairs& b) {
return a.field == b.field && a.value == b.value;
}
-bool operator==(const IPTCPair& a, const IPTCPair& b) {
+bool operator==(const IPTCPairs& a, const IPTCPairs& b) {
return a.field == b.field && a.values == b.values;
-}
+}*/
bool ProcParams::operator== (const ProcParams& other) {
return
@@ -1115,23 +1175,21 @@ bool ProcParams::operator== (const ProcParams& other) {
&& vibrance.protectskins == other.vibrance.protectskins
&& vibrance.avoidcolorshift == other.vibrance.avoidcolorshift
&& vibrance.pastsattog == other.vibrance.pastsattog
- && colorBoost.amount == other.colorBoost.amount
- && colorBoost.avoidclip == other.colorBoost.avoidclip
- && colorBoost.enable_saturationlimiter == other.colorBoost.enable_saturationlimiter
- && colorBoost.saturationlimit == other.colorBoost.saturationlimit
+ //&& colorBoost.amount == other.colorBoost.amount
+ //&& colorBoost.avoidclip == other.colorBoost.avoidclip
+ //&& colorBoost.enable_saturationlimiter == other.colorBoost.enable_saturationlimiter
+ //&& colorBoost.saturationlimit == other.colorBoost.saturationlimit
&& wb.method == other.wb.method
&& wb.green == other.wb.green
&& wb.temperature == other.wb.temperature
- && colorShift.a == other.colorShift.a
- && colorShift.b == other.colorShift.b
+ //&& colorShift.a == other.colorShift.a
+ //&& colorShift.b == other.colorShift.b
&& impulseDenoise.enabled == other.impulseDenoise.enabled
&& impulseDenoise.thresh == other.impulseDenoise.thresh
&& dirpyrDenoise.enabled == other.dirpyrDenoise.enabled
&& dirpyrDenoise.luma == other.dirpyrDenoise.luma
&& dirpyrDenoise.chroma == other.dirpyrDenoise.chroma
&& dirpyrDenoise.gamma == other.dirpyrDenoise.gamma
- && dirpyrDenoise.lumcurve == other.dirpyrDenoise.lumcurve
- && dirpyrDenoise.chromcurve == other.dirpyrDenoise.chromcurve
&& edgePreservingDecompositionUI.enabled == other.edgePreservingDecompositionUI.enabled
&& edgePreservingDecompositionUI.Strength == other.edgePreservingDecompositionUI.Strength
&& edgePreservingDecompositionUI.EdgeStopping == other.edgePreservingDecompositionUI.EdgeStopping
@@ -1140,13 +1198,12 @@ bool ProcParams::operator== (const ProcParams& other) {
&& defringe.enabled == other.defringe.enabled
&& defringe.radius == other.defringe.radius
&& defringe.threshold == other.defringe.threshold
- && lumaDenoise.enabled == other.lumaDenoise.enabled
- && lumaDenoise.radius == other.lumaDenoise.radius
- && lumaDenoise.edgetolerance == other.lumaDenoise.edgetolerance
- && colorDenoise.enabled == other.colorDenoise.enabled
- && colorDenoise.radius == other.colorDenoise.radius
- && colorDenoise.edgetolerance == other.colorDenoise.edgetolerance
- && colorDenoise.edgesensitive == other.colorDenoise.edgesensitive
+ //&& lumaDenoise.enabled == other.lumaDenoise.enabled
+ //&& lumaDenoise.radius == other.lumaDenoise.radius
+ //&& lumaDenoise.edgetolerance == other.lumaDenoise.edgetolerance
+ //&& colorDenoise.enabled == other.colorDenoise.enabled
+ //&& colorDenoise.edgetolerance == other.colorDenoise.edgetolerance
+ //&& colorDenoise.edgesensitive == other.colorDenoise.edgesensitive
&& sh.enabled == other.sh.enabled
&& sh.hq == other.sh.hq
&& sh.highlights == other.sh.highlights
@@ -1204,6 +1261,7 @@ bool ProcParams::operator== (const ProcParams& other) {
&& raw.cared == other.raw.cared
&& raw.cablue == other.raw.cablue
&& raw.hotdeadpix_filt == other.raw.hotdeadpix_filt
+ && raw.hotdeadpix_thresh == other.raw.hotdeadpix_thresh
&& raw.dmethod == other.raw.dmethod
&& raw.greenthresh == other.raw.greenthresh
&& raw.linenoise == other.raw.linenoise
@@ -1233,12 +1291,92 @@ bool ProcParams::operator== (const ProcParams& other) {
&& raw.blackthree==other.raw.blackthree
&& raw.twogreen==other.raw.twogreen;
- }
+}
bool ProcParams::operator!= (const ProcParams& other) {
return !(*this==other);
}
+
+PartialProfile::PartialProfile(bool createInstance) {
+ if (createInstance) {
+ pparams = new ProcParams();
+ pedited = new ParamsEdited();
+ }
+ else {
+ pparams = NULL;
+ pedited=NULL;
+ }
+}
+
+PartialProfile::PartialProfile(ProcParams* pp, ParamsEdited* pe, bool fullCopy) {
+ if (fullCopy && pp) {
+ pparams = new ProcParams(*pp);
+ }
+ else
+ pparams = pp;
+
+ if (fullCopy && pe) {
+ pedited = new ParamsEdited(*pe);
+ }
+ else
+ pedited = pe;
+};
+
+PartialProfile::PartialProfile(const ProcParams* pp, const ParamsEdited* pe) {
+ if (pp) {
+ pparams = new ProcParams(*pp);
+ }
+ else
+ pparams = NULL;
+
+ if (pe) {
+ pedited = new ParamsEdited(*pe);
+ }
+ else
+ pedited = NULL;
+};
+
+int PartialProfile::load (Glib::ustring fName) {
+ if (!pparams) pparams = new ProcParams();
+ if (!pedited) pedited = new ParamsEdited();
+ return pparams->load(fName, pedited);
+}
+
+void PartialProfile::deleteInstance () {
+ if (pparams) { delete pparams; pparams = NULL; }
+ if (pedited) { delete pedited; pedited = NULL; }
+}
+
+/*
+ * Set the all values of the General section to false
+ * in order to preserve them in applyTo
+ */
+void PartialProfile::clearGeneral () {
+ if (pedited) {
+ pedited->general.colorlabel = false;
+ pedited->general.intrash = false;
+ pedited->general.rank = false;
+ }
+}
+
+void PartialProfile::applyTo(ProcParams *destParams) const {
+ if (destParams && pparams && pedited) {
+ if (pedited->coarse.rotate)
+ destParams->coarse.rotate = 0;
+ if (pedited->coarse.hflip)
+ destParams->coarse.hflip = false;
+ if (pedited->coarse.vflip)
+ destParams->coarse.vflip = false;
+
+ pedited->combine(*destParams, *pparams, true);
+ }
+}
+
+void PartialProfile::set(bool v) {
+ if (pedited) pedited->set(v);
+};
+
}
}
diff --git a/rtengine/procparams.h b/rtengine/procparams.h
index b1dbc3913..147f1b5b2 100644
--- a/rtengine/procparams.h
+++ b/rtengine/procparams.h
@@ -22,6 +22,8 @@
#include
#include
+class ParamsEdited;
+
namespace rtengine {
namespace procparams {
@@ -126,14 +128,14 @@ class VibranceParams {
/**
* Parameters of the color boost
*/
-class ColorBoostParams {
+/*class ColorBoostParams {
public:
int amount;
bool avoidclip;
bool enable_saturationlimiter;
double saturationlimit;
-};
+};*/
/**
* Parameters of the white balance adjustments
@@ -179,36 +181,35 @@ class WBParams {
/**
* Parameters of the color shift
*/
-class ColorShiftParams {
+/*class ColorShiftParams {
public:
double a;
double b;
-};
+};*/
/**
* Parameters of the luminance denoising
*/
-class LumaDenoiseParams {
+/*class LumaDenoiseParams {
public:
bool enabled;
double radius;
int edgetolerance;
-};
+};*/
/**
* Parameters of the color denoising
*/
-class ColorDenoiseParams {
+/*class ColorDenoiseParams {
public:
bool enabled;
- double radius;
int edgetolerance;
bool edgesensitive;
int amount;
-};
+};*/
/**
* Parameters of defringing
@@ -243,8 +244,6 @@ class ColorDenoiseParams {
int luma;
int chroma;
float gamma;
- std::vector lumcurve;
- std::vector chromcurve;
};
//EPD related parameters.
@@ -420,24 +419,14 @@ class ColorManagementParams {
};
/**
- * A class representing a key/value for the exif metadata information
+ * Typedef for representing a key/value for the exif metadata information
*/
-class ExifPair {
-
- public:
- Glib::ustring field;
- Glib::ustring value;
-};
+typedef std::map ExifPairs;
/**
* The IPTC key/value pairs
*/
-class IPTCPair {
-
- public:
- Glib::ustring field;
- std::vector values;
-};
+typedef std::map > IPTCPairs;
/**
* Directional pyramid equalizer params
@@ -522,11 +511,11 @@ class ProcParams {
SharpenEdgeParams sharpenEdge; ///< Sharpen edge parameters
SharpenMicroParams sharpenMicro; ///< Sharpen microcontrast parameters
VibranceParams vibrance; ///< Vibrance parameters
- ColorBoostParams colorBoost; ///< Color boost parameters
+ //ColorBoostParams colorBoost; ///< Color boost parameters
WBParams wb; ///< White balance parameters
- ColorShiftParams colorShift; ///< Color shift parameters
- LumaDenoiseParams lumaDenoise; ///< Luminance denoising parameters
- ColorDenoiseParams colorDenoise; ///< Color denoising parameters
+ //ColorShiftParams colorShift; ///< Color shift parameters
+ //LumaDenoiseParams lumaDenoise; ///< Luminance denoising parameters
+ //ColorDenoiseParams colorDenoise; ///< Color denoising parameters
DefringeParams defringe; ///< Defringing parameters
ImpulseDenoiseParams impulseDenoise; ///< Impulse denoising parameters
DirPyrDenoiseParams dirpyrDenoise; ///< Directional Pyramid denoising parameters
@@ -544,18 +533,18 @@ class ProcParams {
HRecParams hlrecovery; ///< Highlight recovery parameters
ResizeParams resize; ///< Resize parameters
ColorManagementParams icm; ///< profiles/color spaces used during the image processing
- ColorManagementParams gam; ///< profiles/color spaces used during the image processing
RAWParams raw; ///< RAW parameters before demosaicing
DirPyrEqualizerParams dirpyrequalizer; ///< directional pyramid equalizer parameters
HSVEqualizerParams hsvequalizer; ///< hsv equalizer parameters
- std::vector exif; ///< List of modifications appplied on the exif tags of the input image
- std::vector iptc; ///< The IPTC tags and values to be saved to the output image
char rank; ///< Custom image quality ranking
char colorlabel; ///< Custom color label
bool inTrash; ///< Marks deleted image
- Glib::ustring appVersion; ///< Version of the application that generated the parameters
- int ppVersion; ///< Version of the PP file from which the parameters have been read
+ Glib::ustring appVersion; ///< Version of the application that generated the parameters
+ int ppVersion; ///< Version of the PP file from which the parameters have been read
+
+ ExifPairs exif; ///< List of modifications appplied on the exif tags of the input image
+ IPTCPairs iptc; ///< The IPTC tags and values to be saved to the output image
/**
* The constructor only sets the hand-wired defaults.
@@ -568,17 +557,19 @@ class ProcParams {
/**
* Saves the parameters to possibly two files. This is a performance improvement if a function has to
* save the same file in two different location, i.e. the cache and the image's directory
- * @param fname the name of the first file (can be an empty string)
- * @param fname2 the name of the second file (can be an empty string) (optional)
+ * @param fname the name of the first file (can be an empty string)
+ * @param fname2 the name of the second file (can be an empty string) (optional)
+ * @param pedited pointer to a ParamsEdited object (optional) to store which values has to be saved
* @return Error code (=0 if all supplied filenames where created correctly)
*/
- int save (Glib::ustring fname, Glib::ustring fname2 = "") const;
+ int save (Glib::ustring fname, Glib::ustring fname2 = "", ParamsEdited* pedited=NULL) const;
/**
* Loads the parameters from a file.
* @param fname the name of the file
+ * @params pedited pointer to a ParamsEdited object (optional) to store which values has been loaded
* @return Error code (=0 if no error)
*/
- int load (Glib::ustring fname);
+ int load (Glib::ustring fname, ParamsEdited* pedited=NULL);
/** Creates a new instance of ProcParams.
* @return a pointer to the new ProcParams instance. */
@@ -603,6 +594,32 @@ class ProcParams {
int write (Glib::ustring &fname, Glib::ustring &content) const;
};
+
+/**
+ * This class associate a ProcParams object and a ParamEdited object through a pointer
+ * to instance of each type in order to handle partial pp3 file loading (and later maybe
+ * saving too)
+ *
+ * PartialProfile is not responsible of ProcParams and ParamsEdited object creation
+ * and hence is not responsible of their destructions. The function that instanciate
+ * PartialProfile object has to handle all this itself.
+ */
+class PartialProfile {
+ public:
+ rtengine::procparams::ProcParams* pparams;
+ ParamsEdited* pedited;
+ PartialProfile& operator=(PartialProfile& rhs) { pparams=rhs.pparams; pedited=rhs.pedited; return *this; };
+
+ PartialProfile (bool createInstance=false);
+ PartialProfile (ProcParams* pp, ParamsEdited* pe=NULL, bool fullCopy=false);
+ PartialProfile (const ProcParams* pp, const ParamsEdited* pe=NULL);
+ void deleteInstance ();
+ void clearGeneral ();
+ int load (Glib::ustring fName);
+ void set (bool v);
+ void applyTo (ProcParams *destParams) const ;
+};
+
}
}
#endif
diff --git a/rtengine/rtengine.h b/rtengine/rtengine.h
index f170889b5..3fe8c1361 100644
--- a/rtengine/rtengine.h
+++ b/rtengine/rtengine.h
@@ -58,7 +58,7 @@ namespace rtengine {
virtual bool hasIPTC () const =0;
/** Returns the directory of IPTC tags.
* @return The directory of IPTC tags */
- virtual const std::vector getIPTCData () const =0;
+ virtual const procparams::IPTCPairs getIPTCData () const =0;
/** @return a struct containing the date and time of the image */
virtual struct tm getDateTime () const =0;
/** @return a timestamp containing the date and time of the image */
diff --git a/rtexif/CMakeLists.txt b/rtexif/CMakeLists.txt
index 90d39c836..e22ac7fef 100644
--- a/rtexif/CMakeLists.txt
+++ b/rtexif/CMakeLists.txt
@@ -3,8 +3,17 @@ add_library (rtexif rtexif.cc stdattribs.cc nikonattribs.cc canonattribs.cc
IF (WIN32)
set_target_properties (rtexif PROPERTIES COMPILE_FLAGS " -ffast-math -fexpensive-optimizations")
+ include_directories (${EXTRA_INCDIR} ${GLIB2_INCLUDE_DIRS} ${GLIBMM_INCLUDE_DIRS}
+ ${GTK_INCLUDE_DIRS} ${GTKMM_INCLUDE_DIRS})
+ link_directories (. ../rtexif ${EXTRA_LIBDIR} ${GLIB2_LIBRARY_DIRS} ${GLIBMM_LIBRARY_DIRS}
+ ${GTK_LIBRARY_DIRS} ${GTKMM_LIBRARY_DIRS})
+ #set_target_properties (rth PROPERTIES LINK_FLAGS "-mwindows")
ELSE (WIN32)
set_target_properties (rtexif PROPERTIES COMPILE_FLAGS " -ffast-math -fexpensive-optimizations -fPIC")
+ include_directories (${EXTRA_INCDIR} ${GLIB2_INCLUDE_DIRS}
+ ${GLIBMM_INCLUDE_DIRS} ${GTK_INCLUDE_DIRS} ${GTKMM_INCLUDE_DIRS})
+ link_directories (${EXTRA_LIBDIR} ${GLIB2_LIBRARY_DIRS}
+ ${GLIBMM_LIBRARY_DIRS} ${GTK_LIBRARY_DIRS} ${GTKMM_LIBRARY_DIRS})
ENDIF (WIN32)
IF (BUILD_SHARED_LIBS)
diff --git a/rtexif/rtexif.cc b/rtexif/rtexif.cc
index 50d7f6dcf..bc8c7e095 100644
--- a/rtexif/rtexif.cc
+++ b/rtexif/rtexif.cc
@@ -1404,7 +1404,7 @@ const std::vector& ExifManager::getDefaultTIFFTags (TagDirectory* forthis)
-int ExifManager::createJPEGMarker (const TagDirectory* root, const std::vector< std::pair >& changeList, int W, int H, unsigned char* buffer) {
+int ExifManager::createJPEGMarker (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, unsigned char* buffer) {
// write tiff header
int offs = 6;
@@ -1423,8 +1423,8 @@ int ExifManager::createJPEGMarker (const TagDirectory* root, const std::vector<
else
cl = new TagDirectory (NULL, ifdAttribs, INTEL);
- for (int i=0; iapplyChange (changeList[i].first, changeList[i].second);
+ for (rtengine::procparams::ExifPairs::const_iterator i=changeList.begin(); i!=changeList.end(); i++)
+ cl->applyChange (i->first, i->second);
getDefaultTIFFTags (cl);
@@ -1442,7 +1442,7 @@ int ExifManager::createJPEGMarker (const TagDirectory* root, const std::vector<
return size + 6;
}
-int ExifManager::createTIFFHeader (const TagDirectory* root, const std::vector< std::pair >& changeList, int W, int H, int bps, const char* profiledata, int profilelen, const char* iptcdata, int iptclen, unsigned char* buffer) {
+int ExifManager::createTIFFHeader (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, int bps, const char* profiledata, int profilelen, const char* iptcdata, int iptclen, unsigned char* buffer) {
// write tiff header
int offs = 0;
@@ -1489,8 +1489,8 @@ int ExifManager::createTIFFHeader (const TagDirectory* root, const std::vector<
}
// apply list of changes
- for (int i=0; iapplyChange (changeList[i].first, changeList[i].second);
+ for (rtengine::procparams::ExifPairs::const_iterator i=changeList.begin(); i!=changeList.end(); i++)
+ cl->applyChange (i->first, i->second);
// append default properties
getDefaultTIFFTags (cl);
diff --git a/rtexif/rtexif.h b/rtexif/rtexif.h
index 95a1723bc..58c1bbc8c 100644
--- a/rtexif/rtexif.h
+++ b/rtexif/rtexif.h
@@ -26,6 +26,7 @@
#include
#include
#include
+#include "../rtengine/procparams.h"
namespace rtexif {
@@ -203,8 +204,8 @@ class ExifManager {
static void parseCIFF (FILE* f, int base, int length, TagDirectory* root);
static const std::vector& getDefaultTIFFTags (TagDirectory* forthis);
- static int createJPEGMarker (const TagDirectory* root, const std::vector< std::pair >& changeList, int W, int H, unsigned char* buffer);
- static int createTIFFHeader (const TagDirectory* root, const std::vector< std::pair >& changeList, int W, int H, int bps, const char* profiledata, int profilelen, const char* iptcdata, int iptclen, unsigned char* buffer);
+ static int createJPEGMarker (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, unsigned char* buffer);
+ static int createTIFFHeader (const TagDirectory* root, const rtengine::procparams::ExifPairs& changeList, int W, int H, int bps, const char* profiledata, int profilelen, const char* iptcdata, int iptclen, unsigned char* buffer);
};
class Interpreter {
diff --git a/rtgui/CMakeLists.txt b/rtgui/CMakeLists.txt
index 26be6a17b..97ef4fc1a 100644
--- a/rtgui/CMakeLists.txt
+++ b/rtgui/CMakeLists.txt
@@ -45,8 +45,6 @@ else (WIN32)
${GTK_LIBRARY_DIRS} ${GTKMM_LIBRARY_DIRS} ${GIO_LIBRARY_DIRS} ${GIOMM_LIBRARY_DIRS} ${IPTCDATA_LIBRARY_DIRS} ${LCMS_LIBRARY_DIRS} ${GTHREAD_LIBRARY_DIRS} ${GOBJECT_LIBRARY_DIRS})
endif (WIN32)
# create config.h which defines where data are stored
-message (STATUS --- CMAKE_CURRENT_SOURCE_DIR = ${CMAKE_CURRENT_SOURCE_DIR})
-message (STATUS --- CMAKE_CURRENT_BINARY_DIR = ${CMAKE_CURRENT_BINARY_DIR})
configure_file (${CMAKE_CURRENT_SOURCE_DIR}/config.h.in ${CMAKE_CURRENT_SOURCE_DIR}/config.h)
add_executable (rth ${EXTRA_SRC} ${BASESOURCEFILES})
diff --git a/rtgui/batchtoolpanelcoord.cc b/rtgui/batchtoolpanelcoord.cc
index 98da9a8a9..d7a216055 100644
--- a/rtgui/batchtoolpanelcoord.cc
+++ b/rtgui/batchtoolpanelcoord.cc
@@ -77,7 +77,7 @@ void BatchToolPanelCoordinator::closeSession (bool save) {
for (unsigned int j=0; jtrimValues (&newParams);
- selected[i]->setProcParams (newParams, BATCHEDITOR, true);
+ selected[i]->setProcParams (newParams, NULL, BATCHEDITOR, true);
}
}
for (int i=0; iaddThumbnailListener (this);
}
+ // compare all the ProcParams and describe which parameters has different (i.e. inconsistent) values in pparamsEdited
pparamsEdited.initFrom (initialPP);
crop->setDimensions (100000, 100000);
@@ -188,7 +189,7 @@ void BatchToolPanelCoordinator::initSession () {
if (options.baBehav[ADDSET_SHARPENMICRO_UNIFORMITY]) pparams.sharpenMicro.uniformity = 0;
if (options.baBehav[ADDSET_CHMIXER]) for (int i=0; i<3; i++) pparams.chmixer.red[i] = pparams.chmixer.green[i] = pparams.chmixer.blue[i] = 0;
- if (options.baBehav[ADDSET_LD_EDGETOLERANCE]) pparams.lumaDenoise.edgetolerance = 0;
+ //if (options.baBehav[ADDSET_LD_EDGETOLERANCE]) pparams.lumaDenoise.edgetolerance = 0;
if (options.baBehav[ADDSET_WB_TEMPERATURE]) pparams.wb.temperature = 0;
if (options.baBehav[ADDSET_WB_GREEN]) pparams.wb.green = 0;
@@ -199,10 +200,10 @@ void BatchToolPanelCoordinator::initSession () {
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_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;
+ //if (options.baBehav[ADDSET_CS_BLUEYELLOW]) pparams.colorShift.a = 0;
+ //if (options.baBehav[ADDSET_CS_GREENMAGENTA]) pparams.colorShift.b = 0;
if (options.baBehav[ADDSET_ROTATE_DEGREE]) pparams.rotate.degree = 0;
if (options.baBehav[ADDSET_DIST_AMOUNT]) pparams.distortion.amount = 0;
@@ -228,6 +229,7 @@ void BatchToolPanelCoordinator::initSession () {
toolPanels[i]->read (&pparams, &pparamsEdited);
}
for (int i=0; iprocParamsChanged (&pparams, rtengine::EvPhotoLoaded, M("BATCH_PROCESSING"), &pparamsEdited);
}
}
@@ -271,7 +273,7 @@ void BatchToolPanelCoordinator::panelChanged (rtengine::ProcEvent event, const G
for (unsigned int j=0; jtrimValues (&newParams);
- selected[i]->setProcParams (newParams, BATCHEDITOR, false);
+ selected[i]->setProcParams (newParams, NULL, BATCHEDITOR, false);
}
for (int i=0; i ACTUALLY NOT SUPPORTED
+ return;
+ }
+
+ pparams = *(nparams->pparams);
if (paramsEdited)
pparamsEdited = *paramsEdited;
+
for (int i=0; iread (&pparams, &pparamsEdited);
somethingChanged = true;
@@ -319,12 +334,12 @@ void BatchToolPanelCoordinator::profileChange (const ProcParams *nparams, rteng
for (int i=0; iwrite (&pparams, &pparamsEdited);
- // combine with initial parameters and set
+ // combine with initial parameters of each image and set
ProcParams newParams;
for (int i=0; isetProcParams (newParams, BATCHEDITOR, false);
+ selected[i]->setProcParams (newParams, NULL, BATCHEDITOR, false);
}
for (int i=0; i
#include "../rtengine/rtengine.h"
+#include "../rtengine/procparams.h"
+#include "paramsedited.h"
#include "mydiagonalcurve.h"
class Clipboard {
-
+
bool _hasIPTC;
- std::vector iptc;
- bool _hasProcParams;
- rtengine::procparams::ProcParams procParams;
+ rtengine::procparams::IPTCPairs iptc;
+ rtengine::procparams::PartialProfile partProfile;
DiagonalCurveType hasCurveDataType;
std::vector curve;
public:
- void setIPTC (const std::vector& iptcc) { iptc = iptcc; _hasIPTC = true;}
- const std::vector& getIPTC () { return iptc; }
+ void setIPTC (const rtengine::procparams::IPTCPairs& iptcc) { iptc = iptcc; _hasIPTC = true;}
+ const rtengine::procparams::IPTCPairs& getIPTC () { return iptc; }
bool hasIPTC () { return _hasIPTC; }
-
- void setProcParams (const rtengine::procparams::ProcParams& pparams) { procParams = pparams; _hasProcParams = true; }
- const rtengine::procparams::ProcParams& getProcParams () { return procParams; }
- bool hasProcParams () { return _hasProcParams; }
+
+ void setPartialProfile (const rtengine::procparams::PartialProfile& pprofile);
+ const rtengine::procparams::PartialProfile& getPartialProfile () { return partProfile; };
+ void setProcParams (const rtengine::procparams::ProcParams& pparams);
+ const rtengine::procparams::ProcParams& getProcParams () { return *partProfile.pparams; }
+ bool hasProcParams () { return partProfile.pparams; }
+ bool hasPEdited () { return partProfile.pedited; }
void setCurveData (std::vector& p, DiagonalCurveType type ) { curve = p; hasCurveDataType = type; return; }
const std::vector & getCurveData () { return curve; }
DiagonalCurveType hasCurveData () { return hasCurveDataType; }
+ Clipboard ();
+ ~Clipboard ();
};
diff --git a/rtgui/editorpanel.cc b/rtgui/editorpanel.cc
index 1202fd307..e194e6a76 100644
--- a/rtgui/editorpanel.cc
+++ b/rtgui/editorpanel.cc
@@ -479,7 +479,7 @@ void EditorPanel::saveProfile () {
ipc->getParams (¶ms);
// Will call updateCache, which will update both the cached and sidecar files if necessary
- openThm->setProcParams (params, EDITOR);
+ openThm->setProcParams (params, NULL, EDITOR);
}
}
@@ -592,7 +592,7 @@ void EditorPanel::refreshProcessingState (bool inProcessingP) {
if (ipc && openThm && tpc->getChangedState()) {
rtengine::procparams::ProcParams pparams;
ipc->getParams (&pparams);
- openThm->setProcParams (pparams, EDITOR, false);
+ openThm->setProcParams (pparams, NULL, EDITOR, false);
}
// Ring a sound if it was a long event
@@ -908,8 +908,13 @@ bool EditorPanel::handleShortcutKey (GdkEventKey* event) {
void EditorPanel::procParamsChanged (Thumbnail* thm, int whoChangedIt) {
- if (whoChangedIt!=EDITOR)
- tpc->profileChange (&openThm->getProcParams(), rtengine::EvProfileChangeNotification, M("PROGRESSDLG_PROFILECHANGEDINBROWSER"));
+ if (whoChangedIt!=EDITOR) {
+ PartialProfile pp(true);
+ pp.set(true);
+ *(pp.pparams) = openThm->getProcParams();
+ tpc->profileChange (&pp, rtengine::EvProfileChangeNotification, M("PROGRESSDLG_PROFILECHANGEDINBROWSER"));
+ pp.deleteInstance();
+ }
}
bool EditorPanel::idle_saveImage (ProgressConnector *pc, Glib::ustring fname, SaveFormat sf) {
diff --git a/rtgui/exifpanel.cc b/rtgui/exifpanel.cc
index b696ab641..828ef877c 100644
--- a/rtgui/exifpanel.cc
+++ b/rtgui/exifpanel.cc
@@ -512,27 +512,15 @@ void ExifPanel::updateChangeList (Gtk::TreeModel::Children root, std::string pre
if (prefix!="")
prefix = prefix + ".";
-
+
Gtk::TreeModel::iterator iter;
for (iter = root.begin(); iter!=root.end(); iter++) {
- if (iter->get_value (exifColumns.edited) == true) {
- ExifPair ec;
- ec.field = prefix + iter->get_value (exifColumns.field_nopango);
- ec.value = iter->get_value (exifColumns.value_nopango);
- changeList.push_back (ec);
- }
- else if (iter->get_value (exifColumns.action) == WRITE && iter->get_value (exifColumns.icon) == delicon) {
- ExifPair ec;
- ec.field = prefix + iter->get_value (exifColumns.field_nopango);
- ec.value = "#delete";
- changeList.push_back (ec);
- }
- else if (iter->get_value (exifColumns.action) == DONTWRITE && iter->get_value (exifColumns.icon) == keepicon) {
- ExifPair ec;
- ec.field = prefix + iter->get_value (exifColumns.field_nopango);
- ec.value = "#keep";
- changeList.push_back (ec);
- }
+ if (iter->get_value (exifColumns.edited) == true)
+ changeList[ prefix+iter->get_value (exifColumns.field_nopango) ] = iter->get_value (exifColumns.value_nopango);
+ else if (iter->get_value (exifColumns.action) == WRITE && iter->get_value (exifColumns.icon) == delicon)
+ changeList[ prefix+iter->get_value (exifColumns.field_nopango) ] = "#delete";
+ else if (iter->get_value (exifColumns.action) == DONTWRITE && iter->get_value (exifColumns.icon) == keepicon)
+ changeList[ prefix+iter->get_value (exifColumns.field_nopango) ] = "#keep";
if (iter->get_value (exifColumns.icon) == keepicon)
updateChangeList (iter->children(), prefix + iter->get_value (exifColumns.field_nopango));
}
@@ -546,8 +534,8 @@ void ExifPanel::updateChangeList () {
void ExifPanel::applyChangeList () {
- for (int i=0; ichildren(), changeList[i].field, changeList[i].value);
+ for (rtengine::procparams::ExifPairs::iterator i=changeList.begin(); i!=changeList.end(); i++)
+ editTag (exifTreeModel->children(), i->first, i->second);
}
void ExifPanel::row_activated (const Gtk::TreeModel::Path& path, Gtk::TreeViewColumn* column) {
diff --git a/rtgui/exifpanel.h b/rtgui/exifpanel.h
index eb9e10a49..5dbc3676b 100644
--- a/rtgui/exifpanel.h
+++ b/rtgui/exifpanel.h
@@ -28,8 +28,8 @@ class ExifPanel : public Gtk::VBox, public ToolPanel {
const rtengine::ImageMetaData* idata;
int fullw, fullh, cx, cy, cw, ch;
bool crenabled;
- std::vector changeList;
- std::vector defChangeList;
+ rtengine::procparams::ExifPairs changeList;
+ rtengine::procparams::ExifPairs defChangeList;
bool recursiveOp;
class ExifColumns : public Gtk::TreeModelColumnRecord {
diff --git a/rtgui/exportpanel.cc b/rtgui/exportpanel.cc
index aabf59ddc..4e060b97a 100644
--- a/rtgui/exportpanel.cc
+++ b/rtgui/exportpanel.cc
@@ -50,8 +50,8 @@ ExportPanel::ExportPanel () : listener (NULL) {
bypass_sharpening = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_SHARPENING")));
bypass_sharpenEdge = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_SHARPENEDGE")));
bypass_sharpenMicro = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_SHARPENMICRO")));
- bypass_lumaDenoise = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_LUMADENOISE")));
- bypass_colorDenoise = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_COLORDENOISE")));
+ //bypass_lumaDenoise = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_LUMADENOISE")));
+ //bypass_colorDenoise = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_COLORDENOISE")));
bypass_defringe = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_DEFRINGE")));
bypass_dirpyrDenoise = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_DIRPYRDENOISE")));
bypass_sh_hq = Gtk::manage ( new Gtk::CheckButton (M("EXPORT_BYPASS_SH_HQ")));
@@ -162,8 +162,8 @@ ExportPanel::ExportPanel () : listener (NULL) {
bypass_sharpeningConn = bypass_sharpening->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
bypass_sharpenEdgeConn = bypass_sharpenEdge->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
bypass_sharpenMicroConn = bypass_sharpenMicro->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
- bypass_lumaDenoiseConn = bypass_lumaDenoise->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
- bypass_colorDenoiseConn = bypass_colorDenoise->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
+ //bypass_lumaDenoiseConn = bypass_lumaDenoise->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
+ //bypass_colorDenoiseConn = bypass_colorDenoise->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
bypass_defringeConn = bypass_defringe->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
bypass_dirpyrDenoiseConn = bypass_dirpyrDenoise->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
bypass_sh_hqConn = bypass_sh_hq->signal_toggled().connect (sigc::bind (sigc::mem_fun(*bypass_ALL, &Gtk::CheckButton::set_inconsistent), true));
@@ -201,8 +201,8 @@ void ExportPanel::SaveSettingsAsDefault(){
options.fastexport_bypass_sharpening = bypass_sharpening->get_active ();
options.fastexport_bypass_sharpenEdge = bypass_sharpenEdge->get_active ();
options.fastexport_bypass_sharpenMicro = bypass_sharpenMicro->get_active ();
- options.fastexport_bypass_lumaDenoise = bypass_lumaDenoise->get_active ();
- options.fastexport_bypass_colorDenoise = bypass_colorDenoise->get_active ();
+ //options.fastexport_bypass_lumaDenoise = bypass_lumaDenoise->get_active ();
+ //options.fastexport_bypass_colorDenoise = bypass_colorDenoise->get_active ();
options.fastexport_bypass_defringe = bypass_defringe->get_active ();
options.fastexport_bypass_dirpyrDenoise = bypass_dirpyrDenoise->get_active ();
options.fastexport_bypass_sh_hq = bypass_sh_hq->get_active ();
@@ -254,8 +254,8 @@ void ExportPanel::LoadDefaultSettings(){
bypass_sharpening->set_active (options.fastexport_bypass_sharpening );
bypass_sharpenEdge->set_active (options.fastexport_bypass_sharpenEdge );
bypass_sharpenMicro->set_active (options.fastexport_bypass_sharpenMicro );
- bypass_lumaDenoise->set_active (options.fastexport_bypass_lumaDenoise );
- bypass_colorDenoise->set_active (options.fastexport_bypass_colorDenoise );
+ //bypass_lumaDenoise->set_active (options.fastexport_bypass_lumaDenoise );
+ //bypass_colorDenoise->set_active (options.fastexport_bypass_colorDenoise );
bypass_defringe->set_active (options.fastexport_bypass_defringe );
bypass_dirpyrDenoise->set_active (options.fastexport_bypass_dirpyrDenoise );
bypass_sh_hq->set_active (options.fastexport_bypass_sh_hq );
@@ -323,8 +323,8 @@ void ExportPanel::bypassALL_Toggled(){
bypass_sharpeningConn.block (true);
bypass_sharpenEdgeConn.block (true);
bypass_sharpenMicroConn.block (true);
- bypass_lumaDenoiseConn.block (true);
- bypass_colorDenoiseConn.block (true);
+ //bypass_lumaDenoiseConn.block (true);
+ //bypass_colorDenoiseConn.block (true);
bypass_defringeConn.block (true);
bypass_dirpyrDenoiseConn.block (true);
bypass_sh_hqConn.block (true);
@@ -344,8 +344,8 @@ void ExportPanel::bypassALL_Toggled(){
bypass_sharpening->set_active(bypass_ALL->get_active());
bypass_sharpenEdge->set_active(bypass_ALL->get_active());
bypass_sharpenMicro->set_active(bypass_ALL->get_active());
- bypass_lumaDenoise->set_active(bypass_ALL->get_active());
- bypass_colorDenoise->set_active(bypass_ALL->get_active());
+ //bypass_lumaDenoise->set_active(bypass_ALL->get_active());
+ //bypass_colorDenoise->set_active(bypass_ALL->get_active());
bypass_defringe->set_active(bypass_ALL->get_active());
bypass_dirpyrDenoise->set_active(bypass_ALL->get_active());
bypass_sh_hq->set_active(bypass_ALL->get_active());
@@ -363,8 +363,8 @@ void ExportPanel::bypassALL_Toggled(){
bypass_sharpeningConn.block (false);
bypass_sharpenEdgeConn.block (false);
bypass_sharpenMicroConn.block (false);
- bypass_lumaDenoiseConn.block (false);
- bypass_colorDenoiseConn.block (false);
+ //bypass_lumaDenoiseConn.block (false);
+ //bypass_colorDenoiseConn.block (false);
bypass_defringeConn.block (false);
bypass_dirpyrDenoiseConn.block (false);
bypass_sh_hqConn.block (false);
diff --git a/rtgui/exportpanel.h b/rtgui/exportpanel.h
index d9cd8661e..f7318967a 100644
--- a/rtgui/exportpanel.h
+++ b/rtgui/exportpanel.h
@@ -39,8 +39,8 @@ class ExportPanel : public Gtk::VBox {
Gtk::CheckButton* bypass_sharpenEdge;
Gtk::CheckButton* bypass_sharpenMicro;
Gtk::CheckButton* bypass_sharpening;
- Gtk::CheckButton* bypass_lumaDenoise;
- Gtk::CheckButton* bypass_colorDenoise;
+ //Gtk::CheckButton* bypass_lumaDenoise;
+ //Gtk::CheckButton* bypass_colorDenoise;
Gtk::CheckButton* bypass_defringe;
Gtk::CheckButton* bypass_dirpyrDenoise;
Gtk::CheckButton* bypass_sh_hq;
@@ -77,8 +77,8 @@ class ExportPanel : public Gtk::VBox {
sigc::connection bypass_sharpeningConn ;
sigc::connection bypass_sharpenEdgeConn ;
sigc::connection bypass_sharpenMicroConn ;
- sigc::connection bypass_lumaDenoiseConn ;
- sigc::connection bypass_colorDenoiseConn ;
+ //sigc::connection bypass_lumaDenoiseConn ;
+ //sigc::connection bypass_colorDenoiseConn ;
sigc::connection bypass_defringeConn ;
sigc::connection bypass_dirpyrDenoiseConn ;
sigc::connection bypass_sh_hqConn ;
diff --git a/rtgui/filebrowser.cc b/rtgui/filebrowser.cc
index 737e9004d..0c8c7a8d3 100644
--- a/rtgui/filebrowser.cc
+++ b/rtgui/filebrowser.cc
@@ -32,7 +32,7 @@
extern Options options;
FileBrowser::FileBrowser ()
- : tbl(NULL),numFiltered(0) {
+ : tbl(NULL),numFiltered(0), partialPasteDlg(M("PARTIALPASTE_DIALOGLABEL")) {
fbih = new FileBrowserIdleHelper;
fbih->fbrowser = this;
@@ -514,7 +514,7 @@ void FileBrowser::menuItemActivated (Gtk::MenuItem* m) {
rtengine::procparams::ProcParams pp=mselected[i]->thumbnail->getProcParams();
pp.raw.df_autoselect= true;
pp.raw.dark_frame.clear();
- mselected[i]->thumbnail->setProcParams(pp,FILEBROWSER,false);
+ mselected[i]->thumbnail->setProcParams(pp,NULL,FILEBROWSER,false);
}
}else if (m==selectDF){
if( !mselected.empty() ){
@@ -531,7 +531,7 @@ void FileBrowser::menuItemActivated (Gtk::MenuItem* m) {
rtengine::procparams::ProcParams pp=mselected[i]->thumbnail->getProcParams();
pp.raw.dark_frame= fc.get_filename();
pp.raw.df_autoselect= false;
- mselected[i]->thumbnail->setProcParams(pp,FILEBROWSER,false);
+ mselected[i]->thumbnail->setProcParams(pp,NULL,FILEBROWSER,false);
}
}
}
@@ -553,7 +553,7 @@ void FileBrowser::menuItemActivated (Gtk::MenuItem* m) {
rtengine::procparams::ProcParams pp=mselected[i]->thumbnail->getProcParams();
pp.raw.ff_AutoSelect= true;
pp.raw.ff_file.clear();
- mselected[i]->thumbnail->setProcParams(pp,FILEBROWSER,false);
+ mselected[i]->thumbnail->setProcParams(pp,NULL,FILEBROWSER,false);
}
}
else if (m==selectFF){
@@ -571,7 +571,7 @@ void FileBrowser::menuItemActivated (Gtk::MenuItem* m) {
rtengine::procparams::ProcParams pp=mselected[i]->thumbnail->getProcParams();
pp.raw.ff_file= fc.get_filename();
pp.raw.ff_AutoSelect= false;
- mselected[i]->thumbnail->setProcParams(pp,FILEBROWSER,false);
+ mselected[i]->thumbnail->setProcParams(pp,NULL,FILEBROWSER,false);
}
}
}
@@ -605,7 +605,7 @@ void FileBrowser::menuItemActivated (Gtk::MenuItem* m) {
// Empty run to update the thumb
rtengine::procparams::ProcParams params = mselected[i]->thumbnail->getProcParams ();
- mselected[i]->thumbnail->setProcParams (params, FILEBROWSER);
+ mselected[i]->thumbnail->setProcParams (params, NULL, FILEBROWSER);
}
} else if (m==clearFromCache) {
for (int i=0; i mselected;
- for (int i=0; i(selected[i]));
+ if (clipboard.hasProcParams()) {
+ std::vector mselected;
+ for (unsigned int i=0; i(selected[i]));
- if (!tbl || mselected.empty())
- return;
+ if (!tbl || mselected.empty())
+ return;
- for (int i=0; ithumbnail->setProcParams (clipboard.getProcParams(), FILEBROWSER);
-
- queue_draw ();
-}
+ for (unsigned int i=0; i mselected;
- for (int i=0; i(selected[i]));
-
- if (!tbl || mselected.empty())
- return;
-
- if (partialPasteDlg.run ()) {
-
- for (int i=0; ithumbnail->createProcParamsForUpdate(false,false); // this can execute customprofilebuilder to generate param file
- rtengine::procparams::ProcParams params = mselected[i]->thumbnail->getProcParams ();
- partialPasteDlg.applyPaste (¶ms, &clipboard.getProcParams());
- mselected[i]->thumbnail->setProcParams (params, FILEBROWSER);
+ // applying the PartialProfile to the thumb's ProcParams
+ mselected[i]->thumbnail->setProcParams (*pastedPartProf.pparams, pastedPartProf.pedited, FILEBROWSER);
+ pastedPartProf.deleteInstance();
}
queue_draw ();
}
- partialPasteDlg.hide ();
+}
+
+void FileBrowser::partPasteProfile () {
+
+ if (clipboard.hasProcParams()) {
+
+ std::vector mselected;
+ for (unsigned int i=0; i(selected[i]));
+
+ if (!tbl || mselected.empty())
+ return;
+
+ int i = partialPasteDlg.run ();
+ if (i == Gtk::RESPONSE_OK) {
+
+ for (unsigned int i=0; ithumbnail->createProcParamsForUpdate(false,false); // this can execute customprofilebuilder to generate param file
+ rtengine::procparams::PartialProfile cbPartProf = clipboard.getPartialProfile();
+ rtengine::procparams::PartialProfile pastedPartProf(&mselected[i]->thumbnail->getProcParams (), NULL);
+
+ // pushing the selected values of the clipboard PartialProfile to the temporary PartialProfile
+ partialPasteDlg.applyPaste (pastedPartProf.pparams, pastedPartProf.pedited, cbPartProf.pparams, cbPartProf.pedited);
+
+ // applying the temporary PartialProfile to the thumb's ProcParams
+ mselected[i]->thumbnail->setProcParams (*pastedPartProf.pparams, pastedPartProf.pedited, FILEBROWSER);
+ pastedPartProf.deleteInstance();
+ }
+
+ queue_draw ();
+ }
+ partialPasteDlg.hide ();
+ }
}
void FileBrowser::openDefaultViewer (int destination) {
@@ -726,10 +746,10 @@ bool FileBrowser::keyPressed (GdkEventKey* event) {
void FileBrowser::applyMenuItemActivated (Glib::ustring ppname) {
- rtengine::procparams::ProcParams* pparams = profileStore.getProfile (ppname);
- if (pparams && !selected.empty()) {
- for (int i=0; i(selected[i]))->thumbnail->setProcParams (*pparams, FILEBROWSER);
+ rtengine::procparams::PartialProfile* partProfile = profileStore.getProfile (ppname);
+ if (partProfile->pparams && !selected.empty()) {
+ for (int i=0; i(selected[i]))->thumbnail->setProcParams (*partProfile->pparams, partProfile->pedited, FILEBROWSER);
queue_draw ();
}
}
@@ -739,17 +759,20 @@ void FileBrowser::applyPartialMenuItemActivated (Glib::ustring ppname) {
if (!tbl || selected.empty())
return;
- rtengine::procparams::ProcParams* pparams = profileStore.getProfile (ppname);
+ rtengine::procparams::PartialProfile* srcProfiles = profileStore.getProfile (ppname);
- if (pparams) {
- if (partialPasteDlg.run ()) {
+ if (srcProfiles->pparams) {
+ if (partialPasteDlg.run()==Gtk::RESPONSE_OK) {
for (int i=0; ithumbnail->createProcParamsForUpdate(false, false); // this can execute customprofilebuilder to generate param file
+ selected[i]->thumbnail->createProcParamsForUpdate(false, false); // this can execute customprofilebuilder to generate param file
- rtengine::procparams::ProcParams params = (static_cast(selected[i]))->thumbnail->getProcParams ();
- partialPasteDlg.applyPaste (¶ms, pparams);
- (static_cast(selected[i]))->thumbnail->setProcParams (params, FILEBROWSER);
+ rtengine::procparams::PartialProfile dstProfile(true);
+ *dstProfile.pparams = (static_cast(selected[i]))->thumbnail->getProcParams ();
+ dstProfile.set(true);
+ partialPasteDlg.applyPaste (dstProfile.pparams, dstProfile.pedited, srcProfiles->pparams, srcProfiles->pedited);
+ (static_cast(selected[i]))->thumbnail->setProcParams (*dstProfile.pparams, dstProfile.pedited, FILEBROWSER);
+ dstProfile.deleteInstance();
}
queue_draw ();
}
diff --git a/rtgui/filebrowser.h b/rtgui/filebrowser.h
index cdd38d499..6aba267cd 100644
--- a/rtgui/filebrowser.h
+++ b/rtgui/filebrowser.h
@@ -102,8 +102,8 @@ class FileBrowser : public ThumbBrowserBase,
FileBrowserListener* tbl;
BrowserFilter filter;
- PartialPasteDlg partialPasteDlg;
int numFiltered;
+ PartialPasteDlg partialPasteDlg;
FileBrowserIdleHelper* fbih;
void toTrashRequested (std::vector tbe);
diff --git a/rtgui/filecatalog.cc b/rtgui/filecatalog.cc
index 1dd9c3b78..75bb63d5a 100644
--- a/rtgui/filecatalog.cc
+++ b/rtgui/filecatalog.cc
@@ -867,8 +867,8 @@ void FileCatalog::developRequested (std::vector tbe, bool fas
if (options.fastexport_bypass_sharpening ) params.sharpening.enabled = false;
if (options.fastexport_bypass_sharpenEdge ) params.sharpenEdge.enabled = false;
if (options.fastexport_bypass_sharpenMicro ) params.sharpenMicro.enabled = false;
- if (options.fastexport_bypass_lumaDenoise ) params.lumaDenoise.enabled = false;
- if (options.fastexport_bypass_colorDenoise ) params.colorDenoise.enabled = false;
+ //if (options.fastexport_bypass_lumaDenoise ) params.lumaDenoise.enabled = false;
+ //if (options.fastexport_bypass_colorDenoise ) params.colorDenoise.enabled = false;
if (options.fastexport_bypass_defringe ) params.defringe.enabled = false;
if (options.fastexport_bypass_dirpyrDenoise ) params.dirpyrDenoise.enabled = false;
if (options.fastexport_bypass_sh_hq ) params.sh.hq = false;
diff --git a/rtgui/history.cc b/rtgui/history.cc
index 920d5dd7a..e9212c3e6 100644
--- a/rtgui/history.cc
+++ b/rtgui/history.cc
@@ -144,9 +144,12 @@ void History::historySelectionChanged () {
if (row)
bTreeView->get_selection()->unselect_all ();
if (row && tpc) {
- ProcParams params = row[historyColumns.params];
+ ProcParams pparams = row[historyColumns.params];
+ ParamsEdited pe;
+ pe.set(true);
+ PartialProfile pp(&pparams, &pe);
ParamsEdited paramsEdited = row[historyColumns.paramsEdited];
- tpc->profileChange (¶ms, EvHistoryBrowsed, row[historyColumns.text], ¶msEdited);
+ tpc->profileChange (&pp, EvHistoryBrowsed, row[historyColumns.text], ¶msEdited);
}
if (blistener && blistenerLock==false) {
Gtk::TreeModel::Path path = historyModel->get_path (iter);
@@ -167,9 +170,12 @@ void History::bookmarkSelectionChanged () {
if (row)
hTreeView->get_selection()->unselect_all ();
if (row && tpc) {
- ProcParams params = row[bookmarkColumns.params];
+ ProcParams pparams = row[bookmarkColumns.params];
+ ParamsEdited pe;
+ pe.set(true);
+ PartialProfile pp(&pparams, &pe);
ParamsEdited paramsEdited = row[bookmarkColumns.paramsEdited];
- tpc->profileChange (¶ms, EvBookmarkSelected, row[bookmarkColumns.text], ¶msEdited);
+ tpc->profileChange (&pp, EvBookmarkSelected, row[bookmarkColumns.text], ¶msEdited);
}
}
}
@@ -201,7 +207,7 @@ void History::procParamsChanged (ProcParams* params, ProcEvent ev, Glib::ustring
if (size>0)
row = historyModel->children()[size-1];
// if there is no last item or its chev!=ev, create a new one
- if (size==0 || !row || row[historyColumns.chev]!=ev) {
+ if (size==0 || !row || row[historyColumns.chev]!=ev || ev==EvProfileChanged) {
Gtk::TreeModel::Row newrow = *(historyModel->append());
newrow[historyColumns.realText] = eventDescrArray[ev];
newrow[historyColumns.text] = text;
diff --git a/rtgui/iptcpanel.cc b/rtgui/iptcpanel.cc
index b0d592006..4a0c216c0 100644
--- a/rtgui/iptcpanel.cc
+++ b/rtgui/iptcpanel.cc
@@ -339,6 +339,7 @@ IPTCPanel::IPTCPanel () {
void IPTCPanel::read (const ProcParams* pp, const ParamsEdited* pedited) {
disableListener ();
+ changeList.clear();
if (!pp->iptc.empty())
changeList = pp->iptc;
else
@@ -377,7 +378,7 @@ void IPTCPanel::addKeyWord () {
keyword->get_entry()->select_region (0, keyword->get_entry()->get_text().size());
- for (int i=0; isize(); i++)
+ for (unsigned int i=0; isize(); i++)
if (keywords->get_text (i) == keyword->get_entry()->get_text())
return;
@@ -390,7 +391,7 @@ void IPTCPanel::addKeyWord () {
items.push_back (s);
}
keyword->clear_items ();
- for (int i=0; i<10 && iappend_text (items[i]);
keywords->scroll_to_row (keywords->get_model()->get_path(--keywords->get_model()->children().end()));
@@ -402,11 +403,11 @@ void IPTCPanel::delKeyWord () {
std::vector selection = keywords->get_selected ();
if (!selection.empty()) {
std::vector keep;
- for (int i=0; isize(); i++)
+ for (unsigned int i=0; isize(); i++)
if (std::find (selection.begin(), selection.end(), i) == selection.end())
keep.push_back (keywords->get_text (i));
keywords->clear_items ();
- for (int i=0; iappend_text (keep[i]);
}
@@ -415,7 +416,7 @@ void IPTCPanel::delKeyWord () {
void IPTCPanel::addSuppCategory () {
- for (int i=0; isize(); i++)
+ for (unsigned int i=0; isize(); i++)
if (suppCategories->get_text (i) == suppCategory->get_entry()->get_text())
return;
@@ -428,7 +429,7 @@ void IPTCPanel::addSuppCategory () {
items.push_back (s);
}
suppCategory->clear_items ();
- for (int i=0; i<10 && iappend_text (items[i]);
suppCategories->scroll_to_row (suppCategories->get_model()->get_path(--suppCategories->get_model()->children().end()));
suppCategory->get_entry()->select_region (0, suppCategory->get_entry()->get_text().size());
@@ -441,11 +442,11 @@ void IPTCPanel::delSuppCategory () {
std::vector selection = suppCategories->get_selected ();
if (!selection.empty()) {
std::vector keep;
- for (int i=0; isize(); i++)
+ for (unsigned int i=0; isize(); i++)
if (std::find (selection.begin(), selection.end(), i) == selection.end())
keep.push_back (suppCategories->get_text (i));
suppCategories->clear_items ();
- for (int i=0; iappend_text (keep[i]);
}
@@ -455,45 +456,30 @@ void IPTCPanel::delSuppCategory () {
void IPTCPanel::updateChangeList () {
changeList.clear ();
- changeList.resize (18);
- changeList[0].field = "Caption";
- changeList[0].values.push_back (captionText->get_text ());
- changeList[1].field = "CaptionWriter";
- changeList[1].values.push_back (captionWriter->get_text ());
- changeList[2].field = "Headline";
- changeList[2].values.push_back (headline->get_text ());
- changeList[3].field = "Instructions";
- changeList[3].values.push_back (instructions->get_text ());
- changeList[4].field = "Keywords";
- for (int i=0; isize(); i++)
- changeList[4].values.push_back (keywords->get_text (i));
- changeList[5].field = "Category";
- changeList[5].values.push_back (category->get_entry()->get_text ());
- changeList[6].field = "SupplementalCategories";
- for (int i=0; isize(); i++)
- changeList[6].values.push_back (suppCategories->get_text (i));
- changeList[7].field = "Author";
- changeList[7].values.push_back (author->get_text ());
- changeList[8].field = "AuthorsPosition";
- changeList[8].values.push_back (authorPos->get_text ());
- changeList[9].field = "Credit";
- changeList[9].values.push_back (credit->get_text ());
- changeList[10].field = "Source";
- changeList[10].values.push_back (source->get_text ());
- changeList[11].field = "Copyright";
- changeList[11].values.push_back (copyright->get_text ());
- changeList[12].field = "City";
- changeList[12].values.push_back (city->get_text ());
- changeList[13].field = "Province";
- changeList[13].values.push_back (province->get_text ());
- changeList[14].field = "Country";
- changeList[14].values.push_back (country->get_text ());
- changeList[15].field = "Title";
- changeList[15].values.push_back (title->get_text ());
- changeList[16].field = "DateCreated";
- changeList[16].values.push_back (dateCreated->get_text ());
- changeList[17].field = "TransReference";
- changeList[17].values.push_back (transReference->get_text ());
+ changeList["Caption" ].push_back (captionText->get_text ());
+ changeList["CaptionWriter" ].push_back (captionWriter->get_text ());
+ changeList["Headline" ].push_back (headline->get_text ());
+ changeList["Instructions" ].push_back (instructions->get_text ());
+
+ for (unsigned int i=0; isize(); i++)
+ changeList["Keywords" ].push_back (keywords->get_text (i));
+
+ changeList["Category" ].push_back (category->get_entry()->get_text ());
+
+ for (unsigned int i=0; isize(); i++)
+ changeList["SupplementalCategories"].push_back (suppCategories->get_text (i));
+
+ changeList["Author" ].push_back (author->get_text ());
+ changeList["AuthorsPosition"].push_back (authorPos->get_text ());
+ changeList["Credit" ].push_back (credit->get_text ());
+ changeList["Source" ].push_back (source->get_text ());
+ changeList["Copyright" ].push_back (copyright->get_text ());
+ changeList["City" ].push_back (city->get_text ());
+ changeList["Province" ].push_back (province->get_text ());
+ changeList["Country" ].push_back (country->get_text ());
+ changeList["Title" ].push_back (title->get_text ());
+ changeList["DateCreated" ].push_back (dateCreated->get_text ());
+ changeList["TransReference" ].push_back (transReference->get_text ());
notifyListener ();
}
@@ -524,45 +510,47 @@ void IPTCPanel::applyChangeList () {
keyword->get_entry()->set_text ("");
suppCategory->get_entry()->set_text ("");
- for (int i=0; iset_text (changeList[i].values[0]);
- else if (changeList[i].field == "CaptionWriter" && !changeList[i].values.empty())
- captionWriter->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Headline" && !changeList[i].values.empty())
- headline->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Instructions" && !changeList[i].values.empty())
- instructions->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Keywords")
- for (int j=0; jappend_text (changeList[i].values[j]);
- else if (changeList[i].field == "Category" && !changeList[i].values.empty())
- category->get_entry()->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "SupplementalCategories")
- for (int j=0; jappend_text (changeList[i].values[j]);
- else if (changeList[i].field == "Author" && !changeList[i].values.empty())
- author->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "AuthorsPosition" && !changeList[i].values.empty())
- authorPos->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Credit" && !changeList[i].values.empty())
- credit->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Source" && !changeList[i].values.empty())
- source->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Copyright" && !changeList[i].values.empty())
- copyright->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "City" && !changeList[i].values.empty())
- city->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Province" && !changeList[i].values.empty())
- province->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Country" && !changeList[i].values.empty())
- country->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "Title" && !changeList[i].values.empty())
- title->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "DateCreated" && !changeList[i].values.empty())
- dateCreated->set_text (changeList[i].values[0]);
- else if (changeList[i].field == "TransReference" && !changeList[i].values.empty())
- transReference->set_text (changeList[i].values[0]);
+ for (rtengine::procparams::IPTCPairs::iterator i=changeList.begin(); i!=changeList.end(); i++) {
+ printf("- %s: %s\n", i->first.c_str(), i->second.empty()?"[vide]":i->second.at(0).c_str());
+ if (i->first == "Caption" && !i->second.empty())
+ captionText->set_text (i->second.at(0));
+ else if (i->first == "CaptionWriter" && !i->second.empty())
+ captionWriter->set_text (i->second.at(0));
+ else if (i->first == "Headline" && !i->second.empty())
+ headline->set_text (i->second.at(0));
+ else if (i->first == "Instructions" && !i->second.empty())
+ instructions->set_text (i->second.at(0));
+ else if (i->first == "Keywords")
+ for (unsigned int j=0; jsecond.size(); j++)
+ keywords->append_text (i->second.at(j));
+ else if (i->first == "Category" && !i->second.empty())
+ category->get_entry()->set_text (i->second.at(0));
+ else if (i->first == "SupplementalCategories")
+ for (unsigned int j=0; jsecond.size(); j++)
+ suppCategories->append_text (i->second.at(j));
+ else if (i->first == "Author" && !i->second.empty())
+ author->set_text (i->second.at(0));
+ else if (i->first == "AuthorsPosition" && !i->second.empty())
+ authorPos->set_text (i->second.at(0));
+ else if (i->first == "Credit" && !i->second.empty())
+ credit->set_text (i->second.at(0));
+ else if (i->first == "Source" && !i->second.empty())
+ source->set_text (i->second.at(0));
+ else if (i->first == "Copyright" && !i->second.empty())
+ copyright->set_text (i->second.at(0));
+ else if (i->first == "City" && !i->second.empty())
+ city->set_text (i->second.at(0));
+ else if (i->first == "Province" && !i->second.empty())
+ province->set_text (i->second.at(0));
+ else if (i->first == "Country" && !i->second.empty())
+ country->set_text (i->second.at(0));
+ else if (i->first == "Title" && !i->second.empty())
+ title->set_text (i->second.at(0));
+ else if (i->first == "DateCreated" && !i->second.empty())
+ dateCreated->set_text (i->second.at(0));
+ else if (i->first == "TransReference" && !i->second.empty())
+ transReference->set_text (i->second.at(0));
+}
for (int i=0; i<16; i++)
conns[i].block (false);
diff --git a/rtgui/iptcpanel.h b/rtgui/iptcpanel.h
index 3c97b91d1..128bf3018 100644
--- a/rtgui/iptcpanel.h
+++ b/rtgui/iptcpanel.h
@@ -26,9 +26,9 @@
class IPTCPanel : public Gtk::VBox, public ToolPanel {
private:
- std::vector changeList;
- std::vector defChangeList;
- std::vector embeddedData;
+ rtengine::procparams::IPTCPairs changeList;
+ rtengine::procparams::IPTCPairs defChangeList;
+ rtengine::procparams::IPTCPairs embeddedData;
Gtk::TextView* captionView;
Glib::RefPtr captionText;
diff --git a/rtgui/main.cc b/rtgui/main.cc
index c8a081b1d..f8c0838cc 100644
--- a/rtgui/main.cc
+++ b/rtgui/main.cc
@@ -58,7 +58,8 @@ bool simpleEditor;
* 1 to start GUI (with a dir or file option)
* 2 to start GUI because no files found
* -1 if there is an error in parameters
- * -2 if an error occurred during processing */
+ * -2 if an error occurred during processing
+ * -3 if at least one required procparam file was not found */
int processLineParams( int argc, char **argv );
int main(int argc, char **argv)
@@ -164,24 +165,36 @@ int main(int argc, char **argv)
return 0;
}
+void deleteProcParams(std::vector &pparams) {
+ for (unsigned int i=0; ideleteInstance();
+ delete pparams[i];
+ pparams[i] = NULL;
+ }
+ return;
+}
+
int processLineParams( int argc, char **argv )
{
+ rtengine::procparams::PartialProfile *rawParams=NULL, *imgParams=NULL;
std::vector inputFiles;
Glib::ustring outputPath = "";
- Glib::ustring processingParams = "";
+ std::vector processingParams;
bool isDirectory=false;
bool outputDirectory=false;
bool overwriteFiles=false;
bool sideProcParams=false;
bool copyParamsFile=false;
- bool useDefaultIfAbsent=true;
+ bool skipIfNoSidecar=false;
+ bool useDefault=false;
+ unsigned int sideCarFilePos = 0;
int compression=100;
int bits=-1;
std::string outputType = "";
unsigned errors=0;
for( int iArg=1; iArgload ( fname ))) {
+ processingParams.push_back(currentParams);
+ }
+ else {
+ std::cerr << "Error: \""<< fname <<"\" not found" << std::endl;
+ deleteProcParams(processingParams);
+ return -3;
+ }
}
break;
case 'S':
- useDefaultIfAbsent=false;
- case 's': // Processing params next to file (.pp3 appended)
+ skipIfNoSidecar=true;
+ case 's': // Processing params next to file (file extension appended)
sideProcParams = true;
+ sideCarFilePos = processingParams.size();
+ break;
+ case 'd':
+ useDefault = true;
break;
case 'Y':
overwriteFiles =true;
@@ -232,7 +264,7 @@ int processLineParams( int argc, char **argv )
safe_build_file_list (dir, names, argv[iArg] );
for(size_t iFile=0; iFile< names.size(); iFile++ ){
if( !safe_file_test( names[iFile] , Glib::FILE_TEST_IS_DIR)){
- // skip files without extension and pp3 files
+ // skip files without extension and without sidecar files
Glib::ustring s(names[iFile]);
Glib::ustring::size_type ext= s.find_last_of('.');
if( Glib::ustring::npos == ext )
@@ -250,27 +282,41 @@ int processLineParams( int argc, char **argv )
case 'h':
case '?':
default:
- std::cerr << "RawTherapee, " << VERSION << std::endl;
- std::cerr << "Copyright (c)2004-2011 Gabor Horvath "<< std::endl << std::endl;
+ {
+ Glib::ustring pparamsExt = paramFileExtension.substr(1);
+ std::cerr << "RawTherapee, V" << VERSION << std::endl;
+ std::cerr << "Copyright (c)2004-2012 Gabor Horvath "<< std::endl << std::endl;
std::cerr << "Usage:"<< std::endl;
std::cerr << Glib::path_get_basename(argv[0]) << " [] : start RT GUI browser inside dir."<< std::endl;
std::cerr << Glib::path_get_basename(argv[0]) << " : start GUI editor with file."<< std::endl;
std::cerr << Glib::path_get_basename(argv[0]) << " -c | : convert files in batch with default parameters."<< std::endl<< std::endl;
std::cerr << "Other options used with -c (that must be last option) "<< std::endl;
- std::cerr << Glib::path_get_basename(argv[0]) <<" [-o