org.apache.poi.hwmf.record

## Enum HwmfBitmapDib.BitCount

- java.lang.Object
- - java.lang.Enum<HwmfBitmapDib.BitCount>
  - - org.apache.poi.hwmf.record.HwmfBitmapDib.BitCount

- All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<HwmfBitmapDib.BitCount>
  Enclosing class:
    HwmfBitmapDib

      public static enum HwmfBitmapDib.BitCount
      extends java.lang.Enum<HwmfBitmapDib.BitCount>

- - ### Enum Constant Summary

    Enum Constants
    Enum Constant and Description
    `BI_BITCOUNT_0` The image SHOULD be in either JPEG or PNG format.
    `BI_BITCOUNT_1` Each pixel in the bitmap is represented by a single bit.
    `BI_BITCOUNT_2` Each pixel in the bitmap is represented by a 4-bit index into the color table, and each byte contains 2 pixels.
    `BI_BITCOUNT_3` Each pixel in the bitmap is represented by an 8-bit index into the color table, and each byte contains 1 pixel.
    `BI_BITCOUNT_4` Each pixel in the bitmap is represented by a 16-bit value.
    `BI_BITCOUNT_5` The bitmap has a maximum of 2^24 colors, and the Colors field of DIB is NULL.
    `BI_BITCOUNT_6` The bitmap has a maximum of 2^24 colors.

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static HwmfBitmapDib.BitCount` | `valueOf(java.lang.String name)` Returns the enum constant of this type with the specified name.
    `static HwmfBitmapDib.BitCount[]` | `values()` Returns an array containing the constants of this enum type, in the order they are declared.

    - ### Methods inherited from class java.lang.Enum

      `clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

- - ### Enum Constant Detail

    - #### BI_BITCOUNT_0

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_0

      The image SHOULD be in either JPEG or PNG format. <6> Neither of these formats includes a color table, so this value specifies that no color table is present. See [JFIF] and [RFC2083] for more information concerning JPEG and PNG compression formats.

    - #### BI_BITCOUNT_1

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_1

      Each pixel in the bitmap is represented by a single bit. If the bit is clear, the pixel is displayed with the color of the first entry in the color table; if the bit is set, the pixel has the color of the second entry in the table.

    - #### BI_BITCOUNT_2

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_2

      Each pixel in the bitmap is represented by a 4-bit index into the color table, and each byte contains 2 pixels.

    - #### BI_BITCOUNT_3

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_3

      Each pixel in the bitmap is represented by an 8-bit index into the color table, and each byte contains 1 pixel.

    - #### BI_BITCOUNT_4

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_4

      Each pixel in the bitmap is represented by a 16-bit value.
      If the Compression field of the BitmapInfoHeader Object is BI_RGB, the Colors field of DIB is NULL. Each WORD in the bitmap array represents a single pixel. The relative intensities of red, green, and blue are represented with 5 bits for each color component. The value for blue is in the least significant 5 bits, followed by 5 bits each for green and red. The most significant bit is not used. The color table is used for optimizing colors on palette-based devices, and contains the number of entries specified by the ColorUsed field of the BitmapInfoHeader Object.
      If the Compression field of the BitmapInfoHeader Object is BI_BITFIELDS, the Colors field contains three DWORD color masks that specify the red, green, and blue components, respectively, of each pixel. Each WORD in the bitmap array represents a single pixel.
      When the Compression field is set to BI_BITFIELDS, bits set in each DWORD mask MUST be contiguous and SHOULD NOT overlap the bits of another mask.

    - #### BI_BITCOUNT_5

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_5

      The bitmap has a maximum of 2^24 colors, and the Colors field of DIB is NULL. Each 3-byte triplet in the bitmap array represents the relative intensities of blue, green, and red, respectively, for a pixel. The Colors color table is used for optimizing colors used on palette-based devices, and MUST contain the number of entries specified by the ColorUsed field of the BitmapInfoHeader Object.

    - #### BI_BITCOUNT_6

          public static final HwmfBitmapDib.BitCount BI_BITCOUNT_6

      The bitmap has a maximum of 2^24 colors.
      If the Compression field of the BitmapInfoHeader Object is set to BI_RGB, the Colors field of DIB is set to NULL. Each DWORD in the bitmap array represents the relative intensities of blue, green, and red, respectively, for a pixel. The high byte in each DWORD is not used. The Colors color table is used for optimizing colors used on palette-based devices, and MUST contain the number of entries specified by the ColorUsed field of the BitmapInfoHeader Object.
      If the Compression field of the BitmapInfoHeader Object is set to BI_BITFIELDS, the Colors field contains three DWORD color masks that specify the red, green, and blue components, respectively, of each pixel. Each DWORD in the bitmap array represents a single pixel.
      When the Compression field is set to BI_BITFIELDS, bits set in each DWORD mask must be contiguous and should not overlap the bits of another mask. All the bits in the pixel do not need to be used.

  - ### Method Detail

    - #### values

          public static HwmfBitmapDib.BitCount[] values()

      Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:

          for (HwmfBitmapDib.BitCount c : HwmfBitmapDib.BitCount.values())
              System.out.println(c);

      Returns:
        an array containing the constants of this enum type, in the order they are declared

    - #### valueOf

          public static HwmfBitmapDib.BitCount valueOf(java.lang.String name)

      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
        `name` - the name of the enum constant to be returned.
      Returns:
        the enum constant with the specified name
      Throws:
        `java.lang.IllegalArgumentException` - if this enum type has no constant with the specified name
        `java.lang.NullPointerException` - if the argument is null

Copyright 2020 The Apache Software Foundation or its licensors, as applicable.