|
NAMESDLmm::PixelFormat -SYNOPSIS#include <sdlmm_pixelformat.h> Public MethodsPixelFormat (SDL_PixelFormat *pixelformat) Constructor from an SDL_PixelFormat*. virtual ~PixelFormat () The destructor. Uint8 BitsPerPixel () const Uint8 BytesPerPixel () const Uint8 Rshift () const Uint8 Gshift () const Uint8 Bshift () const Uint8 Rloss () const Uint8 Gloss () const Uint8 Bloss () const Uint8 Aloss () const Uint32 Rmask () const Uint32 Gmask () const Uint32 Bmask () const Uint32 Amask () const Color colorkey () const Uint8 alpha () const SDL_Palette* palette () const Color MapRGB (Uint8 r, Uint8 g, Uint8 b) const Map a RGB color value to a pixel format. Color MapRGB (const ColorRGB &colorrgb) const Color MapRGBA (Uint8 r, Uint8 g, Uint8 b, Uint8 a) const Map a RGBA color value to a pixel format. Color MapRGBA (const ColorRGBA &colorrgba) const void GetRGB (Color pixel, Uint8 &r, Uint8 &g, Uint8 &b) const Get RGB values from a pixel in the pixel format of this PixelFormat . const ColorRGB GetRGB (Color pixel) const void GetRGBA (Color pixel, Uint8 &r, Uint8 &g, Uint8 &b, Uint8 &a) const Get RGBA values from a pixel in the pixel format of this PixelFormat . const ColorRGBA GetRGBA (Color pixel) const Informational methods
Protected AttributesSDL_PixelFormat* me The actual SDL_PixelFormat for this PixelFormat. DETAILED DESCRIPTIONAuthor:Adam Gates CONSTRUCTOR & DESTRUCTOR DOCUMENTATIONSDLmm::PixelFormat::PixelFormat (SDL_PixelFormat * pixelformat) [inline, explicit]Constructor from an SDL_PixelFormat*.This creates a new PixelFormat object from an existing SDL_PixelFormat. It's very important not to free the original pixel format since that will cause problems. Use with caution. SDLmm::PixelFormat::~PixelFormat () [inline, virtual]The destructor.MEMBER FUNCTION DOCUMENTATIONUint8 SDLmm::PixelFormat::Aloss () const [inline]Uint32 SDLmm::PixelFormat::Amask () const [inline]Uint8 SDLmm::PixelFormat::BitsPerPixel () const [inline]Uint8 SDLmm::PixelFormat::Bloss () const [inline]Uint32 SDLmm::PixelFormat::Bmask () const [inline]Uint8 SDLmm::PixelFormat::Bshift () const [inline]Uint8 SDLmm::PixelFormat::BytesPerPixel () const [inline]const ColorRGB SDLmm::PixelFormat::GetRGB (Color pixel) const [inline]void SDLmm::PixelFormat::GetRGB (Color pixel, Uint8 & r, Uint8 & g, Uint8 & b) constGet RGB values from a pixel in the pixel format of this PixelFormat.This function uses the entire 8-bit [0..255] range when converting color components from pixel formats with less than 8-bits per RGB component (e.g., a completely white pixel in 16-bit RGB565 format would return [0xff, 0xff, 0xff] not [0xf8, 0xfc, 0xf8]). Parameters:
See also:
const ColorRGBA SDLmm::PixelFormat::GetRGBA (Color pixel) const [inline]void SDLmm::PixelFormat::GetRGBA (Color pixel, Uint8 & r, Uint8 & g, Uint8 & b, Uint8 & a) constGet RGBA values from a pixel in the pixel format of this PixelFormat.This function uses the entire 8-bit [0..255] range when converting color components from pixel formats with less than 8-bits per RGB component (e.g., a completely white pixel in 16-bit RGB565 format would return [0xff, 0xff, 0xff] not [0xf8, 0xfc, 0xf8]). Note:
Parameters:
See also:
Uint8 SDLmm::PixelFormat::Gloss () const [inline]Uint32 SDLmm::PixelFormat::Gmask () const [inline]Uint8 SDLmm::PixelFormat::Gshift () const [inline]Color SDLmm::PixelFormat::MapRGB (const ColorRGB & colorrgb) const [inline]Color SDLmm::PixelFormat::MapRGB (Uint8 r, Uint8 g, Uint8 b) constMap a RGB color value to a pixel format.Maps the RGB color value to this PixelFormat's pixel format and returns the pixel value as a 32-bit int. If the format has a palette (8-bit) the index of the closest matching color in the palette will be returned. If the specified pixel format has an alpha component it will be returned as all 1 bits (fully opaque). Returns:
Parameters:
See also:
Color SDLmm::PixelFormat::MapRGBA (const ColorRGBA & colorrgba) const [inline]Color SDLmm::PixelFormat::MapRGBA (Uint8 r, Uint8 g, Uint8 b, Uint8 a) constMap a RGBA color value to a pixel format.Maps the RGBA color value to this PixelFormat's pixel format and returns the pixel value as a 32-bit int. If the format has a palette (8-bit) the index of the closest matching color in the palette will be returned. If the specified pixel format has no alpha component the alpha value will be ignored (as it will be in formats with a palette). Returns:
Parameters:
See also:
Uint8 SDLmm::PixelFormat::Rloss () const [inline]Uint32 SDLmm::PixelFormat::Rmask () const [inline]Uint8 SDLmm::PixelFormat::Rshift () const [inline]Uint8 SDLmm::PixelFormat::alpha () const [inline]Color SDLmm::PixelFormat::colorkey () const [inline]SDL_Palette * SDLmm::PixelFormat::palette () const [inline]bool SDLmm::PixelFormat::valid () const [inline]Returns true if this PixelFormat is initialized, false otherwise.Warning:
MEMBER DATA DOCUMENTATIONSDL_PixelFormat * SDLmm::PixelFormat::me [protected]The actual SDL_PixelFormat for this PixelFormat.AUTHORGenerated automatically by Doxygen for SDLmm from the source code.
Visit the GSP FreeBSD Man Page Interface. |