<?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: Texturizing only on specific parts of wall in ArcGIS CityEngine Questions</title>
    <link>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027158#M10108</link>
    <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/452987"&gt;@ArtNow&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Treat texturing as the final mesh object and you will encounter this error much less.&amp;nbsp; &amp;nbsp;For example make a rule:&lt;/P&gt;&lt;P&gt;Final_Wall_wTexture--&amp;gt;&amp;nbsp;&lt;SPAN&gt;setupProjection(0, scope.xy, 1, 1)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;texture(test)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;projectUV(0)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Replace your "Wall." rule with this rule and delete the texturing part at the beginning in Wall1.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Use this rule any time you think you are at the model's last branch of the shape tree (instead of making an unused shape with no rule like "Wall."&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;Further note, to make all the textures look seemless even though they are different meshes, try to use the setupProjection&amp;nbsp;("world.x,y,or z")&amp;nbsp; as opposed to scope, or possibly try using the tileUV rule.&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;But, If you want to texture early in the process you will have to use the deleteUV rule when you get to the shape with the problems.&amp;nbsp; But it's harder in my opinion to keep track of texturing this way.&lt;/P&gt;</description>
    <pubDate>Wed, 17 Feb 2021 12:33:33 GMT</pubDate>
    <dc:creator>Anonymous User</dc:creator>
    <dc:date>2021-02-17T12:33:33Z</dc:date>
    <item>
      <title>Texturizing only on specific parts of wall</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027111#M10107</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have an isssue with texturizing walls of my building model. What I want to is to texturize only walls but leave objects (e.g. window and door) without additional texture, because these objects have their own textures defined. Here is my cga script and screenshot of current model:&lt;/P&gt;&lt;LI-SPOILER&gt;&lt;P&gt;testWall --&amp;gt;&lt;BR /&gt;extrude(4)&lt;BR /&gt;comp(f){front : Wall1}&lt;/P&gt;&lt;P&gt;Wall1 --&amp;gt;&lt;BR /&gt;setupProjection(0, scope.xy, 1, 1)&lt;BR /&gt;texture(test)&lt;BR /&gt;projectUV(0)&lt;BR /&gt;&lt;BR /&gt;split(x){ '0.5 : Window | '0.5 : Doors }&lt;BR /&gt;&lt;BR /&gt;Window --&amp;gt;&lt;BR /&gt;split(x){ ~1 : Wall.&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; | 1 : split(y){ ~1 : Wall.&lt;BR /&gt;&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;| 1 : WindowAsset&lt;BR /&gt;&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;| ~1 : Wall. }&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; | ~1 : Wall. }&lt;BR /&gt;&lt;BR /&gt;Doors --&amp;gt;&lt;BR /&gt;split(x){ ~1 : Wall.&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; | 1.5 : split(y){ 2.5 : DoorsAsset&lt;BR /&gt;&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;| ~1 : Wall. }&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; | ~1 : Wall. }&lt;BR /&gt;&lt;BR /&gt;WindowAsset --&amp;gt;&lt;BR /&gt;i(window)&lt;BR /&gt;mirror(false,false,true)&lt;BR /&gt;set(material.specular.r, 0)&lt;BR /&gt;set(material.specular.b, 0)&lt;BR /&gt;set(material.specular.g, 0)&lt;BR /&gt;&lt;BR /&gt;DoorsAsset --&amp;gt;&lt;BR /&gt;i(plain_door)&lt;BR /&gt;mirror(false,false,true)&lt;BR /&gt;set(material.specular.r, 0)&lt;BR /&gt;set(material.specular.b, 0)&lt;BR /&gt;set(material.specular.g, 0)&lt;/P&gt;&lt;/LI-SPOILER&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="ArtNow_0-1613467826665.png" style="width: 400px;"&gt;&lt;img src="https://community.esri.com/t5/image/serverpage/image-id/6119i8CE7F0434FF6B0E1/image-size/medium?v=v2&amp;amp;px=400" role="button" title="ArtNow_0-1613467826665.png" alt="ArtNow_0-1613467826665.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 16 Feb 2021 09:33:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027111#M10107</guid>
      <dc:creator>ArtNow</dc:creator>
      <dc:date>2021-02-16T09:33:17Z</dc:date>
    </item>
    <item>
      <title>Re: Texturizing only on specific parts of wall</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027158#M10108</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/452987"&gt;@ArtNow&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Treat texturing as the final mesh object and you will encounter this error much less.&amp;nbsp; &amp;nbsp;For example make a rule:&lt;/P&gt;&lt;P&gt;Final_Wall_wTexture--&amp;gt;&amp;nbsp;&lt;SPAN&gt;setupProjection(0, scope.xy, 1, 1)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;texture(test)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN&gt;projectUV(0)&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Replace your "Wall." rule with this rule and delete the texturing part at the beginning in Wall1.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Use this rule any time you think you are at the model's last branch of the shape tree (instead of making an unused shape with no rule like "Wall."&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;Further note, to make all the textures look seemless even though they are different meshes, try to use the setupProjection&amp;nbsp;("world.x,y,or z")&amp;nbsp; as opposed to scope, or possibly try using the tileUV rule.&amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;But, If you want to texture early in the process you will have to use the deleteUV rule when you get to the shape with the problems.&amp;nbsp; But it's harder in my opinion to keep track of texturing this way.&lt;/P&gt;</description>
      <pubDate>Wed, 17 Feb 2021 12:33:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027158#M10108</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2021-02-17T12:33:33Z</dc:date>
    </item>
    <item>
      <title>Re: Texturizing only on specific parts of wall</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027808#M10111</link>
      <description>&lt;P&gt;Thanks! That works perfectly for me.&lt;/P&gt;</description>
      <pubDate>Wed, 17 Feb 2021 20:30:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1027808#M10111</guid>
      <dc:creator>ArtNow</dc:creator>
      <dc:date>2021-02-17T20:30:45Z</dc:date>
    </item>
    <item>
      <title>Re: Texturizing only on specific parts of wall</title>
      <link>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1061334#M10157</link>
      <description>&lt;P&gt;Another way would be similar to how the facade and windows are textured in Tutorial 6.&lt;/P&gt;&lt;P&gt;&lt;A href="https://doc.arcgis.com/en/cityengine/latest/tutorials/tutorial-6-basic-shape-grammar.htm" target="_blank"&gt;https://doc.arcgis.com/en/cityengine/latest/tutorials/tutorial-6-basic-shape-grammar.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;The idea is that the UVs are setup across the whole facade when the facade is created using &lt;FONT face="courier new,courier"&gt;setupProjection()&lt;/FONT&gt;.&amp;nbsp; Then, the rule goes on to break up the facade into walls and windows.&amp;nbsp; On the wall pieces, the texture is assigned using &lt;FONT face="courier new,courier"&gt;texture()&lt;/FONT&gt;, and the UVs are projected onto the shape using &lt;FONT face="courier new,courier"&gt;projectUV()&lt;/FONT&gt;.&amp;nbsp; On the window pieces, you can either insert geometry that already has UVs in which case those UVs will be used, or you can insert a &lt;FONT face="courier new,courier"&gt;primitiveQuad()&lt;/FONT&gt; which automatically has UVs on it, or you can assign UVs to the window shape using &lt;FONT face="courier new,courier"&gt;setupProjection()&lt;/FONT&gt;.&amp;nbsp; Here's a simplified version of what Tutorial 6 does.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;Lot --&amp;gt;
	extrude(height)
	comp(f) { front: Facade }
	
