[?-R106] Lines around tiled backgrounds

0 favourites
  • 10 posts
From the Asset Store
You can change amount and speed of circles, length of lines and etc. Only 6 events.
  • CAPX

    I have discussed this problem before, but now I just made a new and very fast capx sample - you should notice the problem on any game you make with tiled backgrounds.

    I know you just say it's a graphics driver problem - but it's not. It's present on any computer and other commercial games deffinately don't have this issue! I have tried this on various AMD and Nvidia gfx and on both AMD and Intel PC. Unfortunately the same problem is present.

    Try the capx and notice the ugly lines around the top dirt tiles and in the clouds.

    On this sample - pixel rounding is even on - but it doesn't make any difference besides making the movement less smooth.

    Also notice that a tiles made like a sprites (like the dirt corners) doesn't have the problem when pushed against a tiled background tile. The it looks as you would expect it look.

    Actually this problem is worse now than it was before around R100 or maybe R102. I had the problem when using R95, but then it disapeared in some of the later version and then got back around R100-R102.

    I have used so much time trying to eliminate the issue - but nobody seems to notice it.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • To me it seems that you just have poorly cropped images. I can see some thin black lines on your tiles when zoomed closer in image editor.

    Here's a test I made:

    http://dl.dropbox.com/u/53898431/Junk/Tiles_Test.capx

    Do you get any lines with my test?

  • To me it seems that you just have poorly cropped images. I can see some thin black lines on your tiles when zoomed closer in image editor.

    Here's a test I made:

    http://dl.dropbox.com/u/53898431/Junk/Tiles_Test.capx

    Do you get any lines with my test?

    I can make a sample like yours too - but that doesn't help me with my problem. First of all, the problem is worse with scrolling, and scaling. Both with or without letterbox.

    My capx has no cropping in it. All tiles are the right size and has no errors or faults. The dirt tiles are all 32x32 and they are pixel perfect.

    Try my capx in internet explorer too if you like, it much worse there, but it is also terrible in chrome - although better than IE.

  • Maybe you're not crazy after all <img src="smileys/smiley1.gif" border="0" align="middle" />

    It actually seems that there's a one pixel vertical shift. Easiest to see if one tiled background block is flipped 180-degrees and set against the other.

  • Maybe you're not crazy after all <img src="smileys/smiley1.gif" border="0" align="middle" />

    It actually seems that there's a one pixel vertical shift. Easiest to see if one tiled background block is flipped 180-degrees and set against the other.

    YES!

    Also - it's not present in all cases - the sample I have provided is more or less worst case scenario, because of the brown colour and the 32x32 tile size that seems to cause the worst problems.

    I really thing this is a bug and not just my imagination :)

    Btw. my game is almost made entirely of 32x32 tiles so it is a huge problem it that case.

  • But do you have this problem after exporting your project?

  • It's the same...

  • lokesen - believe it or not, this example is actually working normally and is not a bug.

    Obviously, the Tiled Background object wraps its texture, so if you enlarge it the image repeats throughout. However, if the object is sized 32x32 with a 32x32 image, and you zoom in a little (in this case using fullscreen mode), it actually does a tiny bit of wrapping round to the other side of the image at the edges. Imagine the image is still tiled in those directions, just you can't see them because they're outside the bounds of the object. So in this case one edge is black and the rest is brown; the side opposite the black edge will still wrap across to the black-edged side ever so slightly, and this creates a visible seam. It's enough to still seam when pixel rounding and point sampling are on. This is just how computer graphics works and would happen with any tool or framework.

    The workaround: add an extra row of pixels to the image, or resize the image ever so slightly smaller. For example, make the image 32x33 to add an extra row of pixels along the bottom, and make them the same color. Or, just resize the Tiled Background to be e.g. 64x31, so the last row of pixels doesn't wrap around. Or, just position the other backgrounds to slightly overlap and hide the seams.

  • lokesen - believe it or not, this example is actually working normally and is not a bug.

    Obviously, the Tiled Background object wraps its texture, so if you enlarge it the image repeats throughout. However, if the object is sized 32x32 with a 32x32 image, and you zoom in a little (in this case using fullscreen mode), it actually does a tiny bit of wrapping round to the other side of the image at the edges. Imagine the image is still tiled in those directions, just you can't see them because they're outside the bounds of the object. So in this case one edge is black and the rest is brown; the side opposite the black edge will still wrap across to the black-edged side ever so slightly, and this creates a visible seam. It's enough to still seam when pixel rounding and point sampling are on. This is just how computer graphics works and would happen with any tool or framework.

    The workaround: add an extra row of pixels to the image, or resize the image ever so slightly smaller. For example, make the image 32x33 to add an extra row of pixels along the bottom, and make them the same color. Or, just resize the Tiled Background to be e.g. 64x31, so the last row of pixels doesn't wrap around. Or, just position the other backgrounds to slightly overlap and hide the seams.

    Thanks Ashley - I will try to work around it.

  • With your tips I managed to get a perfect result. It's not as easy as I would like - but it works and that's good enough for me.

    Nothing about making a good game is easy - that's just how it is.

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)