Project

General

Profile

Actions

Emulator Issues #13733

open

[Graphical emulation issue] CI texture TLUT address calculation is wrong

Added by Evoca about 2 months ago. Updated about 2 months ago.

Status:
Accepted
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 (obviously not accurate):

tmem_addr = ( tmem_offset + tex_ci ) & tmem_bank_size_mask;
pixel_color = TMEMGetTlutValue(tmem_addr);

where tmem_offset is the offset of the TLUT begining in high bank TMEM and tex_ci is the current pixel index value of the texture.

As per my testing, the address of a TLUT value should be calculated by using an OR operation:

tmem_addr = ( tmem_offset | tex_ci ) & tmem_bank_size_mask;

Meaning that in real hardware there is no wrapping around high bank TMEM.

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

tlut_test.png (207 KB) tlut_test.png How it shows in hardware Evoca, 02/03/2025 08:47 PM
tlut_test.dff (1.61 MB) tlut_test.dff Fifo recording Evoca, 02/03/2025 08:47 PM
tlut_test_hardware_fifoplayer.png (54 KB) tlut_test_hardware_fifoplayer.png flacs, 02/11/2025 04:21 PM
Actions

Also available in: Atom PDF