Tuesday, July 11, 2006

Graphical fixes

Here are a few of the significant graphical fixes I've made so far for R6.

Firstly, I managed to fix the horrible flickering that happened when running various roms (Paper Mario was a good example). It turned out that I was making an assumption that roms executed exactly one display list per frame. I assumed that each display list would clear the screen, render everything, and then wait for the screen to flip. As it turns out, some roms execute multiple display lists per frame. In the case of Paper Mario it executes 2 display lists per frame (one which clears the screen, then another which renders everything). By making sure that I only flip after the second display list executes, I avoid the flickering (the actual solution is a little more involved but this is the general idea).

The next significant glitch I've fixed was to do with backface culling of triangles. Basically, when I ported the graphics engine over from the PC version, I forgot to implement the two or three lines of code which handles this. It was a very small fix, but it corrects a number of significant graphical issues (notably all the walls getting in the way in Quest 64).

Finally, I've managed to track down and fix a significant memory leak in the texture handling code. I believe this was causing many of the random crashes that were occuring when leaving the emulator running for several minutes or more (basically through running out of memory). Before applying the fix I found that the Super Mario 64 would crash within 4-5 minutes. After applying the fix I've been able to run Mario with no problems for over 30 minutes.

I'll keep you posted as to when you can expect a new release. I'm quite excited about the memory leak fix, so I'd like to get a new release out as soon as I can implement some of the other things I promised for R6.

-StrmnNrmn

PS I know I've been crap at replying to emails :( I'm hoping to get this release out and then I'll spend a few hours sorting out my mailbox and replying to various comments here.

17 comments:

Morgan said...

StrmnNrmn I don't knwo much about emulation but can you constantly find things in the emulate to improve on? Like do you actually think you can tweak this emulator to full speed one day? Thanks and keep up the great work but please answer my old question are you going to use the Media Engine now most psp's are 1.5. Also the tip pspmonkey gave you when you test it could you tell us the results it makes. Thanks!

Disturbd1 said...

That's GREAT news!! Awesome! So I assume this is going to be more of a graphical update than a speed one, correct? Sounds Great dude, keep up the good work!

Trexx said...

Sounds great man, cant wait. thanks for your contrubutions to the scene.

Morgan said...

The ME version of the emulator, yes I have been asking about this for weeks. Get in line guys. Keep it up StrmnNrmn!

Morgan said...

Awesome but yeah I can't wait for R6 I hope StrmnNrmn can give us a release date soon. Or maybe he'll just release it soon, maybe on the 14th to spoil the other emulator day.

Disturbd1 said...

"tsurumaru said...

morgan, I think Strmnnrmn mentioned sometime ago that he had some ideas for using the ME to handle some functions but I assume mainly it would handle sound emulation like SNES9XTYL does. Since we don't have sound emulation up and running (Strmn may plan to finish the dynarec and optimisation work first) it probably wont be implemented in any of the immediate builds. (Although we'll have to hear from Strmnnrmn himself for the full lowdown).

Kind regards."

Unless of course the ME would have such a negative impact on the speed compared to non-use of the ME

_Psycho said...

Just curious, how much of your dynarec is complete ?

Morgan said...

Yeah I can't wait for R6 and when the dynarec is complete! Well it's the 14th and I don't see anything about that Full Speed N64 Emulator yet!?!? Course it's only a select few of games they are talking about but I would love to see that the UltraHLE or whatever is true.

Morgan said...

I'm kinda getting inpatient, where's R6?

Morgan said...

*impatient

StrmnNrmn please give us a release date as soon as you can please for R6. Keeup the great work and I'm not trying to rush you I just would like a maybe estimated release or something.

Morgan said...

Like I said I'm not rushing him I'm just saying when the guy said he'd have a release soon I expect a release soon. I can wait forever for the next build I want the best emulator possible. Sorry I have a life and all I'm asking is if he has a release date in mind, so get off my ass. I know strmnnrmn will have r6 when he's ready so don't asct like I'm stupid you jackass.

Morgan said...

act* (typo)

Morgan said...

"It is people like you that make developers loose interest in their projects."


Just about all my posts have ahd keep up the great work or nice job strmnnrmn at the end of about all of them. So yeah make some more sense you fuckin clown. StrmnNrmn I'm not in a great mood because of some of these losers but please keep up the great work.

PS. R6 will get here when it gets here, I said that and then you tell me it and try to call me stupid, lol!

StrmnNrmn said...

bigmace: There will be a minor speed increase as a side-effect of fixing the memory leak, but probably nothing noticable. As disturbd1 says, it's mostly been a graphical update.

morgan: I think there will always things to be improved. It's going to be a relatively slow process of incremental updates though!

wally: I think I mentioned this to you on MSN, but I have fixed the screenshot glitch, yes (it was getting in an infinite loop trying to create the directory for the screenshots on the memory stick).
Let's hope the memory leak fix sorts out the issues with Rugrats etc :)

psdoideka: The 'symmetry problems' are a due to the PSP not supporting mirrored textures (which are used in a few places on the N64). There are a couple of ways of getting around this (namely mirroring the texture in software as required), but I've not gotten around to this yet.

infernomax: I think I'll continue to release the two seperate builds for the time being.

StrmnNrmn said...

knutselmaaster/psdoideka: yup, the flickering has been fixed :)

tsurumaru: That's pretty much what I'm thinking. Ideally I'd like the ME to handle all the RSP processing (which is essentially the display audio list HLE processing), with the CPU emulation on the first core. As the N64 is designed around this parallelism I think this would make the best use of the available resources.

_psycho: I've lost track of how much of my original dynarec ideas are implemented - it's probably something like 50-60% though.

wally: I felt bad about leaving all these comments unanswered so I decided to have a quick run through them now :)

Zodionic said...
This comment has been removed by a blog administrator.
Zodionic said...

http://img.gamespot.com/
gamespot/images/2003/screen2/
197771_20030620_screen020.jpg

AND

http://pspupdates.qj.net/
uploads/articles_module/57643/
zeldapsp.jpg

now speak no more of htis zombie fellow and his FAKE emu, and concentrate on Daedalus

Zodionic