Basemap generation for Terrain.
Hi,
as the thread-title already says, I am interested in creating a basemap for my terrain with different textures and a heightmap. So far I thought about using the degree of the angle between vertices and the height of the vertice itself as criteria for the texture to use.
Are there any other things to take into consideration ?
Any advice (and maybe a link or screenshot :-) would be greatly appreciated...
^_^
Here are a couple of links (though they are old):
One
Two
Also, although it's not really a texture generation method, you might want to look at texture splatting.
[Edited by - Gage64 on August 15, 2008 1:28:09 PM]
One
Two
Also, although it's not really a texture generation method, you might want to look at texture splatting.
[Edited by - Gage64 on August 15, 2008 1:28:09 PM]
Quote:Original post by Zaph-0I have used this scheme, and it works pretty well, although I used a few enhancements. You can in fact do this per-pixel, entirely in the shader - take a look at Ysaneya's Journal for details.
as the thread-title already says, I am interested in creating a basemap for my terrain with different textures and a heightmap. So far I thought about using the degree of the angle between vertices and the height of the vertice itself as criteria for the texture to use.
It is easiest to calculate the angle instead as the dot product between the terrain normal and the vertical, i.e. dot(n, (0,1,0)).
Then you probably want to add some noise to both the height and the angle, because otherwise the transitions are very sharp. If you are doing this in a shader, you can use a small texture filled with several octaves of perlin noise.
Lastly, use the height and angle values (after adding noise) to lookup a value in a 2D-lookup table (as another texture/image), which contains the id of the texture to use. This lets you tweak the look of the terrain just by changing an image, rather than having to work on a complex algorithm.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement