An open API service indexing awesome lists of open source software.

https://github.com/takana671/voronoicity

VoronoiCity is a procedually created city in the image of Tokyo.
https://github.com/takana671/voronoicity

3d-shapes panda3d python3 skybox voronoi-noise

Last synced: 5 months ago
JSON representation

VoronoiCity is a procedually created city in the image of Tokyo.

Awesome Lists containing this project

README

          

# VoronoiCity

When I was looking at the Voronoi noise with rounded edges, I felt like I could create a city using the white edges as roads. 3D shapes were stacked and rotated to look like buildings and placed within the Voronoi regions with the image of Tokyo. Noise, 3D shapes, and skybox were all created procedurally.
See below.

https://github.com/taKana671/NoiseTexture
https://github.com/taKana671/shapes
https://github.com/taKana671/skybox

Mouse drag to rotate the entire city.

![Image](https://github.com/user-attachments/assets/f6f41979-a581-4e1f-a866-87b4665e9789)

# Requirements
* Panda3D 1.10.15
* numpy 2.2.4

# Environment
* Python 3.12
* Windows11

# Usage

#### Clone this repository with submodule.
```
git clone --recursive https://github.com/taKana671/VoronoiCity.git
```

#### Execute the following command
```
python voronoi_city.py
```

https://github.com/user-attachments/assets/161ab37a-eeb4-4208-9c7b-bc80149b089c

#### Key control


key
description


Esc
Close the screen.


t
Toggles physical object display on and off.


i
Click on a building and press the [i] key, its position and angle will be displayed on the console.


r
Releases the building selected by pressing the i key.


w
Toggles wireframe display on and off.


v
Switch between sky view mode and moving view mode.

In `skyview mode`, you can view the city from above and rotate the entire city by dragging the mouse.
`moving view mode` allows you to move around the city by keystrokes below.


key
description


up arrow
Move forward.


left arrow
Turn left.


right arrow
Turn right.


down arrow
Move backward.


u
Go up.


d
Go down.