Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GS: Handle higher TH/TW for STQ calculation #7104

Merged
merged 2 commits into from Oct 9, 2022
Merged

Conversation

refractionpcsx2
Copy link
Member

@refractionpcsx2 refractionpcsx2 commented Sep 29, 2022

Description of Changes

Modify the clamps/FixedTEX0 calculations to allow TEX0 to set values higher than 10 (max texture size on the GS)

Rationale behind Changes

When using STQ, the calculations are done with the TH and TW sizes in mind that were written to the TEX0 register, clamping them to 10 causes the calculation result to be incorrect.

Suggested Testing Steps

test games (Especially those where textures looked accidentally blown up), make sure nothing is busted. Affects both SW and HW.

TODO: Need to do a hardware test to confirm the clamp behaviour, I suspect it will clamp/wrap at 1024, but we will need to do a hardware test to confirm this.

Fixes the text size in Simple 2000 Series Vol. 105 - The Maid Fuku to Kikanjuu, there is a further issue where the 4bit pixels are in the wrong order, however the PS2 also shows this error, so it could be another GS problem with an upload that only happens once, or it's a core problem.

Before:
image
image

After:
image
image

@refractionpcsx2
Copy link
Member Author

Update: Turns out the font is just shit, ran the game normally on my PS2 and the result is this

image

@refractionpcsx2 refractionpcsx2 force-pushed the gs_tex0size branch 3 times, most recently from 47b4174 to 2ff76b6 Compare October 8, 2022 20:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants