Project

General

Profile

Actions

Emulator Issues #13734

open

[Graphical emulation issue] Z-textures are incorrectly affected by swaptable

Added by Evoca 18 days ago. Updated 11 days ago.

Status:
Fix pending
Priority:
Normal
Assignee:
-
% Done:

0%

Operating system:
N/A
Issue type:
Bug
Milestone:
Regression:
No
Relates to usability:
No
Relates to performance:
No
Easy:
No
Relates to maintainability:
No
Regression start:
Fixed in:

Description

Game Name/ID?

Any game

What's the problem? Describe what went wrong.

Current implementation does something like the following:

tevTex = getSample(uv, tmap).agrb;
zVal = dot(tevTex, zTex) + zbias;

Where the pixel value is swizzled depending on the swaptable. When the last stage texture is used for z-texture the swizzled value is used.
From testing I determined that Z-textures are unaffected by the swaptable, so something like the following should be done instead:

rawTevTex = getSample(uv, tmap);
tevTex = rawTevTex.agrb;
zVal = dot(rawTevTex, zTex) + zbias;

Is the issue present in the latest development version?

Yes, Issue occurring as of rev 2412-225

Is the issue present in the latest release?

Yes, as of rev 2409.0


Files

zbuff_test.png (5.49 KB) zbuff_test.png Hardware capture Evoca, 02/03/2025 08:57 PM
zbuff_test.dff (1.02 MB) zbuff_test.dff Fifo recording Evoca, 02/03/2025 08:57 PM
zbuff_test_hardware_fifoplayer.png (2.59 KB) zbuff_test_hardware_fifoplayer.png flacs, 02/11/2025 04:38 PM
Actions #1

Updated by flacs 11 days ago

Actions #2

Updated by flacs 11 days ago

  • Status changed from Accepted to Fix pending
Actions

Also available in: Atom PDF