<?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 Re: &amp;quot;edgeattr array&amp;quot; new feature, sampling the streetWidth for streetfacing lots  in ArcGIS CityEngine Questions</title>
    <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299702#M4180</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;Shapes&lt;/STRONG&gt; -&amp;gt; &lt;STRONG&gt;Compute Edge Attributes&lt;/STRONG&gt; can only be done on shapes that are not dynamic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;streetWidth&lt;/SPAN&gt; attribute can be used for dynamic lot shapes that are automatically created by street networks.&amp;nbsp; However, note that this attribute is different than the edge attribute &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;/edgeattr/streetwidths&lt;/SPAN&gt; that is calculated for non-dynamic shapes.&amp;nbsp; The &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;streetWidth&lt;/SPAN&gt; attribute does not include sidewalk widths, and it does not project to the nearest street (lot sides not touching a street get 0).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See also:&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" class="link-titled" href="https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386" title="https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386"&gt;https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" class="link-titled" href="https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075" title="https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075"&gt;https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 19 Jun 2020 11:40:47 GMT</pubDate>
    <dc:creator>CherylLau</dc:creator>
    <dc:date>2020-06-19T11:40:47Z</dc:date>
    <item>
      <title>"edgeattr array" new feature, sampling the streetWidth for streetfacing lots</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299698#M4176</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all&lt;/P&gt;&lt;P&gt;Say you have a lot which you have subdivided in several minilots using CGA attributes.&lt;/P&gt;&lt;P&gt;All minilots belong to the same shape. All minilots are extruded upward and their vertical facades are separated with split comp.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is it possible to use the new function&lt;STRONG&gt;&amp;nbsp;&lt;SPAN class="" style="font-size: 15.9375px;"&gt;edgeAttr.getFloat(&lt;/SPAN&gt;&lt;SPAN style="color: #4c4c4c;"&gt;&lt;EM&gt;&lt;SPAN class=""&gt;attributeName&lt;/SPAN&gt;&lt;/EM&gt;&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;SPAN class="" style="font-size: 15.9375px;"&gt;&lt;STRONG&gt;)&lt;/STRONG&gt; &lt;/SPAN&gt;to sample the&lt;SPAN class="" style="font-size: 15.9375px;"&gt; &lt;STRONG&gt;streetWidth&lt;/STRONG&gt; &lt;STRONG&gt;Object Attribute&lt;/STRONG&gt; &lt;/SPAN&gt;of each miniLot facade?&lt;/P&gt;&lt;P&gt;&lt;SPAN class="" style="font-size: 15.9375px;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;To add extra complexity, all the streets are curved, not straight, so there are not 1 single street value per side, but several.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/migrated-users/26220"&gt;Simon Haegler&lt;/A&gt;&amp;nbsp;, &lt;A href="https://community.esri.com/migrated-users/172220"&gt;Cheryl Lau&lt;/A&gt;, any idea? &lt;IMG src="https://community.esri.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;A&lt;/P&gt;&lt;P&gt;&lt;SPAN class="" style="font-size: 15.9375px;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 13 Jun 2020 15:13:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299698#M4176</guid>
      <dc:creator>AbeleGiandoso</dc:creator>
      <dc:date>2020-06-13T15:13:46Z</dc:date>
    </item>
    <item>
      <title>Re: "edgeattr array" new feature, sampling the streetWidth for streetfacing lots</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299699#M4177</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi there,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Shapes generated via CGA cannot sample other values on a per-leaf basis. Means you'll get one initial attribute that will be constant for all the shape (and it's successor shapes you create via CGA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cheers,&lt;/P&gt;&lt;P&gt;matt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;matthias buehler &lt;/STRONG&gt;| founder &amp;amp; CTO | msc arch eth zurich&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Jun 2020 11:18:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299699#M4177</guid>
      <dc:creator>MatthiasBuehler3</dc:creator>
      <dc:date>2020-06-16T11:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: "edgeattr array" new feature, sampling the streetWidth for streetfacing lots</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299700#M4178</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;If you have lots that are not dynamic (i.e. not generated automatically by street networks) and streets in the scene, then it is possible to use edge attributes to sample street widths.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To mimic your case, I created a lot with 4 buildings on it.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;Lot --&amp;gt;
	split(x) { ~cell_size: split(z) { ~cell_size: Cell }* }*

