function getAltitude(frustum, dx, dy) {
  let near;
  let top;
  let right;
  if (frustum instanceof PerspectiveFrustum) {
    const tanTheta = Math.tan(0.5 * frustum.fovy);
    near = frustum.near;
    top = frustum.near * tanTheta;
    right = frustum.aspectRatio * top;
    return Math.max((dx * near) / right, (dy * near) / top);
  } else if (frustum instanceof PerspectiveOffCenterFrustum) {
    near = frustum.near;
    top = frustum.top;
    right = frustum.right;
    return Math.max((dx * near) / right, (dy * near) / top);
  }

  return Math.max(dx, dy);
}
Creates tweens for camera flights.
<br /><br />
Mouse interaction is disabled during flights.

@private