# Texture extruded polygons

**URL:** <https://community.cesium.com/t/texture-extruded-polygons/2195>\
**Category:** CesiumJS\
**Created:** [March 19, 2015, 1:10pm UTC](https://community.cesium.com/t/texture-extruded-polygons/2195 "2015-03-19T13:10:39Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![vishal\_tiwari](https://avatars.discourse-cdn.com/v4/letter/v/ba8739/32.png) [@vishal\_tiwari](https://community.cesium.com/u/vishal_tiwari)\
**Post date:** [March 19, 2015, 1:10pm UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/1 "2015-03-19T13:10:39Z")

</div>

Hi,

I am trying to texture the extruded polygons(in my case buildings) with texture. I have the texture data for each of the faces of an extruded polygon.

Now, I know if I make the buildings by extruding every adjacent pair of coordinates to a specified height, I would have the building walls as polygons which I can drape with texture. But I would like to know If there is a way that can directly texture the extruded polygons?

Thanks,

---

<div class="post-metadata">

**Author:** ![Matt\_Amato](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/matt_amato/32/1993_2.png) [@Matt\_Amato](https://community.cesium.com/u/Matt_Amato)\
**Post date:** [March 20, 2015, 2:46pm UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/2 "2015-03-20T14:46:06Z")

</div>

The default geometries don’t currently support draping textures along the sides. You would need to use the lower-level Geometry and Appearances to do this, which would include defining a custom geometry with custom texture coordinates. Another option would be to create glTF files from your data and load them instead.

---

<div class="post-metadata">

**Author:** ![vishal\_tiwari](https://avatars.discourse-cdn.com/v4/letter/v/ba8739/32.png) [@vishal\_tiwari](https://community.cesium.com/u/vishal_tiwari)\
**Post date:** [March 21, 2015, 7:12am UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/3 "2015-03-21T07:12:17Z")

</div>

Thanks for the reply Matthew, I had a look at the tutorial, I will try it out and post it here if I face any issues. 🙂

Thanks,

---

<div class="post-metadata">

**Author:** ![Alexander\_Fedorenko](https://avatars.discourse-cdn.com/v4/letter/a/e480ec/32.png) [@Alexander\_Fedorenko](https://community.cesium.com/u/Alexander_Fedorenko)\
**Post date:** [March 26, 2015, 9:48am UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/4 "2015-03-26T09:48:08Z")

</div>

Do you have any result with textured polygon?

---

<div class="post-metadata">

**Author:** ![vishal\_tiwari](https://avatars.discourse-cdn.com/v4/letter/v/ba8739/32.png) [@vishal\_tiwari](https://community.cesium.com/u/vishal_tiwari)\
**Post date:** [March 26, 2015, 11:52am UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/5 "2015-03-26T11:52:25Z")

</div>

Hi Fizrukbet,

I was able to texture the polygons using the lower-level Geometry and Appearances as suggested by Matthew. You can have a look at the draped walls (see attachment), as of now, I have draped everything with a single texture.

PS: I know the buildings don’t have a roof. 😛

Thanks,

 ![Screenshot from 2015-03-26 17:13:21.png](https://global.discourse-cdn.com/cesium/original/2X/a/a3f7ec215bfca9da46f764b778a38cecb0a73c81.png)

---

<div class="post-metadata">

**Author:** ![Alexander\_Fedorenko](https://avatars.discourse-cdn.com/v4/letter/a/e480ec/32.png) [@Alexander\_Fedorenko](https://community.cesium.com/u/Alexander_Fedorenko)\
**Post date:** [May 28, 2015, 12:13pm UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/6 "2015-05-28T12:13:04Z")

</div>

citygml fme  
[http://www.slideshare.net/SafeSoftware/how-to-easily-read-and-write-citygml-data-using-fme?next\_slideshow=1](http://www.slideshare.net/SafeSoftware/how-to-easily-read-and-write-citygml-data-using-fme?next_slideshow=1)

---

<div class="post-metadata">

**Author:** ![sgoran87](https://avatars.discourse-cdn.com/v4/letter/s/858c86/32.png) [@sgoran87](https://community.cesium.com/u/sgoran87)\
**Post date:** [July 13, 2016, 12:08pm UTC](https://community.cesium.com/t/texture-extruded-polygons/2195/7 "2016-07-13T12:08:57Z")

</div>

Hi Matthew, any advice or resource on how to create glTF from polygons (have the data in PostGis), if we have height info too?  
I am a big of a beginner with cesium..

Thx
