SFML community forums

Help => Graphics => Topic started by: dydya-stepa on December 05, 2011, 03:11:12 pm

Title: Does it make sense to use texture atlases with sfml?
Post by: dydya-stepa on December 05, 2011, 03:11:12 pm
Just saw some notes about texture atlases in another thread.

Does it make sense to use them with sfml? Upcoming graphics API for sfml ?
Title: Does it make sense to use texture atlases with sfml?
Post by: Laurent on December 05, 2011, 03:19:03 pm
Yes, it always makes sense because changing the current texture is a costly operation for the graphics driver.
Title: Does it make sense to use texture atlases with sfml?
Post by: dydya-stepa on December 05, 2011, 06:23:49 pm
how costly is it?
Title: Does it make sense to use texture atlases with sfml?
Post by: Laurent on December 05, 2011, 07:32:34 pm
I really don't know what kind of answer you expect, with such a question.

50 dollars? :lol:
Title: Does it make sense to use texture atlases with sfml?
Post by: dydya-stepa on December 05, 2011, 08:45:30 pm
maybe you have some estimates like let's say we draw 1000 sprites and get 100 fps without optimization, with atlases we get 200. Then it make sense. If we get 102 fps with optimization then it's useless.
Title: Does it make sense to use texture atlases with sfml?
Post by: Laurent on December 05, 2011, 09:23:50 pm
There are so many things that can impact the result, it's really impossible to say. Some may see a huge improvement, some others may not see any difference.

That's why you should test and profile your own application before applying this kind of optimization. Only real numbers are meaningful.