-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added documentation and production fixes
- Loading branch information
1 parent
7e3a710
commit c946781
Showing
4 changed files
with
9 additions
and
702 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,15 @@ | ||
 | ||
|
||
# Displacement Cities | ||
|
||
Generating a cityscape from a 2D noise pattern. | ||
|
||
## Generating the city mesh by interpreting the pattern as a heightmap | ||
Inspired by [/u/ckinggfx on /r/Blender](https://www.reddit.com/r/blender/comments/k05280/sprawling_city_from_a_single_plane/). | ||
|
||
## Generating the city mesh by interpreting a noise pattern as a heightmap | ||
|
||
We create simple plane with subdivisions higher or equal to the noise pattern width in pixels. | ||
We create simple plane with subdivisions higher or equal to the [noise pattern](https://github.com/kevinleguillou/displacement-cities/blob/develop/assets/noise.png) width in pixels. | ||
|
||
## Apply a patchwork texture of city buildings | ||
|
||
The main issue here is to correctly project the texture on the displaced geometry, since the regular UVs would just stretch the texture. We define a specific projection in the fragment shader that assumes a side projection. | ||
The main issue here is to correctly project [the texture](https://github.com/kevinleguillou/displacement-cities/blob/develop/assets/skyscrappers.jpg) on the displaced geometry, since the regular UVs would just stretch the texture. We define a specific projection in the [fragment shader](https://github.com/kevinleguillou/displacement-cities/blob/develop/src/DisplacementCity/DisplacementCity.frag) that assumes a side projection. |
Large diffs are not rendered by default.
Oops, something went wrong.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters