code: def create_3d_figure(
      size,
      bgcolor=(0, 0, 0),
      smooth_shading=None,
      handle=None,
      *,
      scene=True,
      show=False,
  ):
      """Return an empty figure based on the current 3d backend.
  
      .. warning:: Proceed with caution when the renderer object is
                   returned (with ``scene=False``) because the _Renderer
                   API is not necessarily stable enough for production,
                   it's still actively in development.
  
      Parameters
      ----------
      size : tuple
          The dimensions of the 3d figure (width, height).
      bgcolor : tuple
          The color of the background.
      smooth_shading : bool | None
          Whether to enable smooth shading. If ``None``, uses the config value
          ``MNE_3D_OPTION_SMOOTH_SHADING``. Defaults to ``None``.
      handle : int | None
          The figure identifier.
      scene : bool
          If True (default), the returned object is the Figure3D. If False,
          an advanced, undocumented Renderer object is returned (the API is not
          stable or documented, so this is not recommended).
      show : bool
          If True, show the renderer immediately.
  
          .. versionadded:: 1.0
  
      Returns
      -------
      figure : instance of Figure3D or ``Renderer``
          The requested empty figure or renderer, depending on ``scene``.
      """
      _validate_type(smooth_shading, (bool, None), "smooth_shading")
      if smooth_shading is None:
          smooth_shading = _get_3d_option("smooth_shading")
      renderer = _get_renderer(
          fig=handle,
          size=size,
          bgcolor=bgcolor,
          smooth_shading=smooth_shading,
          show=show,
      )
      if scene:
          return renderer.scene()
      else:
          return renderer
  
imports: import importlib
  import time
  from contextlib import contextmanager
  from functools import partial
  import numpy
  from ...utils import _auto_weakref, _check_option, _validate_type, fill_doc, get_config, logger, verbose
  from .._3d import _get_3d_option
  from ..utils import safe_event
  from ._utils import VALID_3D_BACKENDS
label_desc: Use image node_id 13 for calling a global function with example usage: create_3d_figure(size, bgcolor, smooth_shading, handle) and returns: renderer, renderer