mirror of
https://github.com/yuzu-emu/yuzu.git
synced 2024-11-16 00:40:05 +00:00
Use default values for unknown framebuffer pixel format
This commit is contained in:
parent
b6d2c64f4d
commit
0a9fedfac9
@ -17,6 +17,8 @@ u32 FramebufferConfig::BytesPerPixel(PixelFormat format) {
|
|||||||
switch (format) {
|
switch (format) {
|
||||||
case PixelFormat::ABGR8:
|
case PixelFormat::ABGR8:
|
||||||
return 4;
|
return 4;
|
||||||
|
default:
|
||||||
|
return 4;
|
||||||
}
|
}
|
||||||
|
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
|
@ -304,6 +304,12 @@ void RendererOpenGL::ConfigureFramebufferTexture(TextureInfo& texture,
|
|||||||
gl_framebuffer_data.resize(texture.width * texture.height * 4);
|
gl_framebuffer_data.resize(texture.width * texture.height * 4);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
internal_format = GL_RGBA;
|
||||||
|
texture.gl_format = GL_RGBA;
|
||||||
|
texture.gl_type = GL_UNSIGNED_INT_8_8_8_8_REV;
|
||||||
|
gl_framebuffer_data.resize(texture.width * texture.height * 4);
|
||||||
|
LOG_CRITICAL(Render_OpenGL, "Unknown framebuffer pixel format: {}",
|
||||||
|
static_cast<u32>(framebuffer.pixel_format));
|
||||||
UNREACHABLE();
|
UNREACHABLE();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user