app: remove the legacy threshold lut code

This commit is contained in:
Michael Natterer
2012-03-15 11:24:33 +01:00
parent 70e5542077
commit d0d50ca1ea
2 changed files with 0 additions and 43 deletions

View File

@ -89,46 +89,6 @@ brightness_contrast_lut_new (gdouble brightness,
return lut;
}
/* ---------------- Threshold ------------------ */
static gfloat
threshold_lut_func (gdouble *min,
gint n_channels,
gint channel,
gfloat value)
{
/* don't change the alpha channel */
if ((n_channels == 2 || n_channels == 4) && channel == n_channels -1)
return value;
if (value < *min)
return 0.0;
return 1.0;
}
static void
threshold_lut_setup (GimpLut *lut,
gdouble value,
gint n_channels)
{
g_return_if_fail (lut != NULL);
gimp_lut_setup_exact (lut,
(GimpLutFunc) threshold_lut_func, &value, n_channels);
}
GimpLut *
threshold_lut_new (gdouble value,
gint n_channels)
{
GimpLut *lut = gimp_lut_new ();
threshold_lut_setup (lut, value, n_channels);
return lut;
}
/* --------------- equalize ------------- */
typedef struct