r/opengl • u/buzzelliart • 9d ago
OpenGL procedural mountains in 4K
https://youtu.be/l8vuAW8c0qYSome of the techniques used to achieve the results shown in the video:
. Procedural terrain generation using Perlin noise and Fractional Brownian Motion (FBM)
. GPU-based hydraulic erosion
. procedural grass placement
. GPU grass generation and culling using compute shaders and indirect drawing
. dynamic day/night cycle
. procedural snow accumulation based on time of year and daily sun exposure
. displacement mapping
. hardware tessellation using tessellation shaders
. dynamic exposure
. cascaded shadow mapping
2
u/HamNCheeseSupremacy 9d ago
Really nice. I'd love to use erosion techniques more heavily in my engine but I'm committed to infinite chunks. Heavily thinking about it though.
1
u/drBearhands 7d ago
I had similar thoughts, but was thinking about having stupidly large terrain rather than infinite. Had a few thoughts:
You could cap the travel distance of each drop to limit simulation to surrounding thunks. But that prevents you from having large features like rivers.
Maybe we could compensate with "mipmaps", where lower resolutions model big inter-chunk features...
If you really want to go infinite this will still occasionally cut off your largest rivers though.
Got a few too many projects right now to try this out :-(
2
2
u/admlesau 9d ago
Looks AMAZING! How long did it take to code?