|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
ObjectPlanarImage
OpImage
FloodFill
public abstract class FloodFill
Performs the Flood Fill operation on the given raster.
Algorithm
This class implements a Scan line flood fill algorithm as
documented in Wikipedia
on June 2009, section Alternative implementations (queue-based)
modified as described in Scanline fill section. The algorithm
has been modified in order to work properly with tiled images.
| coverage/geotk-coverage (download) | View source code for this class |
| Field Summary | |
|---|---|
static String |
OPERATION_NAME
The name of this operation in the JAI registry. |
| Fields inherited from class OpImage |
|---|
cache, cobbleSources, OP_COMPUTE_BOUND, OP_IO_BOUND, OP_NETWORK_BOUND, tileCacheMetric, tileRecycler |
| Fields inherited from class PlanarImage |
|---|
colorModel, eventManager, height, minX, minY, properties, sampleModel, tileFactory, tileGridXOffset, tileGridYOffset, tileHeight, tileWidth, width |
| Constructor Summary | |
|---|---|
FloodFill(RenderedImage source,
ImageLayout layout,
Map<?,?> configuration,
double[][] oldValues,
double[] newValues)
Constructs a new Flood Fill for the given image. |
|
| Method Summary | |
|---|---|
static void |
fill(WritableRenderedImage image,
Color[] oldColors,
Color newColors,
Point... points)
Colors an area of connected pixels with the same set of color. |
static void |
fill(WritableRenderedImage image,
double[][] oldValues,
double[] newValues,
Point... points)
Colors an area of connected pixels with the same set of color. |
Vector<RenderedImage> |
getSources()
Returns the source images. |
| Methods inherited from class Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String OPERATION_NAME
| Constructor Detail |
|---|
public FloodFill(RenderedImage source,
ImageLayout layout,
Map<?,?> configuration,
double[][] oldValues,
double[] newValues)
source - The source image.layout - The image layout.configuration - The image properties and rendering hints.oldValues - The old values in the source images.newValues - The new values in the source images.| Method Detail |
|---|
public Vector<RenderedImage> getSources()
getSources in interface RenderedImagegetSources in class PlanarImage
public static void fill(WritableRenderedImage image,
Color[] oldColors,
Color newColors,
Point... points)
image - The image in which to colors an area.oldColors - The colors to replace (usually only 1 color, but more are allowed).newColors - The new colors replacing the old ones.points - The coordinate of the starting point. There is usually only one
such point, but more are allowed.
public static void fill(WritableRenderedImage image,
double[][] oldValues,
double[] newValues,
Point... points)
image - The image in which to colors an area.oldValues - The colors to replace (usually only 1 color, but more are allowed).newValues - The new colors replacing the old ones.points - The coordinate of the starting point. There is usually only one
such point, but more are allowed.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||