Package omeis.providers.re
Class RGBAIntBuffer
- java.lang.Object
-
- omeis.providers.re.RGBBuffer
-
- omeis.providers.re.RGBAIntBuffer
-
- All Implemented Interfaces:
java.io.Serializable
public class RGBAIntBuffer extends RGBBuffer
Holds the data of an RGBA image. The image data is stored as a packed integer in the format RGBA. Note that Java color objects are stored in ARGB.- Since:
- OME2.2
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RGBAIntBuffer(int sizeX1, int sizeX2)
Creates a new 4-band packed integer buffer.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description byte
getBlueValue(int index)
Retrieves the Blue value for a particular pixel index.int[]
getDataBuffer()
Retrieves the data buffer that contains the pixel values.byte
getGreenValue(int index)
Retrieves the Green value for a particular pixel index.byte
getRedValue(int index)
Retrieves the Red value for a particular pixel index.void
setBlueValue(int index, int value)
Sets the Blue value for a particular pixel index.void
setGreenValue(int index, int value)
Sets the Green value for a particular pixel index.void
setRedValue(int index, int value)
Sets the Red value for a particular pixel index.void
zero()
Zeros out (sets every pixel offset to zero) each band.-
Methods inherited from class omeis.providers.re.RGBBuffer
getBlueBand, getGreenBand, getRedBand, getSizeX1, getSizeX2
-
-
-
-
Constructor Detail
-
RGBAIntBuffer
public RGBAIntBuffer(int sizeX1, int sizeX2)
Creates a new 4-band packed integer buffer.- Parameters:
sizeX1
- The number of pixels on the X1-axis. This is the X-axis in the case of an XY-plane or XZ-plane. Otherwise it is the Z-axis ZY-plane.sizeX2
- The number of pixels on the X2-axis. This is the Y-axis in the case of an XY-plane or ZY-plane. Otherwise it is the Z-axis XZ-plane.- See Also:
RGBBuffer.bands
-
-
Method Detail
-
setRedValue
public void setRedValue(int index, int value)
Sets the Red value for a particular pixel index.- Overrides:
setRedValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.value
- The pixel value to set.
-
setGreenValue
public void setGreenValue(int index, int value)
Sets the Green value for a particular pixel index.- Overrides:
setGreenValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.value
- The pixel value to set.
-
setBlueValue
public void setBlueValue(int index, int value)
Sets the Blue value for a particular pixel index.- Overrides:
setBlueValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.value
- The pixel value to set.
-
getRedValue
public byte getRedValue(int index)
Retrieves the Red value for a particular pixel index.- Overrides:
getRedValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.- Returns:
- The pixel value at the index.
-
getGreenValue
public byte getGreenValue(int index)
Retrieves the Green value for a particular pixel index.- Overrides:
getGreenValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.- Returns:
- The pixel value at the index.
-
getBlueValue
public byte getBlueValue(int index)
Retrieves the Blue value for a particular pixel index.- Overrides:
getBlueValue
in classRGBBuffer
- Parameters:
index
- The index in the band array.- Returns:
- The pixel value at the index.
-
getDataBuffer
public int[] getDataBuffer()
Retrieves the data buffer that contains the pixel values.- Returns:
- an integer array containing pixel values.
-
-