Package com.jhlabs.image
Class SplineColormap
- java.lang.Object
-
- com.jhlabs.image.ArrayColormap
-
- com.jhlabs.image.SplineColormap
-
- All Implemented Interfaces:
Colormap,java.io.Serializable,java.lang.Cloneable
public class SplineColormap extends ArrayColormap implements java.io.Serializable
A Colormap implemented using Catmull-Rom colour splines. The map has a variable number of knots with a minimum of four. The first and last knots give the tangent at the end of the spline, and colours are interpolated from the second to the second-last knots.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description intnumKnotsint[]xKnotsint[]yKnots-
Fields inherited from class com.jhlabs.image.ArrayColormap
map
-
-
Constructor Summary
Constructors Constructor Description SplineColormap()SplineColormap(int[] xKnots, int[] yKnots)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddKnot(int x, int color)intgetKnot(int n)voidremoveKnot(int n)voidsetKnot(int n, int color)voidsetKnotPosition(int n, int x)-
Methods inherited from class com.jhlabs.image.ArrayColormap
clone, getColor, getMap, setColor, setColorInterpolated, setColorRange, setColorRange, setMap
-
-