Tesselated Terrain - Version 1.6 [with download]

NOTE: This version is outdated, you can find the new version here: https://discourse.panda3d.org/viewtopic.php?f=6&t=16216

This is my tesselated terrain I’ve done in panda3d. The whole terrain is based on shaders, and splitted in four different level-of-details. It still has some artifacts at the chunk / LOD-borders, and the textures will get improved, but I’ll fix that soon. There are currently only two textures, but it is possible to add more if needed …

Video:
http://youtu.be/uf–DnKrJNw

Screenshots:

Download version 5 (outdated):
– Seems not to run on ATI cards, see the patch provided by ninth –
https://www.dropbox.com/s/272gr0dl7gfbmoy/terrain.zip

Features:
- Tesselated Terrain (4 Lods)
- GPU Computed, very fast (runs at ~400 fps with collisions enabled, ~500 fps without collisions @ GTX 670)
- Three detailmaps (1 unused yet)
- Heightmap resolution up to 8K8K, currently 2K2K

Wow that looks really nice! Any plans to share your work?

Yeah, but I’ll finish the terrain code first. As you might see, there are visible holes between the different lods …

It’s Really nice!!!

This is a friendly community so if you will share your source when done, why you don’t do it now and get some help from panda pro?

Download Link (unfinished & old version): [see above for a newer link]

Thanks for source sharing :slight_smile:.
I try to run your sample but there is no thing show !!! It said:

:gobj(error): Cg program too complex for driver: /home/anhsaodem/Desktop/tesselated/shader/terrain.cg. Try choosing a different profile.

Some screenshoots.

My System:
AMD Radeon 5470M - With newest AMD Driver
Core i3 330m, 4GB RAM
Xubuntu 12.10 64 bit

I has same problem when try to push a texture to vertex shader (vshader - Cg) to setHeight for geoMipMap. I try many solution but nothing better.
I try to use glsl (with Ninth’s advise) by and it run.
[url]push texture to vshader sha file]
This my case
http://www.youtube.com/watch?v=7HTEZ_pX0bc

Try to remove the line “//Cg profile gp4vp gp4fp” from shaders/terrain.cg. It might be your video card does not support this profile …

Edit: Additionally you can try to replace the profile line with “//Cg profile glslf glslv”

I see some code of your Cg file. You used a texture in vertex shader and it seem not support by my video card and maybe almost ATI video Card. But when use GLSL to process. It’s running normally. I will try to upload Ninth’s code. His code working for all.

Ps. I don’t know which video card you used but 200 FPS is awesome :slight_smile:

Hehe its a GTX670 :stuck_out_tongue:

Edit: I’ll ask a friend with an ATI Card, see if it runs there …

UPDATE

  • More Atmospheric
  • Objects at distance get blurred
  • Optimisations (Now runs at ~400 Fps)
  • Changed Heightmap

That’s looking very impressive! You seem to still have a few minor holes in your terrain, but otherwise it looks very convincing, I do think. :slight_smile:

If I may, the distance blur feels a little heavy to me: I very much like the effect, but think that it might be better if toned down just a little.

Finally, are you slightly desaturating and blue-tinting distant terrain? If not, it might be worth considering – it should increase the verisimilitude of the scene, I think.

These minor holes you see are between the different level-of-details … i still had no time to fix that :slight_smile:
The distance blur seems a bit heavy, but that’s only the perspective … ingame the mountain you see is about 2km away from you … but i’ll adjust it a bit :slight_smile:
Yeah, something like that:

o_color = (o_color -0.2) * 1.2

But thanks for that hints! :slight_smile:

My Tobias! Why you no use fog instead blur it !!! With linear fog it will be more beautiful. I sure about that.

I already use fog, additionaly to the blur :slight_smile: you can see it in the first screenshot … but maybe I will make it a bit stronger …

UPDATE

  • Added more Fog
  • Decreased distance blur a bit
  • Used some other hints (see posts above)

More impressive still! :slight_smile:

Forgive me please if I seem nitpicky, but I think that you may have turned up the blue-tinting for distant trrain a little [i]too[i] much. ^^; (Nevertheless, I do think that it’s an improvement over the previous version!)

Thanks for your Feedback! :slight_smile:

Yeah, I’ll adjust it in the next version … :slight_smile: thanks for that hint, again :slight_smile:

Video for version 5
http://www.youtube.com/watch?v=d8E_592ydtQ

And Version 6:
http://youtu.be/uf–DnKrJNw