<?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 Roof type by shapefile attribute in ArcGIS CityEngine Questions</title>
    <link>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691269#M9106</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the roof type as an attribute in my footprint (shapefile attribute table) and I want to assign the&amp;nbsp;roof&amp;nbsp;type directly in the CGA rule, not in the inspector. For example, all my gable roof footprints have ''41'' as the value in that field and I want the CGA rule to generate gable roof for any building footprint with the same value without doing&amp;nbsp;it manually in the inspector.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 11 Jul 2018 13:38:51 GMT</pubDate>
    <dc:creator>NavidMoghadam</dc:creator>
    <dc:date>2018-07-11T13:38:51Z</dc:date>
    <item>
      <title>Roof type by shapefile attribute</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691269#M9106</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi everyone,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have the roof type as an attribute in my footprint (shapefile attribute table) and I want to assign the&amp;nbsp;roof&amp;nbsp;type directly in the CGA rule, not in the inspector. For example, all my gable roof footprints have ''41'' as the value in that field and I want the CGA rule to generate gable roof for any building footprint with the same value without doing&amp;nbsp;it manually in the inspector.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jul 2018 13:38:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691269#M9106</guid>
      <dc:creator>NavidMoghadam</dc:creator>
      <dc:date>2018-07-11T13:38:51Z</dc:date>
    </item>
    <item>
      <title>Re: Roof type by shapefile attribute</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691270#M9107</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Navid&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check here : &lt;A href="https://community.esri.com/thread/200641"&gt;GIS Diven Building.cga and building footprints&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Or&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You have to create or to modify a cga file. To see some samples get the Tutorial &lt;A class="link-titled" href="https://www.arcgis.com/home/item.html?id=1746ca6086dd41a49549541438a50531" title="https://www.arcgis.com/home/item.html?id=1746ca6086dd41a49549541438a50531"&gt;https://www.arcgis.com/home/item.html?id=1746ca6086dd41a49549541438a50531&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You will need to choose one attribute on your shapefile to put the information about the roof type and use something like :&lt;/P&gt;&lt;P&gt;attr Roof_Form = "hip"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Roof --&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "shed"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: ShedRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "pyramid"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: PyramidRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "gable"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: GableRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "hip"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: HipRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "half-hip"&amp;nbsp;&amp;nbsp; &amp;nbsp;: HalfHipRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "gablet"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: GabletRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "gambrel"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: GambrelRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "mansard"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: MansardRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "gambrel-flat": GambrelFlatRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "mansard-flat": MansardFlatRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "vault"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: VaultRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "dome"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: DomeRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "saltbox"&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: SaltboxRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;case Roof_Form == "butterfly"&amp;nbsp;&amp;nbsp; &amp;nbsp;: ButterflyRoof&lt;BR /&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;else&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;nbsp;: FlatRoof&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jul 2018 14:21:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691270#M9107</guid>
      <dc:creator>Luiz_AmadeuCoutinho</dc:creator>
      <dc:date>2018-07-11T14:21:39Z</dc:date>
    </item>
    <item>
      <title>Re: Roof type by shapefile attribute</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691271#M9108</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use a case. This should work..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;attr RoofValue = 0

@StartRule
Lot --&amp;gt;
&amp;nbsp;&amp;nbsp; case RoofValue == 41: generateRoofGable
&amp;nbsp;&amp;nbsp; else:&amp;nbsp;generatePyramid

generateRoofGable --&amp;gt;
&amp;nbsp;&amp;nbsp; roofGable(30)
&amp;nbsp;&amp;nbsp; color(1,0,0)

generatePyramid --&amp;gt;
&amp;nbsp;&amp;nbsp; roofPyramid(30)
&amp;nbsp;&amp;nbsp; color(1,0,1)&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 05:05:28 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691271#M9108</guid>
      <dc:creator>LR</dc:creator>
      <dc:date>2021-12-12T05:05:28Z</dc:date>
    </item>
    <item>
      <title>Re: Roof type by shapefile attribute</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691272#M9109</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you so much!&lt;/P&gt;&lt;P&gt;Cheers&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jul 2018 15:31:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/roof-type-by-shapefile-attribute/m-p/691272#M9109</guid>
      <dc:creator>NavidMoghadam</dc:creator>
      <dc:date>2018-07-11T15:31:54Z</dc:date>
    </item>
  </channel>
</rss>

