This project focuses on generating realistic terrains with infinite resolution using Python. By leveraging Numba, the generator achieves high computational efficiency, enabling detailed exploration from large-scale continents to small valleys.
It creates a base map using diamond-square algorithm. And combines interpolation of the base map and finer frequency FBM noise to generate zoomable maps.
| Level | Resolution | Asset |
|---|---|---|
| 1 - Zone | ~100 km | ![]() |
| 2 - County | ~50 km | ![]() |
| 3 - Cluster | ~25 km | ![]() |
| 4 - City | ~12 km | ![]() |
| 5 - Town | ~6 km | ![]() |
| 6 - Village | ~3 km | ![]() |
| 7 - Hamlet | ~1.5 km | ![]() |
- Infinite terrains: Generate heightmaps at any zoom level.
- Realistic erosion: Simulate thermal, hydraulic and wind erosion for natural-looking landscapes.
- Customizable: Adjust parameters to create diverse and unique terrains.
- Visualization tools: Preview terrains in both 2D and 3D.
- Optimized performance: Critical computations are accelerated using Numba.
git clone https://github.com/your-username/infinite-terrain-generator.git
cd infinite-terrain-generator
pip install -r requirements.txtfrom terrain_lod import Terrain
# Create a terrain instance
t = Terrain(seed=42, erode=True)
# Generate a heightmap
t.plot(lim=(0.0, 1.0, 0.0, 1.0), zlim=(0, 3), save_path="world.png")For additional examples, refer to example.ipynb.
map_maker/
├── terrain_lod/
│ ├── terrain.py # Core terrain generation logic
│ ├── erosion.py # Erosion simulation algorithms
│ ├── noise.py # Noise generation functions
│ └── helper.py # Supporting utilities
├── assets/ # Sample images
├── example.ipynb # Interactive notebook
└── README.md
This project is licensed under the MIT License. You are free to use and modify it as needed.






