Package com.ms.com.directX Previous
Previous
Microsoft Packages
Microsoft Packages
Index
Index
Next
Next

Class PaletteEntry

, Constructors

public final class PaletteEntry {
  public byte peRed;
  public byte peGreen;
  public byte peBlue;
  public byte peFlags;

  public PaletteEntry();
  public PaletteEntry(byte[] b, int count, int flags);
}

Specifies a color palette entry when create palettes using the CreatePalette method.

Note that the fields of this class take values indicating the intensity of red, green, or blue. Intensity values are unsigned values in the range 0 to 255, unlike byte values which range from -128 to 127. When assigning intensity values to these fields, you may need to cast such values to byte type.

Fields

peRed
Intensity of red.
peGreen
Intensity of green.
peBlue
Intensity of blue.
peFlags
One value of D3DPAL_ type.


Constructors


PaletteEntry

 public PaletteEntry();

Creates an uninitialized palette entry object.


PaletteEntry

public PaletteEntry(byte[] b, int count, int flags);

Creates an initialized palette entry object.

ParameterDescription
b Array variable that contains the initial palette entry data. The data must be in the order: red intensity, green intensity, blue intensity, and flags.
count Index into b of palette entry data for this object.
flags Can be 0 or DDPCAPS_8BITENTRIES.

Remarks:

Although b can contain data for more than one palette entry, count specifies which data to use to initialize the object being created.



Top© 1996 Microsoft Corporation. All rights reserved.