Home | All Classes | Grouped Classes | Index | Search

Class CL_PixelFormat

Pixel data format description. More...

Derived from: none
Derived by: none
Group: Display (Display 2D)

#include <ClanLib/display.h>

Construction:

CL_PixelFormat

Constructs a pixel format description.

Attributes:

operator ==

Returns true if this pixel format is the same as the other one.

operator !=

Returns true if this pixel format is not the same as the other one.

get_type

Returns the pixel format type (RGB or Indexed).

has_colorkey

Returns true if format uses a source color key.

get_depth

Returns the depth of the pixel format.

get_colorkey

Returns the source color key.

get_red_mask

Returns the red component color mask.

get_green_mask

Returns the green component color mask.

get_blue_mask

Returns the blue component color mask.

get_alpha_mask

Returns the alpha component color mask.

Statics:

rgba8888 static

Pixel format with 32 bit depth, 8 bits per color mask.

rgb888 static

Pixel format with 24 bit depth, 8 bits per color mask, no alpha.

rgba4444 static

Pixel format with 16 bit depth, 4 bits per color mask.

rgb555 static

Pixel format with 16 bit depth, 5 bits per color mask, one bit unused.

rgb565 static

Pixel format with 16 bit depth, 5 bits for red and blue, 6 bits for green.

abgr8888 static

Pixel format with 32 bit depth, 8 bits per color mask.

bgr888 static

Pixel format with 24 bit depth, 8 bits per color mask, no alpha.

abgr4444 static

Pixel format with 16 bit depth, 4 bits per color mask.

bgr555 static

Pixel format with 16 bit depth, 5 bits per color mask, one bit unused.

bgr565 static

Pixel format with 16 bit depth, 5 bits for red and blue, 6 bits for green.

get_mask_shift

Returns the shift of a color mask.

get_mask_bits

Returns the bit count of a color mask.

get_bitmask

Returns the color mask based on bit count and shift.

Operations:

set_type

Sets the pixel format type (RGB or Indexed).

enable_colorkey

Enable/disable color key.

set_colorkey

Sets the color key.

set_depth

Sets the depth of the pixel format.

set_red_mask

Sets the red component color mask.

set_green_mask

Sets the green component color mask.

set_blue_mask

Sets the blue component color mask.

set_alpha_mask

Sets the alpha component color mask.

Detailed description:

!group=Display/Display 2D! !header=display.h!


Questions or comments, write to the
ClanLib mailing list.