code: def add_overlay(self, scalars, colormap, rng, opacity, name):
      overlay = _Overlay(
          scalars=scalars,
          colormap=colormap,
          rng=rng,
          opacity=opacity,
          name=name,
      )
      self._overlays[name] = overlay
      colors = overlay.to_colors()
      if self._current_colors is None:
          self._current_colors = colors
      else:
          # save previous colors to cache
          self._cached_colors = self._current_colors
          self._current_colors = self._compute_over(
              self._cached_colors, colors
          )
  
      # apply the texture
      self._apply()
  
file_path: mne-python/mne/viz/_3d_overlay.py
imports: from collections import OrderedDict
  import numpy
  from ..utils import logger
label_desc: Use image node_id 5 for calling the _LayeredMesh obj's underlying member method code with example usage: obj.add_overlay(scalars, colormap, rng, opacity, name) without return types