javax.media.jai.operator
Class AddConstToCollectionDescriptor
java.lang.Object
|
+--javax.media.jai.OperationDescriptorImpl
|
+--javax.media.jai.operator.AddConstToCollectionDescriptor
- All Implemented Interfaces:
- OperationDescriptor, RegistryElementDescriptor, Serializable
- public class AddConstToCollectionDescriptor
- extends OperationDescriptorImpl
An OperationDescriptor describing the
"AddConstToCollection" operation.
The AddConstToCollection operation takes a collection of
rendered images and an array of double constants, and for each
rendered image in the collection adds a constant to every pixel of
its corresponding band. If the number of constants supplied is less
than the number of bands of a source image then the same constant
from entry 0 is applied to all the bands. Otherwise, a constant
from a different entry is applied to each band.
The operation will attempt to store the result images in the same
collection class as that of the source images. If a new instance of
the source collection class can not be created, then the operation
will store the result images in a java.util.Vector. There will be the
same number of images in the output collection as in the source
collection.
Resource List
| Name | Value |
| GlobalName | AddConstToCollection |
| LocalName | AddConstToCollection |
| Vendor | com.sun.media.jai |
| Description | Adds constants to a collection
of rendered images. | |
| DocURL | http://java.sun.com/products/java-media/jai/forDevelopers/jai-apidocs/javax/media/jai/operator/AddConstToCollectionDescriptor.html |
| Version | 1.0 |
| arg0Desc | The constants to be added. |
Parameter List
| Name | Class Type |
Default Value |
| constants | double[] |
{0.0} |
- See Also:
CollectionImage,
Collection,
OperationDescriptor, Serialized Form
| Methods inherited from class javax.media.jai.OperationDescriptorImpl |
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, validateParameters, validateParameters, validateRenderableArguments, validateRenderableSources, validateSources, validateSources |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AddConstToCollectionDescriptor
public AddConstToCollectionDescriptor()
- Constructor.
validateArguments
public boolean validateArguments(String modeName,
ParameterBlock args,
StringBuffer msg)
- Validates input source and parameter.
- Overrides:
validateArguments in class OperationDescriptorImpl
- Following copied from class:
javax.media.jai.OperationDescriptorImpl
- Parameters:
modeName - the operation mode nameargs - Input arguments, including source(s) and/or parameter(s).msg - A string that may contain error messages.- Throws:
IllegalArgumentException - if modeName is null- See Also:
OperationDescriptorImpl.validateSources(java.lang.String, java.awt.image.renderable.ParameterBlock, java.lang.StringBuffer),
OperationDescriptorImpl.validateParameters(java.lang.String, java.awt.image.renderable.ParameterBlock, java.lang.StringBuffer)
createCollection
public static Collection createCollection(Collection source0,
double[] constants,
RenderingHints hints)
- Adds constants to a collection of rendered images.
Creates a ParameterBlockJAI from all
supplied arguments except hints and invokes
JAI.createCollection(String,ParameterBlock,RenderingHints).
- Parameters:
source0 - Collection source 0.constants - The constants to be added.
May be null.hints - The RenderingHints to use.
May be null.- Returns:
- The
Collection destination. - Throws:
IllegalArgumentException - if source0 is null.- See Also:
JAI,
ParameterBlockJAI,
Collection