Skip to main content
GameDev.net gamedev.net
🔒 Locked

D3DXSprite

Started by Maverick the divider Jun 9, 2002 at 12:00 PM 2 replies 350+ views
Original Post
Maverick the divider
Maverick the divider
Everyone keeps saying D3DXSprite is slow. But maybe anyone knows what makes it slow so it could be worked upon? --- Keep it simple, stupid
---Quite soon...ICQ: 163187735
granat
granat
I may not be optimized fully but it''s probably fast enough for most purposes.
-------------Ban KalvinB !
DrunkenHyena
DrunkenHyena
D3DXSprite is designed to be simple yet flexible, for that you compromise speed.

Basically, all it does is draw a quad with the texture you provide. Rolling your own (if needed) is pretty easy.

If you need higher performance, the biggest win is batching your calls so you are drawing a few hundred triangles rather than D3DXSprite''s 2 per call.


Stay Casual,

Ken
Drunken Hyena
Stay Casual,KenDrunken Hyena</FON
Maverick the divider
Maverick the divider
Oh, thanks for the info.
I just tested how fast it is to render 1000 quads (2 unindexed triangled) using 1 big vertex buffer and 1000 quads (2 trianglestrip) calling drawprimitive 1000 times.
Believe it or not - the results are almost identical!
I get 117 fps with 1 big vb, and 114 with 1000 times calling draw primitive.
uuugh...
---Quite soon...ICQ: 163187735

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.