devinacker / bsnes-plus

debug-oriented fork of bsnes
http://bsnes.revenant1.net
327 stars 94 forks source link

Memory Editor thinks VRAM is byte-addressed #332

Open jeffythedragonslayer opened 2 years ago

jeffythedragonslayer commented 2 years ago

When the Memory Editor is viewing S-PPU VRAM, there are 16 bytes per row. The second row is labeled "0010" (which is hex for 16) which means that this Memory Editor window is displaying the VRAM as byte-addressed. But the SNES has word-addressed VRAM. The "Address:" label in the bottom panel has the same problem.

image

jeffythedragonslayer commented 2 years ago

The Address field and Selected Tile Address label in the Tile Viewer also have this problem.

devinacker commented 2 years ago

This has always been intentional - partly just to make VRAM addressing consistent with everything else, and also since VRAM is still read/written as bytes instead of words behind the scenes.

I think it wouldn't be a bad idea to have an option to use word addressing for VRAM instead, but I'd probably make it non-default just to avoid breaking the existing convention.

jeffythedragonslayer commented 2 years ago

Does that default of byte-addressing make anyone's workflow easier? I think keeping it byte-addressed makes it harder for people developing games because the addresses they're seeing aren't what they need to set VMADDL and VMADDH to in order to read/write VRAM.

Ramsis-SNES commented 2 years ago

I agree with @jeffythedragonslayer. At least an option to have VRAM word addressing in bsnes-plus would make things sooooo much less confusing, and more consistent, with a reasonably normal programming/debugging workflow. :-)