AnsweredAssumed Answered

Aligning sub-shapes to terrain

Question asked by geonetadmin on Jun 26, 2013
Latest reply on Jul 2, 2013 by nicolaisteino2
Original User: nicolaisteino2

I am working on a script which simulates Utzon's famous Fredensborg houses http://bit.ly/15EuuaA which are chains of patio houses which align to a sloping terrain.

I have two problems:

1. I can't figure out how to correctly align the individual houses within the scheme �?? which is generated from a single lot-shape �?? to the terrain. As it shows in the pics, the houses seem to sink into the lot shape, and even more so into the terrain. It seems on the one hand, that the lot-shape does not recognize local hills and depressions within the area of the lot-shape. Furthermore, the sub-shapes of the buildings don't seem to align correctly to the lot-shape.

Is there a way to correct this?

2. As it can be seen in the reference photos, the footprint of the houses is an L-shape. The roofs are shed roofs which incline inward. This means that there is a roof valley in the knee of the L-shape.

Is there a neat way �?? or any way at all �?? to generate this type of roof for this type of footprint?

Regards,

Nic

--

/**
* File:    utzon_rule.cga
* Created: 25 Jun 2013 21:09:22 GMT
* Author:  nic
*/

version "2012.1"

attr width01 = 75
attr width02 = width01
attr width03 = 22
attr bldgH = 3.5
attr bldgW01 = 9
attr bldgW02 = 7
attr wallW = 0.35
attr wallH = 2
attr pathW = 2
attr roofA = 25
attr footprintShift = width03/4
attr outsideWidth = (width01-width03)*0.50
@range(-90,90)
attr rotation = 0
attr randomGrey = listRandom("#ffffff;#0000ff;#ff00ff;#00ffff;#000000")

Lot --> rotateScope(0, rotation, 0) split(x) { ~width01 : Left | ~width02 : Right }*
Left --> innerRect split(z) { ~width03+footprintShift : Strip01 | { ~width03 : Strip02 }* }
Right --> innerRect split(z) { { ~width03 : Strip02 }* | ~width03+footprintShift : Strip03 }
Strip01 --> case scope.sx < width03*2 : NIL
   else : split(x) { width03 : Strip01Split01 | width03 : Strip01Split02 | ~1 : NIL }
Strip02 --> case scope.sx < width03*2 : NIL
   else : split(x) { outsideWidth+rand(-footprintShift, footprintShift) : NIL | width03 : Plot }
Strip03 --> case scope.sx < width03*2 : NIL
   else : split(x) { width03 : Strip01Split02 | width03 : Strip01Split01 | ~1 : NIL }
Strip01Split01 --> split(z) { width03 : Plot | ~1 : NIL }
Strip01Split02 --> rotateScope(0, 180, 0) Strip01Split01

Plot --> color(listRandom("#cccccc;#0000ff;#ff00ff;#00ffff;#333333")) shapeL(bldgW01, bldgW02) { shape : Footprint | remainder: Exterior }
Exterior --> rotateScope(0,180,0) shapeL(wallW, wallW) { shape : Wall | remainder: NIL }
Footprint --> alignScopeToAxes(y) s('1,0,'1) extrude(world.y, bldgH) Envelope
Envelope --> comp(f) { top : Top | side : Side. }
Top --> convexify() roofShed(roofA)
Wall --> alignScopeToAxes(y) s('1,0,'1) extrude(world.y, wallH)

Attachments

Outcomes