PCSX2 / pcsx2

PCSX2 - The Playstation 2 Emulator
https://pcsx2.net
GNU General Public License v3.0
11.56k stars 1.6k forks source link

[BUG]: Castlevania - Curse of Darkness map screen glitched out #6156

Closed rhobiusvoid closed 4 months ago

rhobiusvoid commented 2 years ago

Describe the Bug

image Exactly what it says on the tin. Above this line is a picture of the map screen in Software Mode. image And this is what it looks like in Hardware Mode.

Seems to be a regression, considering the fact this wasn't a problem until now.

Reproduction Steps

Get into the game and just open the map by pressing Select.

Expected Behavior

The map is to be sharp and readable, considering doors are just simple holes in the white outline surrounding the blue interiors. image Here is what it normally looks like.

PCSX2 Revision

1.7.2775

Operating System

Windows 10 (64bit)

If Linux - Specify Distro

No response

CPU

i5-9400F

GPU

GTX 1050ti

GS Settings

image image

Emulation Settings

Tested on all presets, doesn't seem to change anything.

GS Window Screenshots

No response

Logs & Dumps

No response

Mrlinkwii commented 2 years ago

Can you post a gs dump? :)

rhobiusvoid commented 2 years ago

How do I go about doing that?

EDIT: Nevermind, I found it. Here you go. https://drive.google.com/file/d/11nGip_FXJH60oC81S923bSwQq3Drc34v/view?usp=sharing gs_20220523202401_Castlevania - Curse of Darkness_SLUS-21168

coornio commented 2 years ago

I tested the dump myself. Something is definitely wrong.

Rendering is broken as seen in screenshots when in Software rendering. Hardware works fine so long as Texture Preloading isn't set to None. Seems like a regression.

MuPendulum commented 2 years ago

Regressed with #3940 @tellowkrinkle

ichee commented 2 years ago

Issue seems to be caused by the texture filter Bilinear PS2. Setting any other value, excluding the trilinear option which is worse for this issue, seems to resolve it.

If using the software renderer with QT builds, changing to one of the hardware renderers and setting the filter option to anything other than Bilinear PS2 then switching back will work around the issue with software as well.

coornio commented 2 years ago

So it's fixed both by changing the default Texture Filtering and also by having any form of Texture Preloading. I wonder what these two have in common that rectify this.

ichee commented 2 years ago

This same issue (or at least similar) was also reported in the forums years ago, and subsequently resolved.

Forum link at https://forums.pcsx2.net/Thread-Horizontal-Lines-in-Castlevania-Curse-of-Darkness.

ichee commented 2 years ago

Latest build looks significantly better on all hardware renderers than they did previously, though edges of map are a bit jagged. Also, the displayed 'S' on some area maps gets cut off when moving the map vertically.

Software renderer is still broken without using the above workaround.

MuPendulum commented 1 year ago

Regression is still present in latest master (aa4a9cda) so this was not one of the games fixed by #6757.

Software: Broken Hardware w/ Texture Preloading set to None: Broken Hardware w/ Texture Preloading set to Partial: Improved but may still be partially broken according to ichee Hardware w/ Texture Preloading set to Full (Hash Cache): Same as Partial

refractionpcsx2 commented 1 year ago

It's fixable with #6553 image

MuPendulum commented 1 year ago

bd8fcc8f is the culprit although I can confirm the pre-round sprite hack in #6553 works around it in the software renderer.

refractionpcsx2 commented 1 year ago

that's not exactly introducing a bug per-sé, we need that part to be accurate, but the PS2 is not so accurate in its start/end positions of the texture, something the preround PR works to alleviate (but it needs a whole lot more work)