Skip to content

jeromeetienne/threex.proceduralcity

Repository files navigation

threex.proceduralcity.js

It is a three.js extension to display a fully procedural city based on "city" , a demo recently released by @mrdoob. You can try a demo live and check its source. Here is a more basic example and its source.

NOTE: see full implementation details in "How to Do a Procedural City in 100 Lines" post from learningthreejs blog.

How To Install It

You can install it manually or with bower. for the manual version, first include threex.proceduralcity.js with the usual

<script src='threex.proceduralcity.js'></script>

or with bower you type the following to install the package.

bower install -s threex.proceduralcity=https://github.com/jeromeetienne/threex.proceduralcity/archive/master.zip

then you add that in your html

<script src="bower_components/threex.rendererstats/threex.rendererstats.js"></script>

How To Use It

Super simple, just create an instance and it will return a THREE.Mesh

var city  = new THREEx.ProceduralCity()
scene.add(city) 

The demo live contains this city plus a ground, a first personn controls and a fog. This is rather cool result for as little effort.

About

a procedural city generator for three.js based on mrdoob demo

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published