jjil.core
Class Gray32MaskedImage

java.lang.Object
  extended by jjil.core.Image
      extended by jjil.core.Gray32Image
          extended by jjil.core.Gray32MaskedImage

public class Gray32MaskedImage
extends Gray32Image

Gray32MaskedImage is the image type used to store a 32-bit integer image and its associated 8-bit mask. Mask value = Byte.MIN_VALUE is considered to be unmasked; all other values are masked.

Author:
webb

Constructor Summary
Gray32MaskedImage(Gray32Image imData, Gray8Image imMask)
          Creates a new instance of Gray32MaskedImage from an existing image and mask.
Gray32MaskedImage(int cWidth, int cHeight)
          Creates a new instance of Gray32MaskedImage
 
Method Summary
 Image clone()
          Copy this image
 Gray32Image getImage()
          Get the input Gray32Image.
 Gray8Image getMask()
          Get the input Gray8Image mask.
 byte[] getMaskData()
          Return a pointer to the mask data.
 java.lang.String toString()
          Return a string describing the image.
 
Methods inherited from class jjil.core.Gray32Image
getData
 
Methods inherited from class jjil.core.Image
getHeight, getWidth
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Gray32MaskedImage

public Gray32MaskedImage(int cWidth,
                         int cHeight)
Creates a new instance of Gray32MaskedImage

Parameters:
cWidth - Width of the image (columns).
cHeight - Height of the image (rows)

Gray32MaskedImage

public Gray32MaskedImage(Gray32Image imData,
                         Gray8Image imMask)
                  throws Error
Creates a new instance of Gray32MaskedImage from an existing image and mask.

Parameters:
imData - the data image.
imMask - the mask
Throws:
Error - If either input is not a Gray8Image or the sizes are not the same.
Method Detail

clone

public Image clone()
Copy this image

Overrides:
clone in class Gray32Image
Returns:
the image copy.

getImage

public Gray32Image getImage()
Get the input Gray32Image.

Returns:
the input iamge

getMask

public Gray8Image getMask()
Get the input Gray8Image mask.

Returns:
the input mask

getMaskData

public byte[] getMaskData()
Return a pointer to the mask data.

Returns:
the data pointer.

toString

public java.lang.String toString()
Return a string describing the image.

Overrides:
toString in class Gray32Image
Returns:
the string.