Skip to content

Commit efbb911

Browse files
committed
demosaic: Fix some strings.
1 parent 6c5eacc commit efbb911

File tree

2 files changed

+16
-16
lines changed

2 files changed

+16
-16
lines changed

src/iop/demosaic.c

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,7 @@ typedef struct dt_iop_demosaic_params_t
120120
float cs_thrs; // $MIN: 0.0 $MAX: 1.0 $DEFAULT: 0.40 $DESCRIPTION: "edge sensitivity"
121121
float cs_boost; // $MIN: 0.0 $MAX: 1.5 $DEFAULT: 0.0 $DESCRIPTION: "corner boost"
122122
int cs_iter; // $MIN: 0 $MAX: 25 $DEFAULT: 0 $DESCRIPTION: "sharpen"
123-
float cs_centre; // $MIN: 0.0 $MAX: 1.0 $DEFAULT: 0.0 $DESCRIPTION: "sharp centre"
123+
float cs_center; // $MIN: 0.0 $MAX: 1.0 $DEFAULT: 0.0 $DESCRIPTION: "sharp center"
124124
} dt_iop_demosaic_params_t;
125125

126126
typedef struct dt_iop_demosaic_gui_data_t
@@ -137,7 +137,7 @@ typedef struct dt_iop_demosaic_gui_data_t
137137
GtkWidget *cs_radius;
138138
GtkWidget *cs_boost;
139139
GtkWidget *cs_iter;
140-
GtkWidget *cs_centre;
140+
GtkWidget *cs_center;
141141
dt_gui_collapsible_section_t capture;
142142
gboolean cs_mask;
143143
gboolean dual_mask;
@@ -222,7 +222,7 @@ typedef struct dt_iop_demosaic_data_t
222222
float cs_thrs;
223223
float cs_boost;
224224
int cs_iter;
225-
float cs_centre;
225+
float cs_center;
226226
} dt_iop_demosaic_data_t;
227227

228228
static gboolean _get_thumb_quality(const int width, const int height)
@@ -320,7 +320,7 @@ int legacy_params(dt_iop_module_t *self,
320320
float cs_thrs;
321321
float cs_boost;
322322
int cs_iter;
323-
float cs_centre;
323+
float cs_center;
324324
} dt_iop_demosaic_params_v5_t;
325325

