class_docstr: Base class for 3D cameras supporting orthographic and
  perspective projections.
  
  Parameters
  ----------
  fov : float
      Field of view. Default 60.0.
  scale_factor : scalar
      A measure for the scale/range of the scene that the camera
      should show. The exact meaning differs per camera type.
  **kwargs : dict
      Keyword arguments to pass to `BaseCamera`.
docstr: Reset the camera view using the known limits.
docstr_tok: ["Reset","the","camera","view","using","the","known","limits","."]
code: def _set_range(self, init):
      """Reset the camera view using the known limits."""
      if init and (self._scale_factor is not None):
          return  # We don't have to set our scale factor
  
      # Get window size (and store factor now to sync with resizing)
      w, h = self._viewbox.size
      w, h = float(w), float(h)
  
      if (w == 0) or (h == 0):
          return
  
      # Get range and translation for x and y
      x1, y1, z1 = self._xlim[0], self._ylim[0], self._zlim[0]
      x2, y2, z2 = self._xlim[1], self._ylim[1], self._zlim[1]
      rx, ry, rz = (x2 - x1), (y2 - y1), (z2 - z1)
  
      # Correct ranges for window size. Note that the window width
      # influences the x and y data range, while the height influences
      # the z data range.
      if w / h > 1:
          rx /= w / h
          ry /= w / h
      else:
          rz /= h / w
  
      # Convert to screen coordinates. In screen x, only x and y have effect.
      # In screen y, all three dimensions have effect. The idea of the lines
      # below is to calculate the range on screen when that will fit the
      # data under any rotation.
      rxs = (rx**2 + ry**2) ** 0.5
      rys = (rx**2 + ry**2 + rz**2) ** 0.5
  
      self.scale_factor = max(rxs, rys) * 1.04
  
imports: from __future__ import division
  import math
  import numpy
  from .base_camera import BaseCamera
  from ...util import keys, transforms
  from ...visuals.transforms import MatrixTransform
label_desc: Use image node_id 6 for calling the PerspectiveCamera obj's underlying member method code with example usage: obj._set_range(init) without return types