SFML community forums

Help => Graphics => Topic started by: Ben_ on February 20, 2016, 03:31:20 pm

Title: How to scale position and size?
Post by: Ben_ on February 20, 2016, 03:31:20 pm
I am trying to make a game, and I want it to support multiple resolutions.

All I need to do is simply scale the sprites, but from my tests, it only scales the size when I need it to scale both size and position.

Does SFML allow me to do this? Or should I make my own functions to scale the position?
Title: Re: How to scale position and size?
Post by: Nexus on February 20, 2016, 04:02:58 pm
You cannot "scale position", it makes no sense. What do you mean?

Can you show an illustration/sketch of what you want to achieve?
Title: Re: How to scale position and size?
Post by: Laurent on February 20, 2016, 04:34:10 pm
I think he means zooming the whole scene, not just resizing entities without changing their position.

Use views, this is exactly what they do.