|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectca.sqlpower.wabit.swingui.chart.effect.interp.LinearInterpolator
@Immutable public class LinearInterpolator
Simple implementation of a linear interpolator. Produces the same results as
a PolynomialInterpolator with a degree of 1.
| Constructor Summary | |
|---|---|
LinearInterpolator()
|
|
| Method Summary | |
|---|---|
double |
value(double start,
double end,
double pct)
Calculates and returns an interpolated value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LinearInterpolator()
| Method Detail |
|---|
public double value(double start,
double end,
double pct)
Interpolator
value in interface Interpolatorstart - The value that will be returned when pct == 0.0end - The value that will be returned when pct == 1.0pct - A value between 0.0 and 1.0 that indicates how far
"along the way" the interpolated value should be. Values
outside the range 0.0..1.0 produce undefined results.
pct=0.0, the
value of start is returned. When
pct=1.0, the value of end is returned.
For values of pct between 0.0 and 1.0, the returned
value is calculated according to the particular Interpolator in
use. In general, it is not guaranteed to lie between
start and end (some interpolators may
"overshoot" either endpoint then come back to it).
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||