How can I change the property of viewer after I have defined viewer?

29 views
Skip to first unread message

秦骏

unread,
Dec 18, 2017, 8:31:53 PM12/18/17
to cesium-dev

var  viewer = new Cesium.Viewer('cesiumContainer', {
    selectionIndicator : false,
    infoBox : false
});
After I have defined viewer,I want to change selectionIndicator and infobox to false.How can i?

Gabby Getz

unread,
Dec 20, 2017, 11:04:22 AM12/20/17
to cesium-dev
Hi there,

Some options, like selectionIndicator, are only available when constructing the Viewer.

You can hide it after construction, but you need to do it a little differently by setting properties of the widget view model.

viewer.selectionIndicator.viewModel.isVisible = false;

Thanks,
Gabby
Reply all
Reply to author
Forward
0 new messages