Jump to content
  • Advertisement
Sign in to follow this  

Linear Filtering Across Terrain Tile Boundaries

This topic is 4732 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi, I am using a multi-pass splatting technique using an alpha mask to splat terrain textures on top of each other (a mask for each texture). I am using linear filtering on the alpha texture stage so that the boundary blends over nicely, but it seems that alpha mask at the edge of the tile seems to blend out to zero, thus showing through the texture underneath when I don't want it to. I can see this is a problem, as the rendering engine does not know how to blend the texture next to it when it doesn't even know what that texture is. Does what I am saying make any sense, or should I provide screenshots? If it does make sense, how have you guys worked around this? Thanks

Share this post


Link to post
Share on other sites
Advertisement
This might not be the answer you're looking for, but anyway...
I'm using colors in vertices instead of alpha-texture. That's a variation of original splatting.
One of the things that made me to do this is that alpha textures (or pre-made textures for each tile) were succesfully polluting GPU cache, making the whole rendering much slower (or maybe the reason was something else, but the point is, that WAS slowing me down).

So, with so-called vertex alpha, the problem does not exist.
If I remember well, the original author of splatting technique didn't solve this problem as well.

Cheers.
/def

Share this post


Link to post
Share on other sites
Quote:
Original post by deffer
This might not be the answer you're looking for, but anyway...
I'm using colors in vertices instead of alpha-texture. That's a variation of original splatting.
One of the things that made me to do this is that alpha textures (or pre-made textures for each tile) were succesfully polluting GPU cache, making the whole rendering much slower (or maybe the reason was something else, but the point is, that WAS slowing me down).

So, with so-called vertex alpha, the problem does not exist.
If I remember well, the original author of splatting technique didn't solve this problem as well.

Cheers.
/def


Interesting. Does the terrain need to be one big mesh though in order for the tile problem not to exist? Surely the edge vertex in one tile is still not aware of the edge vertex in another if they are being rendered as seperate primitives?

Share this post


Link to post
Share on other sites
Quote:
Original post by Raeldor
Interesting. Does the terrain need to be one big mesh though in order for the tile problem not to exist? Surely the edge vertex in one tile is still not aware of the edge vertex in another if they are being rendered as seperate primitives?


No,no,no, you can still use tiles with this technique. You can do that, because vertices in neighbour tiles partially overlap. Like:


1-2-3 3-a-b b-r-s
| | | | | | | | |
4-5-6 6-c-d d-t-u
| | | | | | | | |
7-8-9 9-e-f f-v-w




And when drawing triangle "6,8,9", you do not need any data from 'c' or 'e'. That's the difference between texture interpolation and color interpolation. You won't ever need to cross the border of your original geometry to render it ;)

Hope it's clear.
/def

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!