Rotation of a cube with a slider