Facade --&amp;gt;
	setupProjection(0, scope.xy, 1.5, 1)	// setup 1.5m x 1m texture tiles across whole facade
	split(y) { ~floor_height: Floor }*
	
Floor --&amp;gt;
	split(x) { ~tile_width: Tile }*
	
Tile --&amp;gt;
	split(x) { ~1: Wall
			 | window_width: split(y) { ~1: Wall
			 						  | window_height: Window
			 						  | ~1: Wall }
			 | ~1: Wall }
			 
Wall --&amp;gt;
	texture(wall_tex)
	projectUV(0)

Window --&amp;gt;
	i(window_asset)	// uses UVs on inserted asset
	texture(randomWindowTexture)
	
// alternative window option
Window2 --&amp;gt;
	primitiveQuad	// has UVs that stretch across quad
	texture(randomWindowTexture)

// alternative window option
Window3 --&amp;gt;
	setupProjection(0, scope.xy, '1, '1)	// define UVs that stretch across scope of shape
	texture(randomWindowTexture)
	projectUV(0)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 25 May 2021 14:15:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-cityengine-questions/texturizing-only-on-specific-parts-of-wall/m-p/1061334#M10157</guid>
      <dc:creator>CherylLau</dc:creator>
      <dc:date>2021-05-25T14:15:07Z</dc:date>
    </item>
  </channel>
</rss>

