Select to view content in your preferred language

Texture in CityEngine

09-28-2018 08:34 AM
New Contributor II

How can i download Facade (Texture)  of building and apply it to my building in CityEngine. Any Tips please. Thanks alot.

Tags (1)
0 Kudos
1 Reply
Esri Regular Contributor

Esri.lib, the library that comes with CityEngine, has rules that can put textures on buildings.

  • Building_From_Footprint.cga: use if your initial shape is a 2D footprint
  • Building_Mass_Texturizer.cga:  use if your initial shape is a 3D mass model

If you'd like to use your own texture image, then you can apply the texture to a model using setupProjection() to do the necessary setup that is needed to determine how to place the texture on the model, then use texture() to assign your texture image file, then use projectUV() to actually perform the projection that is needed to apply the texture to the model.

setupProjection(0, scope.xy, '1, '1)  // this stretches the texture to fit the scope

setupProjection Operation 

For an example, see the Texturing part in Tutorial 6:

Tutorial 6: Basic shape grammar—CityEngine Tutorials | ArcGIS Desktop 

0 Kudos