/// <summary>The type of compression for a compressed bottom-up bitmap (top-down DIBs cannot be compressed). Used in <see cref="BITMAPINFOHEADER"/>.</summary>
/// A run-length encoded (RLE) format for bitmaps with 8 bpp. The compression format is a 2-byte format consisting of a count byte followed by a byte
/// containing a color index.
/// </summary>
BI_RLE8=1,
/// <summary>
/// An RLE format for bitmaps with 4 bpp. The compression format is a 2-byte format consisting of a count byte followed by two word-length color indexes.
/// </summary>
BI_RLE4=2,
/// <summary>
/// Specifies that the bitmap is not compressed and that the color table consists of three DWORD color masks that specify the red, green, and blue
/// components, respectively, of each pixel. This is valid when used with 16- and 32-bpp bitmaps.
/// </summary>
BI_BITFIELDS=3,
/// <summary>Indicates that the image is a JPEG image.</summary>
BI_JPEG=4,
/// <summary>Indicates that the image is a PNG image.</summary>
/// <summary>The BITMAPINFO structure defines the dimensions and color information for a DIB.</summary>
/// <remarks>
/// A DIB consists of two distinct parts: a BITMAPINFO structure describing the dimensions and colors of the bitmap, and an array of bytes defining the
/// pixels of the bitmap. The bits in the array are packed together, but each scan line must be padded with zeros to end on a LONG data-type boundary. If
/// the height of the bitmap is positive, the bitmap is a bottom-up DIB and its origin is the lower-left corner. If the height is negative, the bitmap is
/// a top-down DIB and its origin is the upper left corner.
/// <para>
/// A bitmap is packed when the bitmap array immediately follows the BITMAPINFO header. Packed bitmaps are referenced by a single pointer. For packed
/// bitmaps, the biClrUsed member must be set to an even number when using the DIB_PAL_COLORS mode so that the DIB bitmap array starts on a DWORD boundary.
/// </para>
/// <para><c>Note</c></para>
/// <para>The bmiColors member should not contain palette indexes if the bitmap is to be stored in a file or transferred to another application.</para>
/// <para>Unless the application has exclusive use and control of the bitmap, the bitmap color table should contain explicit RGB values.</para>
/// <summary>The number of bytes required by the structure.</summary>
publicintbiSize;
/// <summary>
/// The width of the bitmap, in pixels. If biCompression is BI_JPEG or BI_PNG, the biWidth member specifies the width of the decompressed JPEG or PNG
/// image file, respectively.
/// </summary>
publicintbiWidth;
/// <summary>
/// The height of the bitmap, in pixels. If biHeight is positive, the bitmap is a bottom-up DIB and its origin is the lower-left corner. If biHeight
/// is negative, the bitmap is a top-down DIB and its origin is the upper-left corner.
/// <para>If biHeight is negative, indicating a top-down DIB, biCompression must be either BI_RGB or BI_BITFIELDS. Top-down DIBs cannot be compressed.</para>
/// <para>If biCompression is BI_JPEG or BI_PNG, the biHeight member specifies the height of the decompressed JPEG or PNG image file, respectively.</para>
/// </summary>
publicintbiHeight;
/// <summary>The number of planes for the target device. This value must be set to 1.</summary>
publicushortbiPlanes;
/// <summary>
/// The number of bits-per-pixel. The biBitCount member of the BITMAPINFOHEADER structure determines the number of bits that define each pixel and
/// the maximum number of colors in the bitmap. This member must be one of the following values.
/// <list type="table">
/// <listheader>
/// <term>Value</term>
/// <description>Meaning</description>
/// </listheader>
/// <item>
/// <term>0</term>
/// <description>The number of bits-per-pixel is specified or is implied by the JPEG or PNG format.</description>
/// </item>
/// <item>
/// <term>1</term>
/// <description>
/// The bitmap is monochrome, and the bmiColors member of BITMAPINFO contains two entries. Each bit in the bitmap array represents a pixel. If the
/// bit is clear, the pixel is displayed with the color of the first entry in the bmiColors table; if the bit is set, the pixel has the color of the
/// second entry in the table.
/// </description>
/// </item>
/// <item>
/// <term>4</term>
/// <description>
/// The bitmap has a maximum of 16 colors, and the bmiColors member of BITMAPINFO contains up to 16 entries. Each pixel in the bitmap is represented
/// by a 4-bit index into the color table. For example, if the first byte in the bitmap is 0x1F, the byte represents two pixels. The first pixel
/// contains the color in the second table entry, and the second pixel contains the color in the sixteenth table entry.
/// </description>
/// </item>
/// <item>
/// <term>8</term>
/// <description>
/// The bitmap has a maximum of 256 colors, and the bmiColors member of BITMAPINFO contains up to 256 entries. In this case, each byte in the array
/// represents a single pixel.
/// </description>
/// </item>
/// <item>
/// <term>16</term>
/// <description>
/// The bitmap has a maximum of 2^16 colors. If the biCompression member of the BITMAPINFOHEADER is BI_RGB, the bmiColors member of BITMAPINFO is
/// NULL. Each WORD in the bitmap array represents a single pixel. The relative intensities of red, green, and blue are represented with five bits
/// for each color component. The value for blue is in the least significant five bits, followed by five bits each for green and red. The most
/// significant bit is not used. The bmiColors color table is used for optimizing colors used on palette-based devices, and must contain the number
/// of entries specified by the biClrUsed member of the BITMAPINFOHEADER.
/// <para>
/// If the biCompression member of the BITMAPINFOHEADER is BI_BITFIELDS, the bmiColors member 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.
/// </para>
/// <para>
/// When the biCompression member is 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 have to be used.
/// </para>
/// </description>
/// </item>
/// <item>
/// <term>24</term>
/// <description>
/// The bitmap has a maximum of 2^24 colors, and the bmiColors member of BITMAPINFO is NULL. Each 3-byte triplet in the bitmap array represents the
/// relative intensities of blue, green, and red, respectively, for a pixel. The bmiColors color table is used for optimizing colors used on
/// palette-based devices, and must contain the number of entries specified by the biClrUsed member of the BITMAPINFOHEADER.
/// </description>
/// </item>
/// <item>
/// <term>32</term>
/// <description>
/// The bitmap has a maximum of 2^32 colors. If the biCompression member of the BITMAPINFOHEADER is BI_RGB, the bmiColors member of BITMAPINFO is
/// NULL. Each DWORD in the bitmap array represents the relative intensities of blue, green, and red for a pixel. The value for blue is in the least
/// significant 8 bits, followed by 8 bits each for green and red. The high byte in each DWORD is not used. The bmiColors color table is used for
/// optimizing colors used on palette-based devices, and must contain the number of entries specified by the biClrUsed member of the BITMAPINFOHEADER.
/// <para>
/// If the biCompression member of the BITMAPINFOHEADER is BI_BITFIELDS, the bmiColors member 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.
/// </para>
/// <para>
/// When the biCompression member is 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.
/// </para>
/// </description>
/// </item>
/// </list>
/// </summary>
publicushortbiBitCount;
/// <summary>The type of compression for a compressed bottom-up bitmap (top-down DIBs cannot be compressed).</summary>
publicBitmapCompressionModebiCompression;
/// <summary>
/// The size, in bytes, of the image. This may be set to zero for BI_RGB bitmaps. If biCompression is BI_JPEG or BI_PNG, biSizeImage indicates the
/// size of the JPEG or PNG image buffer, respectively.
/// </summary>
publicuintbiSizeImage;
/// <summary>
/// The horizontal resolution, in pixels-per-meter, of the target device for the bitmap. An application can use this value to select a bitmap from a
/// resource group that best matches the characteristics of the current device.
/// </summary>
publicintbiXPelsPerMeter;
/// <summary>The vertical resolution, in pixels-per-meter, of the target device for the bitmap.</summary>
publicintbiYPelsPerMeter;
/// <summary>
/// The number of color indexes in the color table that are actually used by the bitmap. If this value is zero, the bitmap uses the maximum number of
/// colors corresponding to the value of the biBitCount member for the compression mode specified by biCompression.
/// <para>
/// If biClrUsed is nonzero and the biBitCount member is less than 16, the biClrUsed member specifies the actual number of colors the graphics engine
/// or device driver accesses. If biBitCount is 16 or greater, the biClrUsed member specifies the size of the color table used to optimize
/// performance of the system color palettes. If biBitCount equals 16 or 32, the optimal color palette starts immediately following the three DWORD masks.
/// </para>
/// <para>
/// When the bitmap array immediately follows the BITMAPINFO structure, it is a packed bitmap. Packed bitmaps are referenced by a single pointer.
/// Packed bitmaps require that the biClrUsed member must be either zero or the actual size of the color table.
/// </para>
/// </summary>
publicuintbiClrUsed;
/// <summary>The number of color indexes that are required for displaying the bitmap. If this value is zero, all colors are required.</summary>
/// The DSH sectionContains a handle to the file mapping object that the CreateDIBSection function used to create the DIB. If CreateDIBSection was
/// called with a NULL value for its hSection parameter, causing the system to allocate memory for the bitmap, the dshSection member will be NULL.
/// </summary>
publicIntPtrdshSection;
/// <summary>
/// The offset to the bitmap's bit values within the file mapping object referenced by dshSection. If dshSection is NULL, the dsOffset value has no meaning.