SFML community forums
Help => Graphics => Topic started by: Richy19 on February 28, 2012, 10:14:00 pm
-
I moved my map from lots of sprites to just 1 vertex array and I was messing around with the window view making it follow the mouse(as in the future I will make it follow he player) and I get transparent lines at some positions.
this is the code:
SFML.Graphics.View view = new SFML.Graphics.View(new SFML.Window.Vector2f(wid/2.0f,80)
, new SFML.Window.Vector2f(wid,160));
window.SetView(view);
And this is what happens:
(http://i.imgur.com/XZNsp.png)
It seems to be picking up a line of pixels from the tile bellow it on the tilesheet
-
This can happen when the using decimal coordinates, or when the size of the view is not a multiple of the size of the window.
-
This can happen when the using decimal coordinates, or when the size of the view is not a multiple of the size of the window.
So i should use floats as the findow position and center?
And if the window is 640x640 then I can use 160 as the view size right?