diff options
Diffstat (limited to 'src/main/curve.c')
-rw-r--r-- | src/main/curve.c | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/main/curve.c b/src/main/curve.c index feaff48..7e4d02b 100644 --- a/src/main/curve.c +++ b/src/main/curve.c @@ -1,5 +1,5 @@ /* - * "$Id: curve.c,v 1.55 2010/08/04 00:33:56 rlk Exp $" + * "$Id: curve.c,v 1.56 2014/01/04 00:31:37 rlk Exp $" * * Print plug-in driver utility functions for the GIMP. * @@ -908,7 +908,6 @@ int stp_curve_rescale(stp_curve_t *curve, double scale, stp_curve_compose_t mode, stp_curve_bounds_t bounds_mode) { - size_t real_point_count; int i; double nblo; double nbhi; @@ -916,8 +915,6 @@ stp_curve_rescale(stp_curve_t *curve, double scale, CHECK_CURVE(curve); - real_point_count = get_real_point_count(curve); - stp_sequence_get_bounds(curve->seq, &nblo, &nbhi); if (bounds_mode == STP_CURVE_BOUNDS_RESCALE) { @@ -1068,7 +1065,7 @@ do_interpolate_spline(double low, double high, double frac, } static inline double -interpolate_point_internal(stp_curve_t *curve, double where) +interpolate_point_internal(const stp_curve_t *curve, double where) { int integer = where; double frac = where - (double) integer; @@ -1082,7 +1079,7 @@ interpolate_point_internal(stp_curve_t *curve, double where) return val; } if (curve->recompute_interval) - compute_intervals(curve); + compute_intervals((stpi_cast_safe(curve))); if (curve->curve_type == STP_CURVE_TYPE_LINEAR) { double val; @@ -1136,7 +1133,7 @@ stp_curve_interpolate_value(const stp_curve_t *curve, double where, if (curve->gamma) /* this means a pure gamma curve */ *result = interpolate_gamma_internal(curve, where); else - *result = interpolate_point_internal((stp_curve_t *) curve, where); + *result = interpolate_point_internal(curve, where); return 1; } |