Class DIBHeader

java.lang.Object
com.twelvemonkeys.imageio.plugins.bmp.DIBHeader
Direct Known Subclasses:
DIBHeader.BitmapCoreHeader, DIBHeader.BitmapCoreHeaderV2, DIBHeader.BitmapInfoHeader, DIBHeader.BitmapV4InfoHeader, DIBHeader.BitmapV5InfoHeader

abstract class DIBHeader extends Object
Represents the DIB (Device Independent Bitmap) Information header structure.
Version:
$Id: DIBHeader.java,v 1.0 May 5, 2009 10:45:31 AM haraldk Exp$
See Also:
  • Field Details

    • DEFAULT_PIXELS_PER_METER

      private final int DEFAULT_PIXELS_PER_METER
      See Also:
    • size

      protected int size
    • width

      protected int width
    • height

      protected int height
    • topDown

      protected boolean topDown
    • planes

      protected int planes
    • bitCount

      protected int bitCount
    • compression

      protected int compression
      0 = BI_RGB: No compression 1 = BI_RLE8: 8 bit RLE Compression (8 bit only) 2 = BI_RLE4: 4 bit RLE Compression (4 bit only) 3 = BI_BITFIELDS: No compression (16 invalid input: '&' 32 bit only)
    • imageSize

      protected int imageSize
    • xPixelsPerMeter

      protected int xPixelsPerMeter
    • yPixelsPerMeter

      protected int yPixelsPerMeter
    • colorsUsed

      protected int colorsUsed
    • colorsImportant

      protected int colorsImportant
    • masks

      protected int[] masks
    • colorSpaceType

      protected int colorSpaceType
    • cieXYZEndpoints

      protected double[] cieXYZEndpoints
    • gamma

      protected int[] gamma
    • intent

      protected int intent
    • profileData

      protected long profileData
    • profileSize

      protected long profileSize
  • Constructor Details

    • DIBHeader

      protected DIBHeader()
  • Method Details

    • read

      public static DIBHeader read(DataInput stream) throws IOException
      Throws:
      IOException
    • createHeader

      private static DIBHeader createHeader(int size) throws IOException
      Throws:
      IOException
    • read

      protected abstract void read(int size, DataInput stream) throws IOException
      Throws:
      IOException
    • write

      protected abstract void write(DataOutput stream) throws IOException
      Throws:
      IOException
    • getSize

      public final int getSize()
    • getWidth

      public final int getWidth()
    • getHeight

      public final int getHeight()
    • getPlanes

      public final int getPlanes()
    • getBitCount

      public final int getBitCount()
    • getCompression

      public int getCompression()
    • getImageSize

      public int getImageSize()
    • getXPixelsPerMeter

      public int getXPixelsPerMeter()
    • getYPixelsPerMeter

      public int getYPixelsPerMeter()
    • getColorsUsed

      public int getColorsUsed()
    • getColorsImportant

      public int getColorsImportant()
    • hasMasks

      public boolean hasMasks()
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • readMasks

      private static int[] readMasks(DataInput stream, boolean hasAlphaMask) throws IOException
      Throws:
      IOException
    • getBMPVersion

      protected abstract String getBMPVersion()