aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNitrus2018-11-20 18:59:17 +0100
committerDavid Turner2018-11-21 07:54:49 +0000
commit92ab8328b19a3a75deedc9a088d609dd77b72b97 (patch)
tree6f154027d9bdab023db403d341004ef44059cd57
parenta4f85955fe748b9e6e33dbb684c8efbc2cf4899b (diff)
downloadscummvm-rg350-92ab8328b19a3a75deedc9a088d609dd77b72b97.tar.gz
scummvm-rg350-92ab8328b19a3a75deedc9a088d609dd77b72b97.tar.bz2
scummvm-rg350-92ab8328b19a3a75deedc9a088d609dd77b72b97.zip
3DS: Clear render target on each frame
...in order to clear framebuffer artifacts in case the screen is not stretched.
-rw-r--r--backends/platform/3ds/osystem-graphics.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/backends/platform/3ds/osystem-graphics.cpp b/backends/platform/3ds/osystem-graphics.cpp
index 777272e1d9..ebc1b8c7ed 100644
--- a/backends/platform/3ds/osystem-graphics.cpp
+++ b/backends/platform/3ds/osystem-graphics.cpp
@@ -273,6 +273,7 @@ void OSystem_3DS::updateScreen() {
C3D_FrameBegin(C3D_FRAME_SYNCDRAW);
// Render top screen
+ C3D_RenderTargetClear(_renderTargetTop, C3D_CLEAR_ALL, 0x00000000, 0);
C3D_FrameDrawOn(_renderTargetTop);
if (config.screen == kScreenTop || config.screen == kScreenBoth) {
C3D_FVUnifMtx4x4(GPU_VERTEX_SHADER, _projectionLocation, &_projectionTop);
@@ -290,6 +291,7 @@ void OSystem_3DS::updateScreen() {
}
// Render bottom screen
+ C3D_RenderTargetClear(_renderTargetBottom, C3D_CLEAR_ALL, 0x00000000, 0);
C3D_FrameDrawOn(_renderTargetBottom);
if (config.screen == kScreenBottom || config.screen == kScreenBoth) {
C3D_FVUnifMtx4x4(GPU_VERTEX_SHADER, _projectionLocation, &_projectionBottom);