all repos — mgba @ d05f513a17098d4128caa6581aff9af49aaf0d05

mGBA Game Boy Advance Emulator

Wii: Clear texture on game load
Jeffrey Pfau jeffrey@endrift.com
Thu, 01 Sep 2016 01:27:06 -0700
commit

d05f513a17098d4128caa6581aff9af49aaf0d05

parent

e159029e48902a642c39d427345951c388d93da5

1 files changed, 1 insertions(+), 2 deletions(-)

jump to
M src/platform/wii/main.csrc/platform/wii/main.c

@@ -284,10 +284,8 @@ guMtxConcat(view, model, modelview);

GX_LoadPosMtxImm(modelview, GX_PNMTX0); texmem = memalign(32, TEX_W * TEX_H * BYTES_PER_PIXEL); - memset(texmem, 0, TEX_W * TEX_H * BYTES_PER_PIXEL); GX_InitTexObj(&tex, texmem, TEX_W, TEX_H, GX_TF_RGB565, GX_CLAMP, GX_CLAMP, GX_FALSE); rescaleTexmem = memalign(32, TEX_W * TEX_H * 4 * BYTES_PER_PIXEL); - memset(rescaleTexmem, 0, TEX_W * TEX_H * 4 * BYTES_PER_PIXEL); GX_InitTexObj(&rescaleTex, rescaleTexmem, TEX_W * 2, TEX_H * 2, GX_TF_RGB565, GX_CLAMP, GX_CLAMP, GX_FALSE); GX_InitTexObjFilterMode(&rescaleTex, GX_LINEAR, GX_LINEAR);

@@ -718,6 +716,7 @@ }

sleep(1); } } + memset(texmem, 0, TEX_W * TEX_H * BYTES_PER_PIXEL); _unpaused(runner); }