10 if (SDL_MUSTLOCK(surface)) {
12 SDL_LockSurface(surface);
18 if (SDL_MUSTLOCK(surface)) {
19 SDL_UnlockSurface(surface);
26 auto bpp =
format.BitsPerPixel;
29 auto Rshift =
format.Rshift;
33 auto Gshift =
format.Gshift;
37 auto Bshift =
format.Bshift;
41 auto Ashift =
format.Ashift;
47 if (bpp == 32 && Amask == 0) {
48 unsigned rgbMask = Rmask | Gmask | Bmask;
49 if ((rgbMask & 0x000000FF) == 0) {
53 }
else if ((rgbMask & 0xFF000000) == 0) {
66 Amask, Ashift, Aloss));
void setPixelFormat(const PixelFormat &format)
SDLDirectPixelAccess(SDL_Surface *surface_)
void setSDLPixelFormat(const SDL_PixelFormat &format)
void format(SectorAccessibleDisk &disk, MSXBootSectorType bootType)
Format the given disk (= a single partition).
This file implemented 3 utility functions: