More than 24 sprites?

PM development, programming, hacking and all that fun stuff.
Post Reply
zoranc
Posts: 297
Joined: August 13th, 2010, 18:13
Contact:

More than 24 sprites?

Post by zoranc » February 14th, 2013, 13:01

Yesterday I was looking into the PRC documentation int the sublab wiki. Then while reading about the interrupts Found a sentence that says:

"It is not uncommon for commercial games to disable the render done IRQ, and simply probe the strobe manually. Shock tetris uses this to double the number of on screen sprites."

Can someone elaborate it for me please? If one disables the IRQ the processor will not run at all I think, since it is disabled during the PRC activity. Second how the lack of IRQ activation help to increase the number of sprites? Finally how the Tetris games makes use of more sprites?

For those curious, for a while I am toying with the idea to port a nice game to PM, but in order to make it look beter I might need more sprites... That's why I am asking this.

User avatar
Agilo
PM.net Staff
Posts: 34
Joined: October 1st, 2008, 01:38
Location: The Netherlands
Contact:

Re: More than 24 sprites?

Post by Agilo » February 15th, 2013, 00:08

I'll let asterick explain.
Had to go back in time using my old chat logs for this one (dated May 16, 2008). :P
<asterick> 24
<asterick> and you can multiplex them.
<asterick> shock tetris does it.
<asterick> it's kinda cool how you do it.
<Wa> idk what multiplex means
<asterick> means to you change the sprites every frame to make more appear.
<Wa> oh
<asterick> essnetially... frame 0: Disable Frame copy, enable map render (blank screen), and draw 24 characters with sprites, wait for the VPU draw to go high, clear the flag, disable map renderer, and change the 24 sprites, repeat until all characters are drawn, disable map and sprite renderer, enable frame copy.
<asterick> the only problem is it takes number of visible characters / 24 frames to display.
<asterick> and 1 frame is at most 1/33rd a second.
<asterick> sooo, if you have 792 onscreen characters, it takes 1 second to render it all.
<asterick> the plus to that is characters can be all sorts of wacky sizes, and overlap each other.
<asterick> also they don't have to be aligned to any axis.

zoranc
Posts: 297
Joined: August 13th, 2010, 18:13
Contact:

Re: More than 24 sprites?

Post by zoranc » February 25th, 2013, 16:00

Oh I see. Thanks a lot for the answer!

That effectively means that frame rate is divided by 2. So it is at most around 16-17 FPS in highest refresh rate with one sprite set multiplexing. If I add a gray shade then the FPS falls down to about 8 FPS or so, and it would be probably noticeable...

Post Reply