Simple test of spritebatch

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
User avatar
Ref
Party member
Posts: 702
Joined: Wed May 02, 2012 11:05 pm

Simple test of spritebatch

Post by Ref »

Thought I'd share a test script.
Just trying to see what effect a large number of quads in a spritebatch had on frame rate and what happens when a portion of a spritebatch is off the screen (frame rate increases).
Of course, I couldn't just try one thing so all kinds of stuff added (just to confuse things).
Script contains:
quads (10,000)
SpriteBatch
PixelEffect
mapPixel
mouse_contriol (a mouse selection menu system)
scrollbar (parameter adjustment)
but NO canvases!
In spite of all the junk, am able to get 100 fps on my laptop.
Attachments
poor_lena.love
A test script
(50.27 KiB) Downloaded 241 times
User avatar
frpnit
Prole
Posts: 21
Joined: Fri Oct 12, 2012 1:05 am
Location: Brazil
Contact:

Re: Simple test of spritebatch

Post by frpnit »

Spritebatches are very effective, i've done a simple test before on my machine (a core i7) and in an old one (a pentium D with intel 950 integrated graphics) - just scrolling a tiled map with arrow keys - and the difference was impressive, if i'm not remembering wrong, the test ran 2.3 times faster on the old machine, and 6x faster on my i7.

I really do not understand why people have complains about spritebatches.
FRP
  • Graphic Designer
  • Hobbyst Programmer
[/color]
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Amazon [Bot] and 3 guests