diff --git a/CHANGES b/CHANGES index 83eeba724..5e7dd6f05 100644 --- a/CHANGES +++ b/CHANGES @@ -65,6 +65,7 @@ Emulation fixes: - GBA Video: Emulate sprite cycle limits in OpenGL renderer (fixes mgba.io/i/1635) - GBA Video: Fix OBJWIN erratic rendering in OpenGL renderer - GBA Video: Fix x offset in 256-color BG mosaic (fixes mgba.io/i/1684) + - GBA Video: Fix transposed BG mosaic parameters in GL renderer - SM83: Emulate HALT bug - SM83: Improve mid-M-cycle interrupts - SM83: HALT should not consume an extra T-state diff --git a/src/gba/renderers/gl.c b/src/gba/renderers/gl.c index 283d602f0..49653a268 100644 --- a/src/gba/renderers/gl.c +++ b/src/gba/renderers/gl.c @@ -1818,7 +1818,7 @@ void _prepareBackground(struct GBAVideoGLRenderer* renderer, struct GBAVideoGLBa glUniform1i(uniforms[GBA_GL_BG_VRAM], 0); glUniform1i(uniforms[GBA_GL_OBJ_PALETTE], 1); if (background->mosaic) { - glUniform2i(uniforms[GBA_GL_BG_MOSAIC], GBAMosaicControlGetBgV(renderer->mosaic) + 1, GBAMosaicControlGetBgH(renderer->mosaic) + 1); + glUniform2i(uniforms[GBA_GL_BG_MOSAIC], GBAMosaicControlGetBgH(renderer->mosaic) + 1, GBAMosaicControlGetBgV(renderer->mosaic) + 1); } else { glUniform2i(uniforms[GBA_GL_BG_MOSAIC], 0, 0); }