A terrain visualizer tool made in C++ using OpenGL (Glad) and GLFW. Create your own noise context, change the context being used in ChunkDataGenerator.cpp in the GridDataPass function and visualize what the noise function looks like!
Keep in mind that this is my first non-arduino c++ project, the code may be messy. My goal for this project was to write as much code as I could on my own without copying anything 1:1.
[WASD] to move, [Cursor] to aim and [Space] to increase your speed
- Changing the chunk generation bound to a large value isn't ideal. The world system isn't multithreaded, it was only moved to a different thread than the main game to prevent it from stuttering the framerate. If the bound is too large, you'll need to stop for a moment while the terrain data gets generated before seeing the terrain appear.
- The game uses trilinear sampling to avoid sampling the noise functions in every cell of every chunk. This technique, altought fast, leave multiple artefacts that reveal the underlying "grid" that makes up the world.
- Implement a biome system that blends different noise context toghether.
- Make the terrain generation multithreaded, give priority to the chunks closer to the player, and make sure the grid data generation doesn't prevent the mesh from being generated in parrallel.
- Make the noise system data oriented instead of requiring to manually edit the code
- Implement water and transparent meshes
- Implement structure generation
- Implement grass generation
https://0fps.net/2013/07/03/ambient-occlusion-for-minecraft-like-worlds/
https://github.com/KdotJPG/Scattered-Biome-Blender
https://github.com/Auburn/FastNoiseLite
https://github.com/Hopson97/HopsonCraft/blob/master/Source/Maths/Frustum.cpp
https://youtube.com/playlist?list=PLlrATfBNZ98dudnM48yfGUldqGD0S4FFb