summaryrefslogtreecommitdiff
path: root/src/code
diff options
context:
space:
mode:
Diffstat (limited to 'src/code')
-rw-r--r--src/code/z_vismono.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/code/z_vismono.c b/src/code/z_vismono.c
index b0c91de60..b169f5b02 100644
--- a/src/code/z_vismono.c
+++ b/src/code/z_vismono.c
@@ -96,8 +96,7 @@ Gfx* VisMono_DesaturateDList(VisMono* this, Gfx* gfx) {
// Its position in texture image space is shifted along +S by 2
gDPSetTile(gfx++, G_IM_FMT_CI, G_IM_SIZ_8b, SCREEN_WIDTH * 2 * G_IM_SIZ_8b_LINE_BYTES / 8, 0x0, G_TX_RENDERTILE,
0, G_TX_NOMIRROR | G_TX_CLAMP, 0, 0, G_TX_NOMIRROR | G_TX_CLAMP, 0, 0);
- gDPSetTileSize(gfx++, G_TX_RENDERTILE, 2 << 2, 0, (SCREEN_WIDTH * 2 + 1) << 2,
- (VISMONO_CFBFRAG_HEIGHT - 1) << 2);
+ gDPSetTileSize(gfx++, G_TX_RENDERTILE, 2 << 2, 0, ((SCREEN_WIDTH * 2) + 1) << 2, (height - 1) << 2);
// Set texel 1 to be a CI8 image with width `SCREEN_WIDTH * 2` and height `VISMONO_CFBFRAG_HEIGHT`
// Its position in texture image space is shifted along +S by 1
@@ -105,7 +104,7 @@ Gfx* VisMono_DesaturateDList(VisMono* this, Gfx* gfx) {
// ignored for CI8 texture sampling.
gDPSetTile(gfx++, G_IM_FMT_CI, G_IM_SIZ_8b, SCREEN_WIDTH * 2 * G_IM_SIZ_8b_LINE_BYTES / 8, 0x0, 1, 1,
G_TX_NOMIRROR | G_TX_CLAMP, 0, 0, G_TX_NOMIRROR | G_TX_CLAMP, 0, 0);
- gDPSetTileSize(gfx++, 1, 1 << 2, 0, (SCREEN_WIDTH * 2) << 2, (VISMONO_CFBFRAG_HEIGHT - 1) << 2);
+ gDPSetTileSize(gfx++, 1, 1 << 2, 0, (SCREEN_WIDTH * 2) << 2, (height - 1) << 2);
// Draw a `SCREEN_WIDTH` wide, `height` high rectangle.
// Texture coordinate T (vertical) starts at 0 and changes by one each line (dtdy = 1)