rotateY method

Offset3D rotateY(
  1. double angle
)

Rotates this point around Y axis (horizontal camera rotation).

Implementation

Offset3D rotateY(double angle) {
  final c = cos(angle);
  final s = sin(angle);
  return Offset3D(x * c + z * s, y, -x * s + z * c);
}