Drawable, MeasurableBinaryLattice, ByteRaster, CellLattice, CellLatticeOSX, CellLatticePC, SiteLatticepublic interface ByteLattice extends Measurable
| Modifier and Type | Method | Description |
|---|---|---|
void |
createDefaultColors() |
Creates the default palette.
|
int |
getNx() |
Gets the number of x entries.
|
int |
getNy() |
Gets the number of y entries.
|
byte |
getValue(int ix,
int iy) |
Gets a value from the given location.
|
int |
indexFromPoint(double x,
double y) |
Determines the lattice index (row-major order) from given x and y world coordinates.
|
void |
randomize() |
Randomizes the values.
|
void |
resizeLattice(int _nx,
int _ny) |
Resizes the lattice.
|
void |
setAll(byte[][] val,
double xmin,
double xmax,
double ymin,
double ymax) |
Sets the lattice values and scale.
|
void |
setBlock(byte[][] val) |
Sets a block of data starting at (0,0) to new values.
|
void |
setBlock(int ix_offset,
int iy_offset,
byte[][] val) |
Sets a block of data to new values.
|
void |
setCol(int ix,
int iy_offset,
byte[] val) |
Sets a column to new values.
|
void |
setColorPalette(java.awt.Color[] colors) |
Sets the color palette.
|
void |
setGridLineColor(java.awt.Color c) |
Sets the color for grid line boundaries
|
void |
setIndexedColor(int i,
java.awt.Color color) |
Sets the color for a single index.
|
void |
setMinMax(double xmin,
double xmax,
double ymin,
double ymax) |
Assigns a scale to the lattice in world units.
|
void |
setRow(int iy,
int ix_offset,
byte[] val) |
Sets a row to new values.
|
void |
setShowGridLines(boolean showGridLines) |
Outlines the lattice boundaries with a grid.
|
void |
setValue(int ix,
int iy,
byte val) |
Sets the given x,y location to a value.
|
void |
setVisible(boolean isVisible) |
Sets the visibility of the lattice.
|
void |
setXMax(double xmax) |
Sets xmax.
|
void |
setXMin(double xmin) |
Sets xmin.
|
void |
setYMax(double ymax) |
Sets ymax.
|
void |
setYMin(double ymin) |
Sets ymin.
|
javax.swing.JFrame |
showLegend() |
Shows the color associated with each value.
|
int |
xToIndex(double x) |
Gets closest index from the given x world coordinate.
|
int |
yToIndex(double y) |
Gets closest index from the given y world coordinate.
|
getXMax, getXMin, getYMax, getYMin, isMeasuredint getNx()
int getNy()
int indexFromPoint(double x,
double y)
x - y - int xToIndex(double x)
x - double the coordinateint yToIndex(double y)
y - double the coordinatebyte getValue(int ix,
int iy)
ix - iy - void setValue(int ix,
int iy,
byte val)
ix - iy - val - void randomize()
void resizeLattice(int _nx,
int _ny)
_nx - _ny - void setAll(byte[][] val,
double xmin,
double xmax,
double ymin,
double ymax)
val - int[][] the new valuesxmin - doublexmax - doubleymin - doubleymax - doublevoid setBlock(int ix_offset,
int iy_offset,
byte[][] val)
ix_offset - the x offset into the latticeiy_offset - the y offset into the latticeval - void setBlock(byte[][] val)
val - void setCol(int ix,
int iy_offset,
byte[] val)
ix - the x index of the columniy_offset - the y offset in the columnval - values in columnvoid setRow(int iy,
int ix_offset,
byte[] val)
iy - the y index of the rowix_offset - the x offset in the rowval - void setShowGridLines(boolean showGridLines)
showGridLines - void setGridLineColor(java.awt.Color c)
c - javax.swing.JFrame showLegend()
void setVisible(boolean isVisible)
isVisible - void setColorPalette(java.awt.Color[] colors)
colors - void setIndexedColor(int i,
java.awt.Color color)
i - color - void setMinMax(double xmin,
double xmax,
double ymin,
double ymax)
xmin - xmax - ymin - ymax - void setXMin(double xmin)
xmin - doublevoid setXMax(double xmax)
xmax - doublevoid setYMin(double ymin)
ymin - doublevoid setYMax(double ymax)
ymax - doublevoid createDefaultColors()