mirror of
https://github.com/PCSX2/pcsx2.git
synced 2026-01-31 01:15:24 +01:00
Compare commits
18 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
480a3fe171 | ||
|
|
b160eac49f | ||
|
|
37ba82b8b7 | ||
|
|
2d604145f1 | ||
|
|
d60a6df313 | ||
|
|
236d9e3028 | ||
|
|
175327e711 | ||
|
|
6342f99504 | ||
|
|
6164ae9f60 | ||
|
|
d2a5b70b2e | ||
|
|
b2be5dcb59 | ||
|
|
b67c03cc75 | ||
|
|
d613701780 | ||
|
|
4b62562fce | ||
|
|
6ffaca45da | ||
|
|
56fe0b32e6 | ||
|
|
f7c0d6af73 | ||
|
|
b625e2c47a |
@@ -231,7 +231,7 @@ echo "Building PlutoVG..."
|
||||
rm -fr "plutovg-$PLUTOVG"
|
||||
tar xf "plutovg-$PLUTOVG.tar.gz"
|
||||
cd "plutovg-$PLUTOVG"
|
||||
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DPLUTOVG_BUILD_EXAMPLES=OFF -B build -G Ninja
|
||||
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH="$INSTALLDIR" -DCMAKE_INSTALL_PREFIX="$INSTALLDIR" -DBUILD_SHARED_LIBS=ON -DPLUTOVG_BUILD_EXAMPLES=OFF -B build -G Ninja
|
||||
cmake --build build --parallel
|
||||
ninja -C build install
|
||||
cd ..
|
||||
|
||||
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
@@ -118,7 +118,7 @@ CPCS-01005:
|
||||
name-en: "Gun Survivor 4 - BioHazard - Heroes Never Die [with GunCon2]"
|
||||
region: "NTSC-J"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -2081,7 +2081,7 @@ SCAJ-20139:
|
||||
name: "Zero - Shisei no Koe" # Fatal Frame - Rei - Irezumi no Sei
|
||||
region: "NTSC-Unk"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 1 # Reduces blurriness.
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SCAJ-20140:
|
||||
name: "Bleach - Erabareshi Tamashi"
|
||||
region: "NTSC-Unk"
|
||||
@@ -17320,7 +17320,7 @@ SLES-51448:
|
||||
region: "PAL-M5"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -20903,11 +20903,10 @@ SLES-52877:
|
||||
region: "PAL-M5"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 2 # Reduces blurriness. Normal Vertex works better, but causes some lights to disappear.
|
||||
roundSprite: 1 # Further reduces blurriness.
|
||||
halfPixelOffset: 5 # Reduces blurriness.
|
||||
bilinearUpscale: 1 # Smooths out fire textures.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
beforeDraw: "OI_HauntingGround" # Fix bloom.
|
||||
textureInsideRT: 1 # Fixes post effects.
|
||||
SLES-52882:
|
||||
name: "Stolen"
|
||||
region: "PAL-M5"
|
||||
@@ -23948,7 +23947,7 @@ SLES-53825:
|
||||
region: "PAL-M5"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 1 # Reduces blurriness.
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SLES-53826:
|
||||
name: "Tom Clancy's Splinter Cell - Double Agent"
|
||||
region: "PAL-M5"
|
||||
@@ -30092,7 +30091,7 @@ SLKA-25038:
|
||||
name: "Gun Survivor 4 - BioHazard - Heroes Never Die"
|
||||
region: "NTSC-K"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -34587,7 +34586,7 @@ SLPM-61039:
|
||||
name-en: "BioHazard Gun Survivor 4 - Heroes Never Die [Store Demo]"
|
||||
region: "NTSC-J"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -40729,7 +40728,7 @@ SLPM-65245:
|
||||
region: "NTSC-J"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -44525,11 +44524,10 @@ SLPM-65913:
|
||||
region: "NTSC-J"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 2 # Reduces blurriness. Normal Vertex works better, but causes some lights to disappear.
|
||||
roundSprite: 1 # Further reduces blurriness.
|
||||
halfPixelOffset: 5 # Reduces blurriness.
|
||||
bilinearUpscale: 1 # Smooths out fire textures.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
beforeDraw: "OI_HauntingGround" # Fix bloom.
|
||||
textureInsideRT: 1 # Fixes post effects.
|
||||
SLPM-65914:
|
||||
name: "NANA"
|
||||
name-sort: "ナナ"
|
||||
@@ -49059,11 +49057,10 @@ SLPM-66638:
|
||||
name-en: "Demento [CapColle]"
|
||||
region: "NTSC-J"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 2 # Reduces blurriness. Normal Vertex works better, but causes some lights to disappear.
|
||||
roundSprite: 1 # Further reduces blurriness.
|
||||
halfPixelOffset: 5 # Reduces blurriness.
|
||||
bilinearUpscale: 1 # Smooths out fire textures.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
beforeDraw: "OI_HauntingGround" # Fix bloom.
|
||||
textureInsideRT: 1 # Fixes post effects.
|
||||
SLPM-66639:
|
||||
name: "ストリートファイターⅢ 3rd STRIKE Fight for the future [カプコレ]"
|
||||
name-sort: "すとりーとふぁいたー3 3rd STRIKE Fight for the future [かぷこれ]"
|
||||
@@ -58219,6 +58216,8 @@ SLPS-25544:
|
||||
name-en: "Fatal Frame III - The Tormented"
|
||||
region: "NTSC-J"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SLPS-25545:
|
||||
name: "ファイティング フォー ワンピース"
|
||||
name-sort: "ふぁいてぃんぐ ふぉー わんぴーす"
|
||||
@@ -61443,6 +61442,8 @@ SLPS-73245:
|
||||
name-sort: "ぜろ しせいのこえ [PlayStation2 the Best]"
|
||||
name-en: "Fatal Frame III - The Tormented [PlayStation2 the Best]"
|
||||
region: "NTSC-J"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SLPS-73246:
|
||||
name: "ガンダム トゥルーオデッセイ ~失われしGの伝説~ [PlayStation2 the Best]"
|
||||
name-sort: "がんだむ とぅるーおでっせい うしなわれしGのでんせつ [PlayStation2 the Best]"
|
||||
@@ -61554,7 +61555,7 @@ SLPS-73257:
|
||||
name-en: "Fatal Frame III - The Tormented [PlayStation 2 the Best - Reprint]"
|
||||
region: "NTSC-J"
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 1 # Reduces blurriness.
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SLPS-73258:
|
||||
name: "喧嘩番長2 ~フルスロットル~ [PlayStation2 the Best]"
|
||||
name-sort: "けんかばんちょう2 ふるすろっとる [PlayStation2 the Best]"
|
||||
@@ -64957,7 +64958,7 @@ SLUS-20669:
|
||||
gsHWFixes:
|
||||
PCRTCOverscan: 1 # Shows full image frame.
|
||||
PCRTCOffsets: 1 # Shows full image frame.
|
||||
halfPixelOffset: 4 # Fixes character offset with flashlight and blurriness.
|
||||
halfPixelOffset: 5 # Fixes character offset with flashlight and blurriness. Fixes water lines.
|
||||
roundSprite: 2 # Fixes font artifacts.
|
||||
autoFlush: 1 # Fixes light bloom intensity.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
@@ -67323,11 +67324,10 @@ SLUS-21075:
|
||||
region: "NTSC-U"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 2 # Reduces blurriness. Normal Vertex works better, but causes some lights to disappear.
|
||||
roundSprite: 1 # Further reduces blurriness.
|
||||
halfPixelOffset: 5 # Reduces blurriness.
|
||||
bilinearUpscale: 1 # Smooths out fire textures.
|
||||
nativeScaling: 2 # Fixes post processing.
|
||||
beforeDraw: "OI_HauntingGround" # Fix bloom.
|
||||
textureInsideRT: 1 # Fixes post effects.
|
||||
SLUS-21076:
|
||||
name: "Atari Anthology"
|
||||
region: "NTSC-U"
|
||||
@@ -68360,7 +68360,7 @@ SLUS-21244:
|
||||
region: "NTSC-U"
|
||||
compat: 5
|
||||
gsHWFixes:
|
||||
halfPixelOffset: 1 # Reduces blurriness.
|
||||
halfPixelOffset: 4 # Reduces blurriness.
|
||||
SLUS-21245:
|
||||
name: "Suikoden Tactics"
|
||||
region: "NTSC-U"
|
||||
|
||||
@@ -19,7 +19,7 @@ find_package(LZ4 REQUIRED)
|
||||
find_package(WebP REQUIRED) # v1.3.2, spews an error on Linux because no pkg-config.
|
||||
find_package(SDL3 3.2.6 REQUIRED)
|
||||
find_package(Freetype 2.11.1 REQUIRED)
|
||||
find_package(plutovg 0.0.13 REQUIRED)
|
||||
find_package(plutovg REQUIRED) # v0.0.13 is needed for building plutosvg, but we can support v1.0.0
|
||||
find_package(plutosvg 0.0.6 REQUIRED)
|
||||
|
||||
if(USE_VULKAN)
|
||||
|
||||
@@ -117,21 +117,26 @@ void AchievementSettingsWidget::updateEnableState()
|
||||
m_ui.achievementNotificationsDurationLabel->setEnabled(notifications);
|
||||
m_ui.leaderboardNotificationsDuration->setEnabled(lb_notifications);
|
||||
m_ui.leaderboardNotificationsDurationLabel->setEnabled(lb_notifications);
|
||||
m_ui.notificationSoundPath->setEnabled(info);
|
||||
m_ui.notificationSoundBrowse->setEnabled(info);
|
||||
m_ui.notificationSoundOpen->setEnabled(info);
|
||||
m_ui.notificationSoundReset->setEnabled(info);
|
||||
m_ui.notificationSound->setEnabled(enabled);
|
||||
m_ui.unlockSoundPath->setEnabled(unlock);
|
||||
m_ui.unlockSoundBrowse->setEnabled(unlock);
|
||||
m_ui.unlockSoundOpen->setEnabled(unlock);
|
||||
m_ui.unlockSoundReset->setEnabled(unlock);
|
||||
m_ui.unlockSound->setEnabled(enabled);
|
||||
m_ui.lbSoundPath->setEnabled(lbsound);
|
||||
m_ui.lbSoundOpen->setEnabled(lbsound);
|
||||
m_ui.lbSoundBrowse->setEnabled(lbsound);
|
||||
m_ui.lbSoundReset->setEnabled(lbsound);
|
||||
m_ui.lbSound->setEnabled(enabled);
|
||||
|
||||
if (!m_dialog->isPerGameSettings())
|
||||
{
|
||||
m_ui.notificationSoundPath->setEnabled(info);
|
||||
m_ui.notificationSoundBrowse->setEnabled(info);
|
||||
m_ui.notificationSoundOpen->setEnabled(info);
|
||||
m_ui.notificationSoundReset->setEnabled(info);
|
||||
m_ui.notificationSound->setEnabled(enabled);
|
||||
m_ui.unlockSoundPath->setEnabled(unlock);
|
||||
m_ui.unlockSoundBrowse->setEnabled(unlock);
|
||||
m_ui.unlockSoundOpen->setEnabled(unlock);
|
||||
m_ui.unlockSoundReset->setEnabled(unlock);
|
||||
m_ui.unlockSound->setEnabled(enabled);
|
||||
m_ui.lbSoundPath->setEnabled(lbsound);
|
||||
m_ui.lbSoundOpen->setEnabled(lbsound);
|
||||
m_ui.lbSoundBrowse->setEnabled(lbsound);
|
||||
m_ui.lbSoundReset->setEnabled(lbsound);
|
||||
m_ui.lbSound->setEnabled(enabled);
|
||||
}
|
||||
|
||||
m_ui.soundEffects->setEnabled(enabled);
|
||||
m_ui.overlays->setEnabled(enabled);
|
||||
m_ui.encoreMode->setEnabled(enabled);
|
||||
|
||||
@@ -1240,13 +1240,8 @@ void GraphicsSettingsWidget::populateUpscaleMultipliers(u32 max_upscale_multipli
|
||||
{
|
||||
static constexpr std::pair<const char*, float> templates[] = {
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "Native (PS2) (Default)"), 1.0f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "1.25x Native (~450px)"), 1.25f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "1.5x Native (~540px)"), 1.5f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "1.75x Native (~630px)"), 1.75f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "2x Native (~720px/HD)"), 2.0f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "2.5x Native (~900px/HD+)"), 2.5f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "3x Native (~1080px/FHD)"), 3.0f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "3.5x Native (~1260px)"), 3.5f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "4x Native (~1440px/QHD)"), 4.0f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "5x Native (~1800px/QHD+)"), 5.0f},
|
||||
{QT_TRANSLATE_NOOP("GraphicsSettingsWidget", "6x Native (~2160px/4K UHD)"), 6.0f},
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -1,19 +1,12 @@
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
[This file contains the template for the PCSX2 code rights license. For the full
|
||||
rant-like preamble of the GPL, see GPL.txt]
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
|
||||
/* PCSX2 - PS2 Emulator for PCs
|
||||
* Copyright (C) 2002-2019 PCSX2 Dev Team
|
||||
*
|
||||
* PCSX2 is free software: you can redistribute it and/or modify it under the terms
|
||||
* of the GNU Lesser General Public License as published by the Free Software Found-
|
||||
* ation, either version 3 of the License, or (at your option) any later version.
|
||||
*
|
||||
* PCSX2 is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
|
||||
* without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
|
||||
* PURPOSE. See the GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License along with PCSX2.
|
||||
* If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
@@ -1200,75 +1200,6 @@ bool GSHwHack::OI_BurnoutGames(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GS
|
||||
return false;
|
||||
}
|
||||
|
||||
bool GSHwHack::OI_HauntingGround(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t)
|
||||
{
|
||||
// Haunting Ground clears two targets by doing a direct colour write at 0x3000, covering a target at 0x3380.
|
||||
// To make matters worse, it's masked. This currently isn't handled in our HLE clears, so we need to manually
|
||||
// remove the other target.
|
||||
if (rt && !ds && !t && r.IsConstantDirectWriteMemClear())
|
||||
{
|
||||
GL_CACHE("GSHwHack::OI_HauntingGround()");
|
||||
|
||||
const u32 bp = RFBP;
|
||||
const u32 bw = RFBW;
|
||||
const u32 psm = RFPSM;
|
||||
const u32 fbmsk = RFBMSK;
|
||||
const GSVector4i rc = r.m_r;
|
||||
|
||||
for (int type = 0; type < 2; type++)
|
||||
{
|
||||
auto& list = g_texture_cache->m_dst[type];
|
||||
|
||||
for (auto i = list.begin(); i != list.end();)
|
||||
{
|
||||
GSTextureCache::Target* t = *i;
|
||||
auto ei = i++;
|
||||
|
||||
// There's two cases we hit here - when we clear 3380 via 3000, and when we overlap 3000 by writing to 3380.
|
||||
// The latter is actually only 256x224, which ends at 337F, but because the game's a pain in the ass, it
|
||||
// shuffles 512x512, causing the target to expand. It'd actually be shuffling junk and wasting draw cycles,
|
||||
// but when did that stop anyone? So, we can get away with just saying "if it's before, ignore".
|
||||
if (t->m_TEX0.TBP0 <= bp)
|
||||
{
|
||||
// don't remove ourself..
|
||||
continue;
|
||||
}
|
||||
|
||||
// Has to intersect.
|
||||
if (!t->Overlaps(bp, bw, psm, rc))
|
||||
continue;
|
||||
|
||||
// Another annoying case. Sometimes it clears with RGB masked, only writing to A. We don't want to kill the
|
||||
// target in this case, so we'll dirty A instead.
|
||||
if (fbmsk != 0)
|
||||
{
|
||||
GL_CACHE("OI_HauntingGround(%x, %u, %s, %d,%d => %d,%d): Dirty target at %x %u %s %08X", bp, bw,
|
||||
psm_str(psm), rc.x, rc.y, rc.z, rc.w, t->m_TEX0.TBP0, t->m_TEX0.TBW, psm_str(t->m_TEX0.PSM),
|
||||
fbmsk);
|
||||
|
||||
g_texture_cache->AddDirtyRectTarget(t, rc, psm, bw, RGBAMask{GSUtil::GetChannelMask(psm, fbmsk)});
|
||||
}
|
||||
else
|
||||
{
|
||||
GL_CACHE("OI_HauntingGround(%x, %u, %s, %d,%d => %d,%d): Removing target at %x %u %s", bp, bw,
|
||||
psm_str(psm), rc.x, rc.y, rc.z, rc.w, t->m_TEX0.TBP0, t->m_TEX0.TBW, psm_str(t->m_TEX0.PSM));
|
||||
|
||||
// Need to also remove any sources which reference this target.
|
||||
g_texture_cache->InvalidateSourcesFromTarget(t);
|
||||
|
||||
list.erase(ei);
|
||||
delete t;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
g_texture_cache->InvalidateVideoMemType(GSTextureCache::DepthStencil, bp);
|
||||
}
|
||||
|
||||
// Not skipping anything. This is just an invalidation hack.
|
||||
return true;
|
||||
}
|
||||
|
||||
#undef RPRIM
|
||||
#undef RCONTEXT
|
||||
|
||||
@@ -1519,7 +1450,6 @@ const GSHwHack::Entry<GSRendererHW::OI_Ptr> GSHwHack::s_before_draw_functions[]
|
||||
CRC_F(OI_SonicUnleashed),
|
||||
CRC_F(OI_ArTonelico2),
|
||||
CRC_F(OI_BurnoutGames),
|
||||
CRC_F(OI_HauntingGround),
|
||||
};
|
||||
|
||||
const GSHwHack::Entry<GSRendererHW::MV_Ptr> GSHwHack::s_move_handler_functions[] = {
|
||||
|
||||
@@ -37,7 +37,6 @@ public:
|
||||
static bool OI_SonicUnleashed(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t);
|
||||
static bool OI_ArTonelico2(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t);
|
||||
static bool OI_BurnoutGames(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t);
|
||||
static bool OI_HauntingGround(GSRendererHW& r, GSTexture* rt, GSTexture* ds, GSTextureCache::Source* t);
|
||||
|
||||
static bool MV_Growlanser(GSRendererHW& r);
|
||||
static bool MV_Ico(GSRendererHW& r);
|
||||
|
||||
@@ -3358,6 +3358,15 @@ void GSRendererHW::Draw()
|
||||
|
||||
if (ds->m_TEX0.TBP0 != z_address_info.ZBP || z_address_info.offset != static_cast<u32>(vertical_offset - z_vertical_offset))
|
||||
g_texture_cache->InvalidateTemporaryZ();
|
||||
else if (!m_r.rintersect(z_address_info.rect_since + GSVector4i(0, z_address_info.offset, 0, z_address_info.offset)).rempty() && m_cached_ctx.TEST.ZTST > ZTST_ALWAYS)
|
||||
{
|
||||
GL_CACHE("RT in RT Updating Z copy on draw %d z_offset %d", s_n, z_address_info.offset);
|
||||
GSVector4i dRect = GSVector4i(z_address_info.rect_since.x * ds->m_scale, (z_address_info.offset + z_address_info.rect_since.y) * ds->m_scale, (z_address_info.rect_since.z + (1.0f / ds->m_scale)) * ds->m_scale, (z_address_info.offset + z_address_info.rect_since.w + (1.0f / ds->m_scale)) * ds->m_scale);
|
||||
g_gs_device->StretchRect(ds->m_texture, GSVector4(z_address_info.rect_since.x / static_cast<float>(ds->m_unscaled_size.x), z_address_info.rect_since.y / static_cast<float>(ds->m_unscaled_size.y), (z_address_info.rect_since.z + (1.0f / ds->m_scale)) / static_cast<float>(ds->m_unscaled_size.x), (z_address_info.rect_since.w + (1.0f / ds->m_scale)) / static_cast<float>(ds->m_unscaled_size.y)), g_texture_cache->GetTemporaryZ(), GSVector4(dRect), ShaderConvert::DEPTH_COPY, false);
|
||||
g_perfmon.Put(GSPerfMon::TextureCopies, 1);
|
||||
z_address_info.rect_since = GSVector4i::zero();
|
||||
g_texture_cache->SetTemporaryZInfo(z_address_info);
|
||||
}
|
||||
}
|
||||
|
||||
if (g_texture_cache->GetTemporaryZ() == nullptr)
|
||||
@@ -4267,10 +4276,11 @@ void GSRendererHW::Draw()
|
||||
GSTextureCache::TempZAddress z_address_info = g_texture_cache->GetTemporaryZInfo();
|
||||
if (ds->m_TEX0.TBP0 == z_address_info.ZBP)
|
||||
{
|
||||
GL_CACHE("RT in RT Updating Z copy on draw %d z_offset %d", s_n, z_address_info.offset);
|
||||
GSVector4i dRect = GSVector4i(real_rect.x * ds->m_scale, (z_address_info.offset + real_rect.y) * ds->m_scale, (real_rect.z + (1.0f / ds->m_scale)) * ds->m_scale, (z_address_info.offset + real_rect.w + (1.0f / ds->m_scale)) * ds->m_scale);
|
||||
g_gs_device->StretchRect(ds->m_texture, GSVector4(real_rect.x / static_cast<float>(ds->m_unscaled_size.x), real_rect.y / static_cast<float>(ds->m_unscaled_size.y), (real_rect.z + (1.0f / ds->m_scale)) / static_cast<float>(ds->m_unscaled_size.x), (real_rect.w + (1.0f / ds->m_scale)) / static_cast<float>(ds->m_unscaled_size.y)), g_texture_cache->GetTemporaryZ(), GSVector4(dRect), ShaderConvert::DEPTH_COPY, false);
|
||||
g_perfmon.Put(GSPerfMon::TextureCopies, 1);
|
||||
if (z_address_info.rect_since.rempty())
|
||||
z_address_info.rect_since = real_rect;
|
||||
else
|
||||
z_address_info.rect_since = z_address_info.rect_since.runion(real_rect);
|
||||
g_texture_cache->SetTemporaryZInfo(z_address_info);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -6401,8 +6411,8 @@ __ri void GSRendererHW::HandleTextureHazards(const GSTextureCache::Target* rt, c
|
||||
}
|
||||
}
|
||||
|
||||
copy_range.z = std::min(copy_range.z, copy_size.x);
|
||||
copy_range.w = std::min(copy_range.w, copy_size.y);
|
||||
copy_range.z = std::min(copy_range.z, src_target->m_unscaled_size.x);
|
||||
copy_range.w = std::min(copy_range.w, src_target->m_unscaled_size.y);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
||||
@@ -2259,6 +2259,15 @@ GSTextureCache::Target* GSTextureCache::LookupTarget(GIFRegTEX0 TEX0, const GSVe
|
||||
{
|
||||
const GSLocalMemory::psm_t& s_psm = GSLocalMemory::m_psm[TEX0.PSM];
|
||||
|
||||
// If it overlaps but the target is huge and the Z isn't offset, we need to split the buffer, so let's shrink this one down.
|
||||
// 896 is just 448 * 2,just gives the buffer chance to be larger than normal, in case they do something like 640x640, or something ridiculous.
|
||||
if (!is_shuffle && (ds && offset == 0 && (t->m_valid.w >= 896) && ((((t->m_end_block + 1) - t->m_TEX0.TBP0) >> 1) + t->m_TEX0.TBP0) <= bp))
|
||||
{
|
||||
t->m_valid.w /= 2;
|
||||
t->m_end_block = ((((t->m_end_block + 1) - t->m_TEX0.TBP0) >> 1) + t->m_TEX0.TBP0) - 1;
|
||||
continue;
|
||||
}
|
||||
|
||||
// I know what you're thinking, and I hate the guy who wrote it too (me). Project Snowblind, Tomb Raider etc decide to offset where they're drawing using a channel shuffle, and this gets messy, so best just to kill the old target.
|
||||
if (is_shuffle && src && src->m_TEX0.PSM == PSMT8 && GSRendererHW::GetInstance()->m_context->FRAME.FBW == 1 && t->m_last_draw != (GSState::s_n - 1) && src->m_from_target && (src->m_from_target->m_TEX0.TBP0 == src->m_TEX0.TBP0 || (((src->m_TEX0.TBP0 - src->m_from_target->m_TEX0.TBP0) >> 5) % std::max(src->m_from_target->m_TEX0.TBW, 1U) == 0)) && widthpage_offset && src->m_from_target != t)
|
||||
{
|
||||
@@ -7759,6 +7768,11 @@ void GSTextureCache::SetTemporaryZInfo(u32 address, u32 offset)
|
||||
{
|
||||
m_temporary_z_info.ZBP = address;
|
||||
m_temporary_z_info.offset = offset;
|
||||
m_temporary_z_info.rect_since = GSVector4i::zero();
|
||||
}
|
||||
void GSTextureCache::SetTemporaryZInfo(TempZAddress address_info)
|
||||
{
|
||||
m_temporary_z_info = address_info;
|
||||
}
|
||||
|
||||
void GSTextureCache::SetTemporaryZ(GSTexture* temp_z)
|
||||
|
||||
@@ -210,6 +210,7 @@ public:
|
||||
{
|
||||
u32 ZBP;
|
||||
u32 offset;
|
||||
GSVector4i rect_since;
|
||||
};
|
||||
|
||||
class Target : public Surface
|
||||
@@ -564,6 +565,7 @@ public:
|
||||
GSTexture* GetTemporaryZ();
|
||||
TempZAddress GetTemporaryZInfo();
|
||||
void SetTemporaryZInfo(u32 address, u32 offset);
|
||||
void SetTemporaryZInfo(TempZAddress address_info);
|
||||
/// Invalidates a temporary Z, a partial copy only created from the current DS for the current draw when Z is not offset but RT is.
|
||||
void InvalidateTemporaryZ();
|
||||
|
||||
|
||||
@@ -242,7 +242,6 @@ namespace FullscreenUI
|
||||
static void ApplyLayoutSettings(const SettingsInterface* bsi = nullptr);
|
||||
|
||||
void DrawSvgTexture(GSTexture* padded_texture, ImVec2 unpadded_size);
|
||||
void DrawSvgTexture_UV(GSTexture* padded_texture, ImVec2 unpadded_size, ImVec2 unpadded_uv0, ImVec2 unpadded_uv1);
|
||||
void DrawCachedSvgTexture(const std::string& path, ImVec2 size, SvgScaling mode);
|
||||
void DrawCachedSvgTextureAsync(const std::string& path, ImVec2 size, SvgScaling mode);
|
||||
|
||||
@@ -3931,13 +3930,8 @@ void FullscreenUI::DrawGraphicsSettingsPage(SettingsInterface* bsi, bool show_ad
|
||||
};
|
||||
static const char* s_resolution_options[] = {
|
||||
FSUI_NSTR("Native (PS2)"),
|
||||
FSUI_NSTR("1.25x Native (~450px)"),
|
||||
FSUI_NSTR("1.5x Native (~540px)"),
|
||||
FSUI_NSTR("1.75x Native (~630px)"),
|
||||
FSUI_NSTR("2x Native (~720px/HD)"),
|
||||
FSUI_NSTR("2.5x Native (~900px/HD+)"),
|
||||
FSUI_NSTR("3x Native (~1080px/FHD)"),
|
||||
FSUI_NSTR("3.5x Native (~1260px)"),
|
||||
FSUI_NSTR("4x Native (~1440px/QHD)"),
|
||||
FSUI_NSTR("5x Native (~1800px/QHD+)"),
|
||||
FSUI_NSTR("6x Native (~2160px/4K UHD)"),
|
||||
@@ -3950,13 +3944,8 @@ void FullscreenUI::DrawGraphicsSettingsPage(SettingsInterface* bsi, bool show_ad
|
||||
};
|
||||
static const char* s_resolution_values[] = {
|
||||
"1",
|
||||
"1.25",
|
||||
"1.5",
|
||||
"1.75",
|
||||
"2",
|
||||
"2.5",
|
||||
"3",
|
||||
"3.5",
|
||||
"4",
|
||||
"5",
|
||||
"6",
|
||||
@@ -7955,13 +7944,8 @@ TRANSLATE_NOOP("FullscreenUI", "Blend (Bottom Field First, Half FPS)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "Adaptive (Top Field First)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "Adaptive (Bottom Field First)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "Native (PS2)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "1.25x Native (~450px)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "1.5x Native (~540px)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "1.75x Native (~630px)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "2x Native (~720px/HD)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "2.5x Native (~900px/HD+)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "3x Native (~1080px/FHD)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "3.5x Native (~1260px)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "4x Native (~1440px/QHD)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "5x Native (~1800px/QHD+)");
|
||||
TRANSLATE_NOOP("FullscreenUI", "6x Native (~2160px/4K UHD)");
|
||||
|
||||
@@ -671,7 +671,7 @@ ImRect ImGuiFullscreen::CenterImage(const ImVec2& fit_size, const ImVec2& image_
|
||||
|
||||
ImRect ImGuiFullscreen::CenterImage(const ImRect& fit_rect, const ImVec2& image_size, bool fill)
|
||||
{
|
||||
ImRect ret(CenterImage(fit_rect.Max - fit_rect.Min, image_size));
|
||||
ImRect ret(CenterImage(fit_rect.Max - fit_rect.Min, image_size, fill));
|
||||
ret.Translate(fit_rect.Min);
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user