Transparency
public final class DiscreteAlphaIndexColorModel extends ColorModel
IndexColorModel
and a ComponentColorModel
,
having both a color map and a full, discrete alpha channel.
The color map entries are assumed to be fully opaque and should have no transparent index.
ColorSpace will always be the default sRGB color space (as with IndexColorModel
).
Component order is always P, A, where P is a palette index, and A is the alpha value.
IndexColorModel
,
ComponentColorModel
pixel_bits, transferType
BITMASK, OPAQUE, TRANSLUCENT
Constructor | Description |
---|---|
DiscreteAlphaIndexColorModel(IndexColorModel icm) |
Creates a
DiscreteAlphaIndexColorModel , delegating color map look-ups
to the given IndexColorModel . |
Modifier and Type | Method | Description |
---|---|---|
SampleModel |
createCompatibleSampleModel(int w,
int h) |
|
WritableRaster |
createCompatibleWritableRaster(int w,
int h) |
|
int |
getAlpha(int pixel) |
|
int |
getAlpha(Object inData) |
|
int |
getBlue(int pixel) |
|
int |
getBlue(Object inData) |
|
int |
getGreen(int pixel) |
|
int |
getGreen(Object inData) |
|
int |
getRed(int pixel) |
|
int |
getRed(Object inData) |
|
boolean |
isCompatibleRaster(Raster raster) |
|
boolean |
isCompatibleSampleModel(SampleModel sm) |
|
String |
toString() |
coerceData, equals, finalize, getAlphaRaster, getColorSpace, getComponents, getComponents, getComponentSize, getComponentSize, getDataElement, getDataElement, getDataElements, getDataElements, getDataElements, getNormalizedComponents, getNormalizedComponents, getNumColorComponents, getNumComponents, getPixelSize, getRGB, getRGB, getRGBdefault, getTransferType, getTransparency, getUnnormalizedComponents, hasAlpha, hashCode, isAlphaPremultiplied
public DiscreteAlphaIndexColorModel(IndexColorModel icm)
DiscreteAlphaIndexColorModel
, delegating color map look-ups
to the given IndexColorModel
.icm
- The IndexColorModel
delegate. Color map entries are assumed to be
fully opaque, any transparency or transparent index will be ignored.public final int getRed(int pixel)
getRed
in class ColorModel
public final int getGreen(int pixel)
getGreen
in class ColorModel
public final int getBlue(int pixel)
getBlue
in class ColorModel
public final int getAlpha(int pixel)
getAlpha
in class ColorModel
public final int getRed(Object inData)
getRed
in class ColorModel
public final int getGreen(Object inData)
getGreen
in class ColorModel
public final int getBlue(Object inData)
getBlue
in class ColorModel
public final int getAlpha(Object inData)
getAlpha
in class ColorModel
public final SampleModel createCompatibleSampleModel(int w, int h)
createCompatibleSampleModel
in class ColorModel
public final boolean isCompatibleSampleModel(SampleModel sm)
isCompatibleSampleModel
in class ColorModel
public final WritableRaster createCompatibleWritableRaster(int w, int h)
createCompatibleWritableRaster
in class ColorModel
public final boolean isCompatibleRaster(Raster raster)
isCompatibleRaster
in class ColorModel
public String toString()
toString
in class ColorModel
Copyright © 2018. All rights reserved.