Cell --&amp;gt;
	offset(-offset_dist, inside)
	extrude(10)
	Mass‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&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;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The lot is surrounded by streets with widths as indicated in the (last) screenshot below.&amp;nbsp; Select the lot, go to &lt;STRONG&gt;Shapes&lt;/STRONG&gt; -&amp;gt; &lt;STRONG&gt;Compute Edge Attributes&lt;/STRONG&gt;.&amp;nbsp; This will create object attributes with the prefix &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;/edgeattr/&lt;/SPAN&gt;.&amp;nbsp; Streetwidths are calculated based on the streets near the shape.&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://doc.arcgis.com/en/cityengine/latest/help/help-compute-attributes.htm" title="https://doc.arcgis.com/en/cityengine/latest/help/help-compute-attributes.htm" rel="nofollow noopener noreferrer" target="_blank"&gt;Compute edge attributes tool—ArcGIS CityEngine Resources | Documentation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jive-emoji image-1 jive-image" height="103" src="https://community.esri.com/legacyfs/online/496887_object_attributes_edgeAttrs.png" width="341" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This code samples the edge attribute &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;streetwidths&lt;/SPAN&gt; for each side of each building and resizes the facade according to the sampled value.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;Mass --&amp;gt;
	comp(f) { side: Side }
	
Side --&amp;gt;
	s('1, edgeAttr.getFloat("streetwidths"), '1)
	set(material.opacity, 0.5)&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;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Sampling happens by projecting the current shape geometry onto the outline of the initial shape.&amp;nbsp; Note that in your case with curvy streets where a building side might correspond to multiple streets, the function will only sample one of the streets.&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://doc.arcgis.com/en/cityengine/latest/cga/cga-edge-attr-function.htm" title="https://doc.arcgis.com/en/cityengine/latest/cga/cga-edge-attr-function.htm" rel="nofollow noopener noreferrer" target="_blank"&gt;edgeAttr functions—ArcGIS CityEngine Resources | Documentation&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="" class="jive-emoji jive-image image-2 j-img-original" src="https://community.esri.com/legacyfs/online/496895_sample_edgeAttr_streetwidths.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 14:22:37 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299700#M4178</guid>
      <dc:creator>CherylLau</dc:creator>
      <dc:date>2021-12-11T14:22:37Z</dc:date>
    </item>
    <item>
      <title>Re: "edgeattr array" new feature, sampling the streetWidth for streetfacing lots</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299701#M4179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&amp;nbsp;&lt;A _jive_internal="true" data-userid="172220" data-username="CLau-esristaff" href="https://community.esri.com/people/CLau-esristaff" style="color: #8ca9cd; background-color: #ffffff; border: 0px; font-weight: 200; text-decoration: none; font-size: 1.286rem;"&gt;Cheryl&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Thanks! Makes sense now.&amp;nbsp;&lt;/P&gt;&lt;P&gt;So if I understand correctly&amp;nbsp;these attributes are &lt;SPAN style="text-decoration: underline;"&gt;only &lt;/SPAN&gt;created when Lots are &lt;SPAN style="text-decoration: underline;"&gt;not&lt;/SPAN&gt; dynamic then&amp;nbsp;and there is no way to do a similar thing for Dynamic lots, correct? To query the streetWidth list of&amp;nbsp;a&amp;nbsp;dynamic shape.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;A.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 17 Jun 2020 15:15:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299701#M4179</guid>
      <dc:creator>AbeleGiandoso</dc:creator>
      <dc:date>2020-06-17T15:15:20Z</dc:date>
    </item>
    <item>
      <title>Re: "edgeattr array" new feature, sampling the streetWidth for streetfacing lots</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299702#M4180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;Shapes&lt;/STRONG&gt; -&amp;gt; &lt;STRONG&gt;Compute Edge Attributes&lt;/STRONG&gt; can only be done on shapes that are not dynamic.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;streetWidth&lt;/SPAN&gt; attribute can be used for dynamic lot shapes that are automatically created by street networks.&amp;nbsp; However, note that this attribute is different than the edge attribute &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;/edgeattr/streetwidths&lt;/SPAN&gt; that is calculated for non-dynamic shapes.&amp;nbsp; The &lt;SPAN style="font-family: 'courier new', courier, monospace;"&gt;streetWidth&lt;/SPAN&gt; attribute does not include sidewalk widths, and it does not project to the nearest street (lot sides not touching a street get 0).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;See also:&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" class="link-titled" href="https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386" title="https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386"&gt;https://community.esri.com/thread/199406-designate-multiple-street-edges#comment-722386&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;and&lt;/P&gt;&lt;P&gt;&lt;A _jive_internal="true" class="link-titled" href="https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075" title="https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075"&gt;https://community.esri.com/message/852677-re-streetwidth-used-in-setback#comment-855075&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Jun 2020 11:40:47 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/quot-edgeattr-array-quot-new-feature-sampling-the/m-p/299702#M4180</guid>
      <dc:creator>CherylLau</dc:creator>
      <dc:date>2020-06-19T11:40:47Z</dc:date>
    </item>
  </channel>
</rss>

