1
Graphics / Re: SFML Tile Map Tearing
« on: May 30, 2014, 07:01:54 pm »
Thanks Nexus,
While minifying code I've tracked 99% of the tearing down to anti-aliasing. I only get very small vertical tears now while jumping, probably due to another significant rounding mistake. There is no tearing now while not moving. Do you have any explanation as to why this has such a drastic effect? I understand it's not absolutely necessary in my case due to the pixelart style of the application; but I didn't see any harm in using it anyway.
I have indeed made a small code sample: It's mostly based on the example given in the tutorial:
Main.cpp:
Tilemap.hpp:
I've attached a small tileset for demonstration purposes. Commenting/uncommenting line 9 in Main.cpp shows some tearing (at least on my systems).
So again, thanks for all your help!
While minifying code I've tracked 99% of the tearing down to anti-aliasing. I only get very small vertical tears now while jumping, probably due to another significant rounding mistake. There is no tearing now while not moving. Do you have any explanation as to why this has such a drastic effect? I understand it's not absolutely necessary in my case due to the pixelart style of the application; but I didn't see any harm in using it anyway.
I have indeed made a small code sample: It's mostly based on the example given in the tutorial:
Main.cpp:
(click to show/hide)
Tilemap.hpp:
(click to show/hide)
I've attached a small tileset for demonstration purposes. Commenting/uncommenting line 9 in Main.cpp shows some tearing (at least on my systems).
So again, thanks for all your help!