public class ErrorDiffusionDescriptor
extends javax.media.jai.OperationDescriptorImpl
OperationDescriptor
describing the "ErrorDiffusion" operation.
The "ErrorDiffusion" operation performs color quantization by finding the nearest color to each pixel in a supplied color map and "diffusing" the color quantization error below and to the right of the pixel.
Users may also define a ROI and a NoData Range for reducing computation area or masking unwanted pixel values.
Name | Value |
---|---|
GlobalName | ErrorDiffusion |
LocalName | ErrorDiffusion |
Vendor | it.geosolutions.jaiext |
Description | Performs error diffusion color quantization using a specified color map and error filter. |
DocURL | |
Version | 1.0 |
arg0Desc | Input colormap. |
arg1Desc | Input errordiffusion kernel. |
arg2Desc | Optional ROI object to use in computation. |
arg3Desc | Optional Range of NoData values to use in computation. |
arg4Desc | Destination No Data value used when the computation cannot be performed. |
Name | Class Type | Default Value |
---|---|---|
colorMap | javax.media.jai.LookupTableJAI | NO_PARAMETER_DEFAULT |
errorKernel | javax.media.jai.KernelJAI | javax.media.jai.KernelJAI.ERROR_FILTER_FLOYD_STEINBERG |
roi | javax.media.jai.ROI | null |
nodata | it.geosolutions.jaiext.range.Range | null |
destNoData | Integer | 0 |
Constructor and Description |
---|
ErrorDiffusionDescriptor()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static javax.media.jai.RenderedOp |
create(RenderedImage source0,
javax.media.jai.LookupTableJAI colorMap,
javax.media.jai.KernelJAI errorKernel,
javax.media.jai.ROI roi,
Range nodata,
double[] destNoData,
RenderingHints hints)
Performs error diffusion color quantization using a specified color map and error filter.
|
arePropertiesSupported, getDefaultSourceClass, getDestClass, getDestClass, getInvalidRegion, getName, getNumParameters, getNumSources, getParamClasses, getParamDefaults, getParamDefaultValue, getParameterListDescriptor, getParamMaxValue, getParamMinValue, getParamNames, getPropertyGenerators, getPropertyGenerators, getRenderableDestClass, getRenderableSourceClasses, getResourceBundle, getResources, getSourceClasses, getSourceClasses, getSourceNames, getSupportedModes, isImmediate, isModeSupported, isRenderableSupported, isRenderedSupported, makeDefaultSourceClassList, validateArguments, validateArguments, validateParameters, validateParameters, validateRenderableArguments, validateRenderableSources, validateSources, validateSources
public static javax.media.jai.RenderedOp create(RenderedImage source0, javax.media.jai.LookupTableJAI colorMap, javax.media.jai.KernelJAI errorKernel, javax.media.jai.ROI roi, Range nodata, double[] destNoData, RenderingHints hints)
Creates a ParameterBlockJAI
from all supplied arguments except hints
and invokes
JAI.create(String,ParameterBlock,RenderingHints)
.
source0
- RenderedImage
source 0.colorMap
- The color map.errorKernel
- The error filter kernel. May be null
.roi
- The optional ROI to use in computation. May be null
.nodata
- A range used for checking if a pixel is nodata. May be null
.destNoData
- Value for the destination NoData to set (in the source image colorspace). May be null
.hints
- The RenderingHints
to use. May be null
.RenderedOp
destination.IllegalArgumentException
- if source0
is null
.IllegalArgumentException
- if colorMap
is null
.JAI
,
ParameterBlockJAI
,
RenderedOp
Copyright © 2006–2017 GeoSolutions. All rights reserved.