326326
typedef struct dt_iop_demosaic_params_v4_t
@@ -387,7 +387,7 @@ int legacy_params(dt_iop_module_t *self,
387387
n->cs_thrs = 0.4f;
388388
n->cs_boost = 0.0f;
389389
n->cs_iter = 0;
390-
n->cs_centre = 0.0f;
390+
n->cs_center = 0.0f;
391391

392392
*new_params = n;
393393
*new_params_size = sizeof(dt_iop_demosaic_params_v5_t);
@@ -1103,7 +1103,7 @@ void commit_params(dt_iop_module_t *self,
11031103
d->cs_radius = p->cs_radius;
11041104
d->cs_thrs = p->cs_thrs;
11051105
d->cs_boost = p->cs_boost;
1106-
d->cs_centre = p->cs_centre;
1106+
d->cs_center = p->cs_center;
11071107
// magic function to have CS iterations with fine granularity for values <= 11 and then rising up to 50
11081108
d->cs_iter = p->cs_iter + (int)(0.000065f * powf((float)p->cs_iter, 4.0f));
11091109
const gboolean xmethod = use_method & DT_DEMOSAIC_XTRANS;
@@ -1291,7 +1291,7 @@ void gui_changed(dt_iop_module_t *self, GtkWidget *w, void *previous)
12911291
gtk_widget_set_sensitive(g->cs_radius, do_capture);
12921292
gtk_widget_set_sensitive(g->cs_thrs, do_capture);
12931293
gtk_widget_set_sensitive(g->cs_boost, do_capture);
1294-
gtk_widget_set_sensitive(g->cs_centre, do_capture && p->cs_boost);
1294+
gtk_widget_set_sensitive(g->cs_center, do_capture && p->cs_boost);
12951295
gtk_widget_set_sensitive(g->cs_iter, capture_support);
12961296

12971297
// we might have a wrong method dur to xtrans/bayer - mode mismatch
@@ -1487,9 +1487,9 @@ void gui_init(dt_iop_module_t *self)
14871487
g->cs_radius = dt_bauhaus_slider_from_params(self, "cs_radius");
14881488
dt_bauhaus_slider_set_digits(g->cs_radius, 2);
14891489
dt_bauhaus_slider_set_format(g->cs_radius, _(_(" px")));
1490-
gtk_widget_set_tooltip_text(g->cs_radius, _("capture sharpen radius should reflect the overall gaussian type blur"
1490+
gtk_widget_set_tooltip_text(g->cs_radius, _("capture sharpen radius should reflect the overall gaussian type blur\n"
14911491
"of the camera sensor, possibly the anti-aliasing filter and the lens.\n"
1492-
"increasing this too far will soon lead to artifacts like halos and"
1492+
"increasing this too far will soon lead to artifacts like halos and\n"
14931493
"ringing especially when used with a large 'sharpen' setting\n"));
14941494
dt_bauhaus_slider_set_hard_min(g->cs_radius, 0.01f);
14951495
dt_bauhaus_widget_set_quad(g->cs_radius, self, dtgtk_cairo_paint_reset, FALSE, _cs_autoradius_callback,
@@ -1507,13 +1507,13 @@ void gui_init(dt_iop_module_t *self)
15071507
dt_bauhaus_slider_set_digits(g->cs_boost, 2);
15081508
dt_bauhaus_slider_set_format(g->cs_boost, _(_(" px")));
15091509
gtk_widget_set_tooltip_text(g->cs_boost, _("further increase sharpen radius at image corners,\n"
1510-
"the sharp centre of the image will not be affected"));
1510+
"the sharp center of the image will not be affected"));
15111511
dt_bauhaus_widget_set_quad(g->cs_boost, self, dtgtk_cairo_paint_showmask, TRUE, _cs_boost_callback, _("visualize the overall radius"));
15121512

1513-
g->cs_centre = dt_bauhaus_slider_from_params(self, "cs_centre");
1514-
dt_bauhaus_slider_set_format(g->cs_centre, "%");
1515-
dt_bauhaus_slider_set_digits(g->cs_centre, 0);
1516-
gtk_widget_set_tooltip_text(g->cs_centre, _("adjust to the sharp image centre"));
1513+
g->cs_center = dt_bauhaus_slider_from_params(self, "cs_center");
1514+
dt_bauhaus_slider_set_format(g->cs_center, "%");
1515+
dt_bauhaus_slider_set_digits(g->cs_center, 0);
1516+
gtk_widget_set_tooltip_text(g->cs_center, _("adjust to the sharp image center"));
15171517

15181518
// start building top level widget
15191519
self->widget = gtk_stack_new();

src/iop/demosaicing/capture.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -638,7 +638,7 @@ void _capture_sharpen(dt_iop_module_t *self,
638638
goto finalize;
639639
}
640640

641-
gauss_idx = _cs_precalc_gauss_idx(self, roi, radius, d->cs_boost, d->cs_centre);
641+
gauss_idx = _cs_precalc_gauss_idx(self, roi, radius, d->cs_boost, d->cs_center);
642642
if(!gauss_idx) goto finalize;
643643

644644
if(show_sigma_mask)
@@ -803,7 +803,7 @@ int _capture_sharpen_cl(dt_iop_module_t *self,
803803
goto finish;
804804
}
805805

806-
unsigned char *f_gauss_idx = _cs_precalc_gauss_idx(self, roi, radius, d->cs_boost, d->cs_centre);
806+
unsigned char *f_gauss_idx = _cs_precalc_gauss_idx(self, roi, radius, d->cs_boost, d->cs_center);
807807
if(f_gauss_idx)
808808
{
809809
gcoeffs = dt_opencl_copy_host_to_device_constant(devid, sizeof(float) * (UCHAR_MAX+1) * CAPTURE_KERNEL_ALIGN, gd->gauss_coeffs);

0 commit comments

Comments
 (0)