IMAGE - The type of image that this processor can processpublic abstract class AbstractImageMaskInpainter<IMAGE extends Image<?,IMAGE>> extends Object implements Inpainter<IMAGE>
Inpainter implementations that consume a mask image
(rather than connected components or pixel sets). Provides the necessary
methods to build the mask image for all the various calls to
setMask.
All setMask implementations call initMask(), which
subclasses should implement to perform any required initialisation.
processImage(Image) performs checks on the image dimensions and then
calls performInpainting(Image).
| Constructor and Description |
|---|
AbstractImageMaskInpainter() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
initMask()
Perform any initialisation once the mask has been set.
|
protected abstract void |
performInpainting(IMAGE image)
Perform the inpainting of the given image
|
void |
processImage(IMAGE image)
Inpaint the given image, painting all the mask pixels set by a prior call
to
Inpainter.setMask(int,int,Collection), Inpainter.setMask(FImage) or
Inpainter.setMask(int,int,PixelSet...) |
void |
setMask(FImage mask)
Set the mask.
|
void |
setMask(int width,
int height,
Collection<? extends Iterable<Pixel>> mask)
Set the mask.
|
void |
setMask(int width,
int height,
PixelSet... mask)
Set the mask.
|
public AbstractImageMaskInpainter()
public void setMask(FImage mask)
Inpainterpublic void setMask(int width, int height, Collection<? extends Iterable<Pixel>> mask)
Inpainterpublic void setMask(int width, int height, PixelSet... mask)
Inpainterprotected void initMask()
public final void processImage(IMAGE image)
InpainterInpainter.setMask(int,int,Collection), Inpainter.setMask(FImage) or
Inpainter.setMask(int,int,PixelSet...)processImage in interface Inpainter<IMAGE extends Image<?,IMAGE>>processImage in interface ImageProcessor<IMAGE extends Image<?,IMAGE>>image - the image to perform inpainting onprotected abstract void performInpainting(IMAGE image)
image - the image to inpaint