JayFoxRox / xqemu

Personal development repository for XQEMU (original Xbox Emulator)
14 stars 1 forks source link

Improve conditions for surface upload #17

Closed JayFoxRox closed 5 years ago

JayFoxRox commented 6 years ago
JayFoxRox: wat. our surface logic appears really flawed. I have a case in TH: American Wasteland where the game has data at address A [640x480], then it switches to buffer B [320x240], then buffer C [640x480], and then back to buffer A [640x480]
JayFoxRox: while the surface is downloaded when going from A -> B, it's not uploaded again before going from C -> A. so the buffer for A remains what was in C
JayFoxRox: our code only appears to check if the CPU has written a surface OR if the surface shape has changed before re-uploading. it doesn't even care if the address changed lol.

This could be bad for perf and not sure how correct that solution is. I haven't dealt with that code in ages. It's mostly a test to confirm that this is indeed the problem I suspected.

TODO:

JayFoxRox commented 5 years ago

Moved upstream.