mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-06-02 18:07:40 +00:00
Revert "Switch pixel format loss fields to number of bits"
This reverts commit 3c90b1c1f6
.
It turns out this is problematic for sdl2-compat. We're investigating a more complete separation between SDL2 and SDL3 surfaces, but in the meantime, I'll fix the breakage.
This commit is contained in:
parent
18c9bd21b5
commit
4fa5196820
9 changed files with 76 additions and 88 deletions
|
@ -175,11 +175,6 @@ static int pixels_allocFreeFormat(void *arg)
|
|||
if (!SDL_ISPIXELFORMAT_INDEXED(format)) {
|
||||
masks = result->Rmask | result->Gmask | result->Bmask | result->Amask;
|
||||
SDLTest_AssertCheck(masks > 0, "Verify value of result.[RGBA]mask combined; expected: >0, got %" SDL_PRIu32, masks);
|
||||
if (SDL_ISPIXELFORMAT_10BIT(format)) {
|
||||
SDLTest_AssertCheck(result->Rbits == 10 && result->Gbits == 10 && result->Bbits == 10, "Verify value of result.[RGB]bits; expected: 10, got %d/%d/%d", result->Rbits, result->Gbits, result->Bbits);
|
||||
} else if (SDL_BITSPERPIXEL(format) == 32) {
|
||||
SDLTest_AssertCheck(result->Rbits == 8 && result->Gbits == 8 && result->Bbits == 8, "Verify value of result.[RGB]bits; expected: 8, got %d/%d/%d", result->Rbits, result->Gbits, result->Bbits);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue