# R: Re: \[cesium-dev\] ol3\_cesium my polygon float

**URL:** <https://community.cesium.com/t/r-re-cesium-dev-ol3-cesium-my-polygon-float/4191>\
**Category:** CesiumJS\
**Created:** [June 3, 2016, 1:48pm UTC](https://community.cesium.com/t/r-re-cesium-dev-ol3-cesium-my-polygon-float/4191 "2016-06-03T13:48:54Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![PAOLO\_GALLO](https://avatars.discourse-cdn.com/v4/letter/p/3ec8ea/32.png) [@PAOLO\_GALLO](https://community.cesium.com/u/PAOLO_GALLO)\
**Post date:** [June 3, 2016, 1:48pm UTC](https://community.cesium.com/t/r-re-cesium-dev-ol3-cesium-my-polygon-float/4191/1 "2016-06-03T13:48:54Z")

</div>

Thank you  
for your replay

I tried this  
code but I obtain:

Uncaught  
TypeError: Cannot read property ‘getGeometry’ of undefined

Thank you  
again.

var ghiacciai = new ol.layer.Vector({ //aggiungo i ghiacciai

title: ‘Ghiacciai’,

visible:  
true,

source:  
new ol.source.Vector({

url:  
‘data/ghiacciai.json’,

projection:  
‘EPSG:3857’,

format:  
new ol.format.GeoJSON()

```
                                                                                                                                                                        })
```

---

<div class="post-metadata">

**Author:** ![Guillaume\_Beraudo](https://sea2.discourse-cdn.com/cesium/user_avatar/community.cesium.com/guillaume_beraudo/32/2985_2.png) [@Guillaume\_Beraudo](https://community.cesium.com/u/Guillaume_Beraudo)\
**Post date:** [June 3, 2016, 2:12pm UTC](https://community.cesium.com/t/r-re-cesium-dev-ol3-cesium-my-polygon-float/4191/2 "2016-06-03T14:12:24Z")

</div>

Paolo,

On a layer it is simply “ghiacciai.set(‘altitudeMode’,  
‘clampToGround’);”.

Now a question:

I am surprised you include both ol.js and ol3cesium.js. Which version of OL3-Cesium are you using?

Guillaume
