More coding style fixes.
This commit is contained in:
parent
0cd27a511e
commit
79bb403089
3 changed files with 14 additions and 8 deletions
|
@ -131,16 +131,22 @@ struct Regs {
|
|||
};
|
||||
|
||||
static unsigned BytesPerPixel(TextureFormat format) {
|
||||
if (format == TextureFormat::RGBA8)
|
||||
switch (format) {
|
||||
case TextureFormat::RGBA8:
|
||||
return 4;
|
||||
else if (format == TextureFormat::RGB8)
|
||||
|
||||
case TextureFormat::RGB8:
|
||||
return 3;
|
||||
else if (format == TextureFormat::RGBA5551 ||
|
||||
format == TextureFormat::RGB565 ||
|
||||
format == TextureFormat::RGBA4)
|
||||
|
||||
case TextureFormat::RGBA5551:
|
||||
case TextureFormat::RGB565:
|
||||
case TextureFormat::RGBA4:
|
||||
return 2;
|
||||
else // placeholder
|
||||
|
||||
default:
|
||||
// placeholder for yet unknown formats
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
|
||||
BitField< 0, 1, u32> texturing_enable;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue