Creating a U or L shape on another shape

1487
2
09-18-2013 03:48 PM
DavidKenley
New Contributor
Hello,

I have the following code for creating a U shape, I'm attempting to essentially extrude a cube, and add a uShape on top using comp(f).

I have attached two images, if I use my start rule as "RoofTier" it creates a ushape no problem. If I use my start rule as Lot, it will extrude my lower part of the building, but the u shape is incorrect. This also happens to L shapes. Note I'm just using the "Null" rule in this case to make my floor/ceiling planes.

Does anyone have any insight? I know from images I've seen this is very possible.

Thanks!

David


version "2012.1"

attr myFrontDepth = 5
attr myRightWidth = 5
attr myLeftWidth = 5


Lot -->
    extrude(20)
 comp(f) { top : Roof | all : Null}
  
Roof -->
 Null
 RoofTier

RoofTier -->
     shapeU(myFrontDepth,myRightWidth,myLeftWidth) { shape : Footprint | remainder: NIL }
     
Footprint -->
    extrude(20)
0 Kudos
2 Replies
by Anonymous User
Not applicable
Original User: matthiasbuehler

Hi !


The following operations need a 'yUp scope' :
setback(), shapeL(),shapeO(),shapeU().

a convention is that the scope is oriented zUp after a comp(f), thus the scope needs to be realigned. Otherwise, one experiences that one dimension of those operations to look 'incorrect'.

-->
solution, e.g. :
Roof -->
    alignScopeToGeometry(yUp, 0)
    shapeL(..)



The scope is a very very important concept in CGA, so make sure you understand this and always work with the 'Inspect Model Mode' and the 'Model Hierarchy'.

Also, check this video :
http://forums.arcgis.com/threads/44417-CGA-Understanding-the-concept-of-the-scope

Ok so far ?

Matt
0 Kudos
MakersMakers
New Contributor II

Thank you! Just ran into this problem trying to make a typical "five over two" podium building.

0 Kudos