joeldipops / TransferBoy

Gameboy Emulator for N64 using Transfer Pak. Actual emulator logic largely written by https://github.com/koenk/gbc. Runs on https://github.com/DragonMinded/libdragon
Other
44 stars 0 forks source link

Flicker in bottom few tile rows of screen. #41

Open joeldipops opened 4 years ago

joeldipops commented 4 years ago

Whenever a sprite moves within the bottom few tiles, those rows flicker and get very ugly.

I suspect this is because the RSP hadn't quite finished rendering the last rows before being asked to render the new ones.

I think the fix here is to have some way for the RSP to signal that it is done and not interrupt it with a new render request. Just skip that frame.

There is also scope for optimising the RSP code - take advantage of delay slots where possible and avoid repeating a few calculations.

joeldipops commented 4 years ago

Oh it's weirder than that. I hacked it so that only those rows would render and got the same behaviour. That can't be timing...

joeldipops commented 4 years ago

Yep, the RSP is finishing well before the next frame comes along. What is this...

joeldipops commented 4 years ago

Might be due to the fact I'm only working with one framebuffer atm. Let's try with two.