CesiumGS / CesiumGS/cesium

Control available scene modes in SceneModePicker

Open
#8,005 9 comments 1 reaction 0 assignees View on GitHub
category - widgets good first issue type - enhancement
Dominant language
JavaScript
Stars
15.7k
Forks
3.9k
Avg merge
4d 6h
Merged PRs (30d)
34

Description

The [BaseLayerPicker](https://cesiumjs.org/Cesium/Build/Documentation/BaseLayerPicker.html?classFilter=BaseLay) allows you to pass an array of which imagery layers should be available. It would be nice if the [SceneModePicker](https://cesiumjs.org/Cesium/Build/Documentation/SceneModePicker.html) had a similar option.

This was [requested on the forum](https://groups.google.com/d/msg/cesium-dev/2eUX-TdtzHM/82m3_m1LAwAJ). Currently it's hardcoded to show all 3. I think it should be easy to add an option to control this. I think you'd need to edit https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/Widgets/SceneModePicker/SceneModePicker.js and https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/Widgets/SceneModePicker/SceneModePickerViewModel.js.

Contributor guide

Open the contributing guide

Research direction

Start by reading Source/Widgets/SceneModePicker/SceneModePicker.js and Source/Widgets/SceneModePicker/SceneModePickerViewModel.js, where the three scene modes are currently exposed. Trace how BaseLayerPicker accepts its available options and determine how a similar option should control SceneModePicker. Done means callers can restrict the available scene modes instead of always seeing all three.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
frontend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.