6package org.mozilla.gecko.util;
8import android.graphics.PointF;
14 return (
Math.abs(
a - b) < 1e-6);
26 public static float interpolate(
float from,
float to,
float t) {
34 public static float clamp(
float value,
float low,
float high) {
36 throw new IllegalArgumentException(
37 "clamp called with invalid parameters (" + high +
" < " + low +
")" );
static float interpolate(float from, float to, float t)
static float clamp(float value, float low, float high)
Returns 'value', clamped so that it isn't any lower than 'low', and it isn't any higher than 'high'.
static boolean fuzzyEquals(float a, float b)
static boolean fuzzyEquals(PointF a, PointF b)