Sign in


You can rotate the 3D map with the mouse right button or with a multi touch two finger combination. But if You need to make Your own interface there is a little how to:

We will now create a slider to rotate the camera.
First, we must create a slider control in the body.

Then in the main function we add the following. This makes it so, that a function is called when we change the value of the slider.

And now we create the changeRotation function to be called. Wayfinder has a component called orbitController, which is the camera we use to look at the floor plan. We can manually set the rotation of the camera from code by accessing the orbitController’s rotation with wayfinder.orbitController.rotation.
This rotation has three components: pitch, yaw and roll.

We use the slider value as a multiplier between 0 and 2π and use it to set the yaw of the camera.

Full example code