<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic How to convert 'ShapeO' to 'SetbackToArea' in ArcGIS CityEngine Questions</title>
    <link>https://community.esri.com/t5/arcgis-cityengine-questions/how-to-convert-shapeo-to-setbacktoarea/m-p/1127497#M10372</link>
    <description>&lt;P&gt;&lt;STRONG&gt;Hi, im student of Urban Planning &amp;amp; Design.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;i got CGA Rule file. that makes each floor building setback.&lt;/P&gt;&lt;P&gt;but, this rule contains ShapeO Operation.&amp;nbsp;&lt;/P&gt;&lt;P&gt;ShapeO Operation work with setback distance.&lt;/P&gt;&lt;P&gt;but, i don't fix setback distance exactly.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Instead of a distance, I want to setback a certain area(through SetbackToArea).&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the ShapeO Operation Doc, maybe ShapeO can convert setback option.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://doc.arcgis.com/en/cityengine/latest/cga/cga-shapeo.htm" target="_blank" rel="noopener"&gt;https://doc.arcgis.com/en/cityengine/latest/cga/cga-shapeo.htm&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;i tried through this Doc, but i failed to convert.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So, i wanna change How to convert 'ShapeO' to 'SetbackToArea'.&lt;/SPAN&gt;&lt;/P&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;&lt;STRONG&gt;I will attach it below 'ShapeO' original CGA Rule File Code.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;#####################################################################################&lt;BR /&gt;# ATTRS&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@Group("BUILDING",0) @Order(0)&lt;BR /&gt;attr nFloors = 15&lt;BR /&gt;@Group("BUILDING") @Order(1)&lt;BR /&gt;attr groundFloorHeight = 5.5&lt;BR /&gt;@Group("BUILDING") @Order(2)&lt;BR /&gt;attr upperFloorHeight = 3.5&lt;BR /&gt;@Group("BUILDING") @Order(3)&lt;BR /&gt;attr volumeChange_1_floor = 2&lt;BR /&gt;@Group("BUILDING") @Order(4)&lt;BR /&gt;attr volumeChange_2_floor = 5&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@Group("1",1) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_1 = 0&lt;BR /&gt;@Group("1") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_1 = 5.9&lt;BR /&gt;@Group("1") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_1 = 0&lt;/P&gt;&lt;P&gt;@Group("2",2) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_2 = 0&lt;BR /&gt;@Group("2") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_2 = 0&lt;BR /&gt;@Group("2") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_2 = 0&lt;/P&gt;&lt;P&gt;@Group("3",3) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_3 = 5&lt;BR /&gt;@Group("3") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_3 = 0&lt;BR /&gt;@Group("3") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_3 = 2&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;#####################################################################################&lt;BR /&gt;# FUNCTIONS&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;floorHeightFunction(floorID) =&lt;BR /&gt;case floorID == 1:&lt;BR /&gt;groundFloorHeight&lt;BR /&gt;else :&lt;BR /&gt;upperFloorHeight&lt;/P&gt;&lt;P&gt;setbackID (n) =&lt;BR /&gt;case n &amp;gt;= rint(volumeChange_2_floor) :&lt;BR /&gt;3&lt;BR /&gt;case n &amp;gt;= rint(volumeChange_1_floor) :&lt;BR /&gt;2&lt;BR /&gt;else :&lt;BR /&gt;1&lt;BR /&gt;&lt;BR /&gt;setbackDimension (n, side) =&lt;BR /&gt;case setbackID(n) == 3:&lt;BR /&gt;case side == "front" : frontSetback_3&lt;BR /&gt;case side == "back" : backSetback_3&lt;BR /&gt;else : sideSetback_3&lt;BR /&gt;case setbackID(n) == 2:&lt;BR /&gt;case side == "front" : frontSetback_2&lt;BR /&gt;case side == "back" : backSetback_2&lt;BR /&gt;else : sideSetback_2&lt;BR /&gt;else :&lt;BR /&gt;case side == "front" : frontSetback_1&lt;BR /&gt;case side == "back" : backSetback_1&lt;BR /&gt;else : sideSetback_1&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;#####################################################################################&lt;BR /&gt;# START&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@StartRule&lt;BR /&gt;Shape --&amp;gt;&lt;BR /&gt;BuildingRecursion(1) # start with floor '1' = ground floor&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;BuildingRecursion(n) --&amp;gt;&lt;BR /&gt;case n &amp;gt; rint(nFloors) :&lt;BR /&gt;NIL&lt;BR /&gt;&lt;BR /&gt;else :&lt;BR /&gt;extrude(world.y, floorHeightFunction(n))&lt;BR /&gt;FloorVolume(n)&lt;/P&gt;&lt;P&gt;# back to recursion&lt;BR /&gt;comp(f) {top : BuildingRecursion(n + 1)}&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;FloorVolume(n) --&amp;gt;&lt;BR /&gt;comp(f) {bottom:&lt;BR /&gt;reverseNormals&lt;BR /&gt;alignScopeToAxes(y)&lt;BR /&gt;&lt;BR /&gt;shapeO(setbackDimension (n, "front"),&lt;BR /&gt;setbackDimension (n, "side"),&lt;BR /&gt;setbackDimension (n, "back"),&lt;BR /&gt;setbackDimension (n, "side"))&lt;BR /&gt;{shape : NIL |&lt;BR /&gt;remainder : extrude(world.y, floorHeightFunction(n))&lt;BR /&gt;Floor.}}&lt;/P&gt;&lt;P class=""&gt;#####################################################################################&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;P class=""&gt;P.s What's mean 'Floor.' ? i don't understand why 'Floor.' is there.&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;I'd really appreciate it if you could answer.&lt;/P&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 20 Dec 2021 00:40:48 GMT</pubDate>
    <dc:creator>JINHWANJUN</dc:creator>
    <dc:date>2021-12-20T00:40:48Z</dc:date>
    <item>
      <title>How to convert 'ShapeO' to 'SetbackToArea'</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/how-to-convert-shapeo-to-setbacktoarea/m-p/1127497#M10372</link>
      <description>&lt;P&gt;&lt;STRONG&gt;Hi, im student of Urban Planning &amp;amp; Design.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;i got CGA Rule file. that makes each floor building setback.&lt;/P&gt;&lt;P&gt;but, this rule contains ShapeO Operation.&amp;nbsp;&lt;/P&gt;&lt;P&gt;ShapeO Operation work with setback distance.&lt;/P&gt;&lt;P&gt;but, i don't fix setback distance exactly.&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Instead of a distance, I want to setback a certain area(through SetbackToArea).&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;In the ShapeO Operation Doc, maybe ShapeO can convert setback option.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&lt;A href="https://doc.arcgis.com/en/cityengine/latest/cga/cga-shapeo.htm" target="_blank" rel="noopener"&gt;https://doc.arcgis.com/en/cityengine/latest/cga/cga-shapeo.htm&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;i tried through this Doc, but i failed to convert.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;So, i wanna change How to convert 'ShapeO' to 'SetbackToArea'.&lt;/SPAN&gt;&lt;/P&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;&lt;STRONG&gt;I will attach it below 'ShapeO' original CGA Rule File Code.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;#####################################################################################&lt;BR /&gt;# ATTRS&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@Group("BUILDING",0) @Order(0)&lt;BR /&gt;attr nFloors = 15&lt;BR /&gt;@Group("BUILDING") @Order(1)&lt;BR /&gt;attr groundFloorHeight = 5.5&lt;BR /&gt;@Group("BUILDING") @Order(2)&lt;BR /&gt;attr upperFloorHeight = 3.5&lt;BR /&gt;@Group("BUILDING") @Order(3)&lt;BR /&gt;attr volumeChange_1_floor = 2&lt;BR /&gt;@Group("BUILDING") @Order(4)&lt;BR /&gt;attr volumeChange_2_floor = 5&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@Group("1",1) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_1 = 0&lt;BR /&gt;@Group("1") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_1 = 5.9&lt;BR /&gt;@Group("1") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_1 = 0&lt;/P&gt;&lt;P&gt;@Group("2",2) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_2 = 0&lt;BR /&gt;@Group("2") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_2 = 0&lt;BR /&gt;@Group("2") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_2 = 0&lt;/P&gt;&lt;P&gt;@Group("3",3) @Order(0) @Range(0,5)&lt;BR /&gt;attr frontSetback_3 = 5&lt;BR /&gt;@Group("3") @Order(1) @Range(0,5)&lt;BR /&gt;attr backSetback_3 = 0&lt;BR /&gt;@Group("3") @Order(2) @Range(0,5)&lt;BR /&gt;attr sideSetback_3 = 2&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;#####################################################################################&lt;BR /&gt;# FUNCTIONS&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;floorHeightFunction(floorID) =&lt;BR /&gt;case floorID == 1:&lt;BR /&gt;groundFloorHeight&lt;BR /&gt;else :&lt;BR /&gt;upperFloorHeight&lt;/P&gt;&lt;P&gt;setbackID (n) =&lt;BR /&gt;case n &amp;gt;= rint(volumeChange_2_floor) :&lt;BR /&gt;3&lt;BR /&gt;case n &amp;gt;= rint(volumeChange_1_floor) :&lt;BR /&gt;2&lt;BR /&gt;else :&lt;BR /&gt;1&lt;BR /&gt;&lt;BR /&gt;setbackDimension (n, side) =&lt;BR /&gt;case setbackID(n) == 3:&lt;BR /&gt;case side == "front" : frontSetback_3&lt;BR /&gt;case side == "back" : backSetback_3&lt;BR /&gt;else : sideSetback_3&lt;BR /&gt;case setbackID(n) == 2:&lt;BR /&gt;case side == "front" : frontSetback_2&lt;BR /&gt;case side == "back" : backSetback_2&lt;BR /&gt;else : sideSetback_2&lt;BR /&gt;else :&lt;BR /&gt;case side == "front" : frontSetback_1&lt;BR /&gt;case side == "back" : backSetback_1&lt;BR /&gt;else : sideSetback_1&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;#####################################################################################&lt;BR /&gt;# START&lt;BR /&gt;#####################################################################################&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;@StartRule&lt;BR /&gt;Shape --&amp;gt;&lt;BR /&gt;BuildingRecursion(1) # start with floor '1' = ground floor&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;BuildingRecursion(n) --&amp;gt;&lt;BR /&gt;case n &amp;gt; rint(nFloors) :&lt;BR /&gt;NIL&lt;BR /&gt;&lt;BR /&gt;else :&lt;BR /&gt;extrude(world.y, floorHeightFunction(n))&lt;BR /&gt;FloorVolume(n)&lt;/P&gt;&lt;P&gt;# back to recursion&lt;BR /&gt;comp(f) {top : BuildingRecursion(n + 1)}&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;FloorVolume(n) --&amp;gt;&lt;BR /&gt;comp(f) {bottom:&lt;BR /&gt;reverseNormals&lt;BR /&gt;alignScopeToAxes(y)&lt;BR /&gt;&lt;BR /&gt;shapeO(setbackDimension (n, "front"),&lt;BR /&gt;setbackDimension (n, "side"),&lt;BR /&gt;setbackDimension (n, "back"),&lt;BR /&gt;setbackDimension (n, "side"))&lt;BR /&gt;{shape : NIL |&lt;BR /&gt;remainder : extrude(world.y, floorHeightFunction(n))&lt;BR /&gt;Floor.}}&lt;/P&gt;&lt;P class=""&gt;#####################################################################################&lt;/P&gt;&lt;P class=""&gt;&amp;nbsp;&lt;/P&gt;&lt;P class=""&gt;P.s What's mean 'Floor.' ? i don't understand why 'Floor.' is there.&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;P class=""&gt;I'd really appreciate it if you could answer.&lt;/P&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;/DIV&gt;&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 20 Dec 2021 00:40:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/how-to-convert-shapeo-to-setbacktoarea/m-p/1127497#M10372</guid>
      <dc:creator>JINHWANJUN</dc:creator>
      <dc:date>2021-12-20T00:40:48Z</dc:date>
    </item>
  </channel>
</rss>

