/*
 * class GreymapFile
 *
 * $Date$
 * $Revision$
 *
 */

#ifndef GREYMAP_FILE_HH__
#define GREYMAP_FILE_HH__

#include "WImage/ImageArray.hh"
#include "WImage/miscdefs.h"

/** 
 * @addtogroup WImage 
 * @{ */

/** 
 * An abstract image file. A framework to create readers and writers on
 * any greyscale images.
 */
/*abstract*/
class 
GreymapFile
{
public:
  
  /** Constructor. Initializes internal fields and gets an {\em ImageArray} 
   * object that may already contain an image or will get one later. 
   * @param name
   * the file name
   * @param data
   * the array for the values */
  GreymapFile (char const *name, ImageArray<coeff> &data);
  
  /** Destructor. Releases some memory. */
  virtual ~GreymapFile (void);

protected:

  /** The pixels. These are one-byte integer values representing pixels
   * stored in typical image formats. */
  ImageArray<pixel> *m_pixels;
  /** Coefficients. These are long floating-point numbers to represent
   * positive or negative floating-point values created through a 
   * transform. */
  ImageArray<coeff> *m_coeffs;
  /** The file name. The name of the file associated with this object. */
  char const * m_fname;
  
}; /* class GreymapFile */

/** @} */

#endif /* GREYMAP_FILE_HH__ */
