|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.jhlabs.image.ArrayColormap
com.jhlabs.image.SplineColormap
public class SplineColormap
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.
| Field Summary |
|---|
| Fields inherited from class com.jhlabs.image.ArrayColormap |
|---|
map |
| Constructor Summary | |
|---|---|
SplineColormap()
Construct a SplineColormap. |
|
SplineColormap(int[] xKnots,
int[] yKnots)
Construct a SplineColormap. |
|
| Method Summary | |
|---|---|
void |
addKnot(int x,
int color)
Add a new knot. |
int |
getKnot(int n)
Get a knot color. |
void |
removeKnot(int n)
Remove a knot. |
void |
setKnot(int n,
int color)
Set a knot color. |
void |
setKnotPosition(int n,
int x)
Set a knot position. |
| Methods inherited from class com.jhlabs.image.ArrayColormap |
|---|
clone, getColor, getMap, setColor, setColorInterpolated, setColorRange, setColorRange, setMap |
| Methods inherited from class java.lang.Object |
|---|
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SplineColormap()
public SplineColormap(int[] xKnots,
int[] yKnots)
xKnots - the knot positionsyKnots - the knot colors| Method Detail |
|---|
public void setKnot(int n,
int color)
n - the knot indexcolor - the colorgetKnot(int)public int getKnot(int n)
n - the knot index
setKnot(int, int)
public void addKnot(int x,
int color)
x - the knot positioncolor - the colorremoveKnot(int)public void removeKnot(int n)
n - the knot indexaddKnot(int, int)
public void setKnotPosition(int n,
int x)
n - the knot indexx - the knot position
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||