mirror of https://github.com/GNOME/gimp.git
app: maintain common settings when editing Brightness-Contrast/Levels as Levels/Curves
When converting Brightness-Contrast to Levels, and Levels to Curves, make sure to copy the common settings as well as the operation-specific settings.
This commit is contained in:
parent
88689515ab
commit
987447f18f
|
@ -181,6 +181,10 @@ gimp_brightness_contrast_config_to_levels_config (GimpBrightnessContrastConfig *
|
|||
|
||||
levels = g_object_new (GIMP_TYPE_LEVELS_CONFIG, NULL);
|
||||
|
||||
gimp_operation_settings_config_copy_base (GIMP_CONFIG (config),
|
||||
GIMP_CONFIG (levels),
|
||||
0);
|
||||
|
||||
brightness = config->brightness / 2.0;
|
||||
slant = tan ((config->contrast + 1) * G_PI_4);
|
||||
|
||||
|
|
|
@ -714,6 +714,10 @@ gimp_levels_config_to_curves_config (GimpLevelsConfig *config)
|
|||
|
||||
curves = g_object_new (GIMP_TYPE_CURVES_CONFIG, NULL);
|
||||
|
||||
gimp_operation_settings_config_copy_base (GIMP_CONFIG (config),
|
||||
GIMP_CONFIG (curves),
|
||||
0);
|
||||
|
||||
curves->trc = config->trc;
|
||||
|
||||
for (channel = GIMP_HISTOGRAM_VALUE;
|
||||
|
|
Loading…
Reference in New Issue