Jump to content
  • Advertisement
Sign in to follow this  
Sneftel

Multitexturing for tile-hiding

This topic is 4581 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

Recently, I needed to make a nice-looking tiled parchment texture in a minimum amount of texture memory. In order to accomplish this, I used two differently sized tiled parchment textures, with dimensions which were relatively prime to each other, blended together equally. It looks pretty darn good; each of the separate textures has moderately visible tiling, but the result barely shows anything at all. Is this a common technique?

Share this post


Link to post
Share on other sites
Advertisement
I've always found two (or more) layers moving at different speeds to work very well as it's really hard to spot a repeating pattern when you do it right. Nice for cheap water and fire effects.
Using micro and macro-textures is a known method, but I haven't really seen scales being made prime to each other on purpose so far. Good thinking. :)

Share this post


Link to post
Share on other sites
Quote:
Original post by Captain P
I haven't really seen scales being made prime to each other on purpose so far. Good thinking. :)

I've been doing some thinking about the relative primality. It worked for me, but my intuition says it isn't the best metric out there. For instance, while 10 and 49 are relatively prime, they are close enough to not being relatively prime that tiling will be visible every 50 pixels "or so". In contrast, 10 and 45 are not relatively prime but would show less tiling (they exactly tile every 90 pixels).

Any math gurus wanna chime in on whether this "fuzzy primality" has a mathematical formalism? It seems like the fuzziness would depend on the spatial frequency spectrum of the textures.

Share this post


Link to post
Share on other sites
I do something similar with my sky background (two textures with carefully chosen frequencies, scrolling at different speeds) and it doesn't appear to tile at all, so the clouds look nice and organic. I havn't thought about using primes to choose the repeat rates though, that could have saved me quite a bit of tweeking time.

Share this post


Link to post
Share on other sites
Conceptually, this is similar to Perlin Noise, and Detail Textures for Terrain. I don't think the default specifications for Perlin specified that the different layers should be Prime to one another; but the basic idea more or less fits those and other 'fractal-ish' procedural generation ideas.

I think someone on this board made an infinite terrain based on the idea of making the layers Prime like yours so it would never repeat.(he used the texture as a heightmap) Been a while tho, I dont remember who it was...

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.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!