fr.esrf.tangoatk.widget.image
Class Mono16ImageFormat

java.lang.Object
  extended by fr.esrf.tangoatk.widget.image.IImageFormat
      extended by fr.esrf.tangoatk.widget.image.Mono16ImageFormat

public class Mono16ImageFormat
extends IImageFormat

Monochrome 16bits image format


Constructor Summary
Mono16ImageFormat()
           
 
Method Summary
 void computeFitting()
          Compute the fitting bounds (Monochrome only)
 int getHistogramWidth()
          Returns the histogram width.
 java.lang.String getName()
          Returns the format name.
 int getRGB(boolean negative, int[] colormap16, int x, int y)
          Returns the pixel at the specifed pos
 double getValue(int x, int y)
          Gets the pixel value as double (Used for table and profile display).
 java.lang.String getValueStr(int x, int y)
          Gets the pixel value as string (Used for pixel info display).
 int getWidth()
          Returns the width of the image depending on the format.
 boolean isColorFormat()
          Returns true if this format is a color format, false otherwise.
 void setData(byte[] rawData)
          Sets and decode the data.
 
Methods inherited from class fr.esrf.tangoatk.widget.image.IImageFormat
getHeight, initDefault, isNull, setFitting
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Mono16ImageFormat

public Mono16ImageFormat()
Method Detail

setData

public void setData(byte[] rawData)
             throws java.io.IOException
Description copied from class: IImageFormat
Sets and decode the data.

Specified by:
setData in class IImageFormat
Parameters:
rawData - Pointer to image data
Throws:
java.io.IOException

getWidth

public int getWidth()
Description copied from class: IImageFormat
Returns the width of the image depending on the format.

Specified by:
getWidth in class IImageFormat

getName

public java.lang.String getName()
Description copied from class: IImageFormat
Returns the format name.

Specified by:
getName in class IImageFormat

isColorFormat

public boolean isColorFormat()
Description copied from class: IImageFormat
Returns true if this format is a color format, false otherwise.

Specified by:
isColorFormat in class IImageFormat

getHistogramWidth

public int getHistogramWidth()
Description copied from class: IImageFormat
Returns the histogram width. (The number of possible value for a pixel)

Specified by:
getHistogramWidth in class IImageFormat

getValue

public double getValue(int x,
                       int y)
Description copied from class: IImageFormat
Gets the pixel value as double (Used for table and profile display).

Specified by:
getValue in class IImageFormat
Parameters:
x - horizontal coordinate
y - vertical coordinate

getValueStr

public java.lang.String getValueStr(int x,
                                    int y)
Description copied from class: IImageFormat
Gets the pixel value as string (Used for pixel info display).

Specified by:
getValueStr in class IImageFormat
Parameters:
x - horizontal coordinate
y - vertical coordinate

computeFitting

public void computeFitting()
Description copied from class: IImageFormat
Compute the fitting bounds (Monochrome only)

Specified by:
computeFitting in class IImageFormat

getRGB

public int getRGB(boolean negative,
                  int[] colormap16,
                  int x,
                  int y)
Description copied from class: IImageFormat
Returns the pixel at the specifed pos

Specified by:
getRGB in class IImageFormat
Parameters:
negative - Negative flag
colormap16 - 16Bit colormap (Monochrome only)
x - horizontal coordinate
y - vertical coordinate