diff options
| author | 2023-01-06 15:20:23 -0500 | |
|---|---|---|
| committer | 2023-01-06 15:20:23 -0500 | |
| commit | c0f17e1b272a4f235707c9e1a67f009d4ccd05f7 (patch) | |
| tree | 595912548c52bc434c46d20c0bcb9fb5c3084b4e | |
| parent | Merge pull request #9566 from Wollnashorn/vulkan-cache-header-fix (diff) | |
| parent | opengl: Sanitize antialiasing config (diff) | |
| download | yuzu-c0f17e1b272a4f235707c9e1a67f009d4ccd05f7.tar.gz yuzu-c0f17e1b272a4f235707c9e1a67f009d4ccd05f7.tar.xz yuzu-c0f17e1b272a4f235707c9e1a67f009d4ccd05f7.zip | |
Merge pull request #9567 from german77/antialias
opengl: Sanitize antialiasing config
| -rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/video_core/renderer_opengl/renderer_opengl.cpp b/src/video_core/renderer_opengl/renderer_opengl.cpp index bc75680f0..de95f2634 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.cpp +++ b/src/video_core/renderer_opengl/renderer_opengl.cpp | |||
| @@ -442,7 +442,13 @@ void RendererOpenGL::DrawScreen(const Layout::FramebufferLayout& layout) { | |||
| 442 | 442 | ||
| 443 | glBindTextureUnit(0, screen_info.display_texture); | 443 | glBindTextureUnit(0, screen_info.display_texture); |
| 444 | 444 | ||
| 445 | const auto anti_aliasing = Settings::values.anti_aliasing.GetValue(); | 445 | auto anti_aliasing = Settings::values.anti_aliasing.GetValue(); |
| 446 | if (anti_aliasing > Settings::AntiAliasing::LastAA) { | ||
| 447 | LOG_ERROR(Render_OpenGL, "Invalid antialiasing option selected {}", anti_aliasing); | ||
| 448 | anti_aliasing = Settings::AntiAliasing::None; | ||
| 449 | Settings::values.anti_aliasing.SetValue(anti_aliasing); | ||
| 450 | } | ||
| 451 | |||
| 446 | if (anti_aliasing != Settings::AntiAliasing::None) { | 452 | if (anti_aliasing != Settings::AntiAliasing::None) { |
| 447 | glEnablei(GL_SCISSOR_TEST, 0); | 453 | glEnablei(GL_SCISSOR_TEST, 0); |
| 448 | auto viewport_width = screen_info.texture.width; | 454 | auto viewport_width = screen_info.texture.width; |