My water layer is now also a vegetation layer

In one of those can’t sleep because your mind is too busy… my trees were looking good, but still really slow the scene when there are more than a hundred fully grown trees and trying to think of LOD strategies… I realized my water layer was wasting all the vertices that are under the terrain where there is no water. So now it also is a vegetation layer. Where there is no water, it will set height and color/transparency by vegetation density. I will use this to ‘render’ very distant tree as deformations in the vegetation heights. Higher vegetation in the palette is less opaque. When I calculate tree cloud volume when tree grows I can update the vegetation. So I don’t have to render distant trees at all they will be part of the water/veg layer. It will just fail to work for trees that are in the water. Just a little vegetation makes the static Castle Terrain and its nice textures, spring to life. And this costs no more processor or graphics. Just another grid of values which is small compared to the graphics. Here distant trees are still rendered and there are about 400 fully gown trees. But that puts framerate down to 7fps. I think using the water/vegetation for the distant trees will get us back above 30, as the water layer is already working fast.

2 Likes

Here is a prototype of trees that deform the water/veg layer instead of being models. In the foreground are the grown trees in the background, the pointy trees are just random placed deformation, I don’t have the real trees tied to these yet. It would look great for pointy pine trees. Whole forests will clump together and if based on the actual tree leaf clouds, should look less pointy and more like canopy topography.

2 Likes

This whole scene is just 25 castle terrain tiles (5x5), each with their corresponding water/veg mesh. No models. This works out to 2.5km by 2.5 km at my 1unit = 5meters scale.


1 Like

100 ‘real’ trees up close. 1000 water mesh based trees everywhere.

2 Likes

A lonely road cuts through the terrain. Trees are now tied to the vegetation data, so here there are trees, but the models are all turned off. The road cuts the vegetation to 0 on the terrain vertices it had to deform to make a nice road.

2 Likes

A lot of fine tuning for how water and vegetation data mix to set which palette points to use resulting in more subtlety and variety. Here a road cuts through the vegetation, but the water flows across the road.
The old flow would flow in the same direction first, followed in order by the rest, but now sorts by the delta, so flows steepest downhill first and remainder goes to the less steep. This makes the streams look more natural.


I love how the rarely seen castleterrain cliff texture shows up where the terrain was cut by the road. I still have yet to see the mud texture.

1 Like

There was a bug in that water flow and it was sorting flow priority by the pointer to the delta value, not by the value itself. All because I forgot to make a method override haha. This worked to create a randomish precedence but was not ideal (though better than before). Here is proper precedence sorting on the delta. Much better. It would be pretty easy to add erosion at this point, especially when I get the terrain changes to be faster. I tried it in the past but my code was too clunky back then.

1 Like