Texture or Image?

I happen to be using Sfml for graphics and was wondering if I should use images or textures for sprites.

Does it matter?
Yes I read that...

I thought you may also be able to use a sprite with an image...
As mentioned in the tutorial you read, you may create a sf::Texture from an sf::Image and use the resulting sf::Texture for your sprite.
The main difference between sf::Image and sf::Texture:

- Image is stored in CPU memory (good for reading/writing pixels)
- Texture is stored in GPU memory (good for drawing)


If you are not going to be making manual changes to pixel data (or reading pixel data), there is zero reason to use sf::Image, and you can use sf::Texture for everything.
Topic archived. No new replies allowed.