Tuesday, March 25, 2014

Procedural Colosseum

Procedural rules are normally associated with creating detailed 3D models for a large set of data.

CGA (Computer Generated Architecture) rules are also effective in terms of reducing the time it takes to create a detailed landmark (such as the Colosseum) manually. This post shows a simple process and the code that was used to create a quick landmark.


A simple arch and ledge object (.dae) was created in Sketch Up, which was used on the outer level.

Arch collada object from SketchUp

The Colosseum footprint digitized manually as a shapefile from the ArcGIS Imagery basemap.

Oval footprint shapefile

The code with some comments is below:




The Result:





























Thursday, March 13, 2014

Random Tree Generation using 3D Vegetation Library

The 3D Vegetation Models Library from LumenRT is a very user friendly way of creating quick, realistic urban vegetation with a variety of plant species.

The library offers a large variety of trees (some of which I have never used). I wanted the CGA rule to create trees for my shapes at random, from a specified selection. A small alteration to the CGA code changes the default value.

For this example I used the Plant_Loader_with_LumenRT_Models.cga

The Plant_Loader_with_LumenRT_Models.cga uses the Name attribute to determine the file path of the model. The "Alder Buckthorn" model is used as a default. As seen below.



By changing the Name attribute to a conditional attribute, and setting a probability for specified plant models, the CGA rule will automatically assign models to shapes. In the example below, only 20 tree models were specified with a propablity of 5% each.



The resulting rule only assigns the models  that were specified as a default. Keeping the original @Range annotation in order to still be able to select any of the other available models.