-
Notifications
You must be signed in to change notification settings - Fork 111
Procedural City
This project aims to design and implement procedural workflow for city modeling.
The building shape is defined by the mass model, a simplified representation of a building structure.
To refine the building we slice it into individual modular components. We organize modules by levels, vertical segments of a building. The level can contain one or more floors.
Base Modules: corner, wall, entrance. Additional Modules: Wall Cap, Transition (designed to be scaled to fill the gaps), Pillar/Column. The building modules are generated in a specific size, size is stored in a module dictionary as width and height.
Shape Grammar represents an architectural style so it may be reproduced on buildings (mass models) of different sizes.
Once building modules are defined, we need to assemble them to create a facade.
Shape grammar includes levels:
The shape grammar is stored in a "BDF" JSON file.
BDF stands for Building Definition File and contains building style and assembly data:
{
"levels":
"0": {
"Level_index": 0,
"Level_height": 3.2,
"Level_rule": {
"F0": ["C|(A)|C", "C|(B)|(C-D)*|(B)|C"],
"S0": ["C|(W)|C", "(A)"]
}
},
"modules": {
"A": {
"width": 2.4
}
}
}
The Building Profile is a starting point for building creation that defines building shape. If we extrude the Building Profile on a certain distance (building height) we get the building "Mass Model".
In Houdini, we split Building Profile into primitives (see Building Profile example image above that has 4 primitives: 0, 1, 2, 3) and each primitive will be a facade base. Extruding the facade base will give us a facade.
- From "Geo" context: Scene Import (All) or Sop Import nodes.
- From USD File: Sublayer or Asset Reference nodes
- The SOP Modify node, Unpack USD Primitives to Polygons check box
- The SOP Modify node, go inside, and create the Unpack USD node.
The USD ROP node, set Save Style to Flatten Stage
In the geometry context, all meshes will be brought into Solaris as a single mesh. Introduce the "name" attribute to split mesh into different pieces.
Create material: Quick Surace Material and then Assign Material or Material Linker. Add node Name to geometry nodes to get different objects in USD
Create Mesh Edit node, turn ON Subdivision Scheme, drag and drop mesh primitive to the Primitives field. To control the quality of subdivision add Render Geometry Settings, set Dising > Dising Quality
USD/Solaris geometry prep: define material assignment by Houdini groups (create a group for each material on geometry), then if you add a "Name" node after groups, USD file will contain mesh divided by groups and in Solaris, you will be able to assign materials by those groups.
Remove internal edges of a polygon: Divide SOP > Remove Shared Edges
[1] The Matrix Awakens: Creating a World | Tech Talk | State of Unreal 2022. https://www.youtube.com/watch?v=xLVJP-o0g28