There are two buttons in my page for switching to ArcRotate camera and to Universal camera. When I click the button for Universal camera, it immediately switches to the same. But it always takes too many clicks on the ArcRotate camera button in order to switch to it. Why is it so?
var cameraType = {
FREE: 0,
ARCROTATE: 1,
WALKTHROUGH: 2,
UNIVERSAL: 3
};
var cameraMode = {
PERSPECTIVE: 0,
ORTHOGRAPHIC: 1
};
this.setCameraAsArcRotate = function () {
_cameraType = cameraType.ARCROTATE;
};
this.setCameraAsUniversal = function () {
_cameraType = cameraType.UNIVERSAL;
};