Package com.luciad.imaging
Class ALcdBandColorSemantics
java.lang.Object
com.luciad.imaging.ALcdBandSemantics
com.luciad.imaging.ALcdBandColorSemantics
Semantics for a color band in an image.
The
type
describes the semantics of the band. In addition for color bands you can also retrieve
the color space
and component index
.
This class cannot be implemented by the user. You can use the
TLcdBandColorSemanticsBuilder
to create new instances.
An image
's pixels are considered to represent a color if:
- All bands are of type
ALcdBandColorSemantics
. - The
band types
are one of the following:- Gray
- Red, Green, Blue
- Red, Green, Blue, Alpha
- All bands with a
color space
have the same one.
ComponentSampleModel
allows a
different memory byte-order and logical order through its band offsets
.- Since:
- 2014.0
-
Nested Class Summary
Nested classes/interfaces inherited from class com.luciad.imaging.ALcdBandSemantics
ALcdBandSemantics.DataType
-
Method Summary
Modifier and TypeMethodDescriptionabstract ColorSpace
Returns the color space.abstract int
Returns the component index in thecolor space
.abstract IndexColorModel
Returns the palette for apalette index
band.abstract ALcdBandColorSemantics.Type
getType()
Returns the type of the band.abstract boolean
Returns if the band is pre-multiplied with alpha.Methods inherited from class com.luciad.imaging.ALcdBandSemantics
getDataType, getMaxValue, getMinValue, getNoDataValue, getNormalizedRangeMaxValue, getNormalizedRangeMinValue, getNumSignificantBits, isNormalized
-
Method Details
-
getType
Returns the type of the band.- Returns:
- the type, never
null
-
getColorSpace
Returns the color space. This property is only available for color bands (e.g. all types exceptALcdBandColorSemantics.Type.ALPHA
).- Returns:
- the color space
-
getComponentIndex
public abstract int getComponentIndex()Returns the component index in thecolor space
. For aalpha
orpalette index
band the component index is-1
.- Returns:
- the component index or
-1
-
isAlphaPremultiplied
public abstract boolean isAlphaPremultiplied()Returns if the band is pre-multiplied with alpha. Analpha
band is never pre-multiplied.- Returns:
- whether the band is pre-multiplied with alpha or not
-
getPalette
Returns the palette for apalette index
band.- Returns:
- the palette or
null
.
-