From 20e65aee2fad1a219344f5d0ab23f63522df5628 Mon Sep 17 00:00:00 2001 From: bkaradzic Date: Tue, 5 Jun 2012 22:22:24 -0700 Subject: [PATCH] Just use the last available MSAA type when higher type is not available. --- src/renderer_d3d9.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/renderer_d3d9.cpp b/src/renderer_d3d9.cpp index acc01834..10318b9a 100644 --- a/src/renderer_d3d9.cpp +++ b/src/renderer_d3d9.cpp @@ -334,7 +334,7 @@ namespace bgfx void updateMsaa() { - for (uint32_t ii = 1; ii < countof(s_checkMsaa); ++ii) + for (uint32_t ii = 1, last = 0; ii < countof(s_checkMsaa); ++ii) { D3DMULTISAMPLE_TYPE msaa = s_checkMsaa[ii]; DWORD quality; @@ -351,11 +351,11 @@ namespace bgfx { s_msaa[ii].m_type = msaa; s_msaa[ii].m_quality = uint32_imax(0, quality-1); + last = ii; } else { - s_msaa[ii].m_type = D3DMULTISAMPLE_NONE; - s_msaa[ii].m_quality = 0; + s_msaa[ii] = s_msaa[last]; } } }