From ebc1a4397c703834d666be569e6e1a505083a0d1 Mon Sep 17 00:00:00 2001 From: zilmar Date: Fri, 18 Aug 2017 17:55:06 +1000 Subject: [PATCH] [Video] Remove voodoo.sup_mirroring --- Source/Project64-video/Main.cpp | 10 ---------- Source/Project64-video/TexCache.cpp | 9 ++++----- Source/Project64-video/rdp.h | 1 - 3 files changed, 4 insertions(+), 16 deletions(-) diff --git a/Source/Project64-video/Main.cpp b/Source/Project64-video/Main.cpp index 392d7bc7f..bb845024a 100644 --- a/Source/Project64-video/Main.cpp +++ b/Source/Project64-video/Main.cpp @@ -460,12 +460,6 @@ int InitGfx() voodoo.tex_min_addr[0] = voodoo.tex_min_addr[1] = gfxTexMinAddress(GFX_TMU0); voodoo.tex_max_addr[0] = voodoo.tex_max_addr[1] = gfxTexMaxAddress(GFX_TMU0); - // Is mirroring allowed? - if (!g_settings->hacks(CSettings::hack_Zelda)) //zelda's trees suffer from hardware mirroring - voodoo.sup_mirroring = 1; - else - voodoo.sup_mirroring = 0; - voodoo.sup_32bit_tex = TRUE; voodoo.gamma_correction = 0; voodoo.gamma_table_size = 256; @@ -566,10 +560,6 @@ int InitGfx() DisplayLoadProgress); } } - if (g_ghq_use) - { - voodoo.sup_mirroring = 1; - } return TRUE; } diff --git a/Source/Project64-video/TexCache.cpp b/Source/Project64-video/TexCache.cpp index 49f919044..9f774c82b 100644 --- a/Source/Project64-video/TexCache.cpp +++ b/Source/Project64-video/TexCache.cpp @@ -849,7 +849,7 @@ void TexCache() mode_s = GFX_TEXTURECLAMP_CLAMP; else { - if (rdp.tiles(tile).mirror_s && voodoo.sup_mirroring) + if (rdp.tiles(tile).mirror_s && !g_settings->hacks(CSettings::hack_Zelda)) mode_s = GFX_TEXTURECLAMP_MIRROR_EXT; else mode_s = GFX_TEXTURECLAMP_WRAP; @@ -863,7 +863,7 @@ void TexCache() mode_t = GFX_TEXTURECLAMP_CLAMP; else { - if (rdp.tiles(tile).mirror_t && voodoo.sup_mirroring) + if (rdp.tiles(tile).mirror_t && !g_settings->hacks(CSettings::hack_Zelda)) mode_t = GFX_TEXTURECLAMP_MIRROR_EXT; else mode_t = GFX_TEXTURECLAMP_WRAP; @@ -998,8 +998,7 @@ void LoadTex(int id, gfxChipID_t tmu) for (shift = 0; (1 << shift) < (int)size_y; shift++); size_y = 1 << shift; - // Voodoo 1 support is all here, it will automatically mirror to the full extent. - if (!voodoo.sup_mirroring) + if (g_settings->hacks(CSettings::hack_Zelda)) { if (rdp.tiles(td).mirror_s && !rdp.tiles(td).clamp_s && (!g_settings->hacks(CSettings::hack_PPL) || size_x <= 128)) size_x <<= 1; @@ -1604,7 +1603,7 @@ void LoadTex(int id, gfxChipID_t tmu) cache->c_scl_y /= splits; } } - if (voodoo.sup_mirroring) + if (!g_settings->hacks(CSettings::hack_Zelda)) { if (rdp.tiles(td).mirror_s && texinfo[id].tile_width == 2 * texinfo[id].width) cache->f_mirror_s = TRUE; diff --git a/Source/Project64-video/rdp.h b/Source/Project64-video/rdp.h index 10d77021a..56d8768ce 100644 --- a/Source/Project64-video/rdp.h +++ b/Source/Project64-video/rdp.h @@ -120,7 +120,6 @@ typedef struct { typedef struct { - int sup_mirroring; int sup_32bit_tex; int has_2mb_tex_boundary; int gamma_correction;