SFML community forums

Help => Graphics => Topic started by: wintertime on October 12, 2013, 08:41:27 pm

Title: RectangleShape vs Sprite
Post by: wintertime on October 12, 2013, 08:41:27 pm
I tried to find the difference between using a RectangleShape and a Sprite by reading the docs, but they seem to have mostly the same functionality, only that a RectangleShape can have a size, an outline and the option to not use a Texture. I assume a Sprite should just get scaled instead of setting a size?
Whats the usecase where a Sprite should be prefered? Is it just a bit more efficient?
Title: Re: RectangleShape vs Sprite
Post by: Nexus on October 12, 2013, 08:56:23 pm
Please search before posting (use Google if you have issues with the forum search).
http://en.sfml-dev.org/forums/index.php?topic=6677
http://en.sfml-dev.org/forums/index.php?topic=7715
http://en.sfml-dev.org/forums/index.php?topic=11952
Title: Re: RectangleShape vs Sprite
Post by: wintertime on October 13, 2013, 12:20:28 am
Well sorry, I had read in the forum often already and several pages deep at that and had not seen such a thread, so it didnt occur to me to use the automatic search for something even older.
I have read those threads now, but the thing with only the shape having a size to be set is still a bit unclear to me. I think I'll try switching to the sprite and see how it works then.