class_docstr: Widget to facilitate plotting
  
  Parameters
  ----------
  *args : arguments
      Arguments passed to the `ViewBox` super class.
  **kwargs : keywoard arguments
      Keyword arguments passed to the `ViewBox` super class.
  
  Notes
  -----
  This class is typically instantiated implicitly by a `Figure`
  instance, e.g., by doing ``fig[0, 0]``.
class_docstr_tok: ["Widget","to","facilitate","plotting","Parameters","--","--","--","--","--","*","args",":","arguments","Arguments","passed","to","the","`","ViewBox","`","super","class",".","*","*","kwargs",":","keywoard","arguments","Keyword","arguments","passed","to","the","`","ViewBox","`","super","class",".","Notes","--","--","-","This","class","is","typically","instantiated","implicitly","by","a","`","Figure","`","instance",",","e.g.",",","by","doing","``","fig","[","0",",","0","]","``","."]
docstr: Show a 3D mesh
  
  Parameters
  ----------
  vertices : array
      Vertices.
  faces : array | None
      Face definitions.
  vertex_colors : array | None
      Vertex colors.
  face_colors : array | None
      Face colors.
  color : instance of Color
      Color to use.
  fname : str | None
      Filename to load. If not None, then vertices, faces, and meshdata
      must be None.
  meshdata : MeshData | None
      Meshdata to use. If not None, then vertices, faces, and fname
      must be None.
  shading : str
      Shading to use, can be None, 'smooth', 'flat', or 'auto'.
      Default ('auto') will use None if face_colors is set, and
      'smooth' otherwise.
  
  Returns
  -------
  mesh : instance of Mesh
      The mesh.
docstr_tok: ["Show","a","3D","mesh","Parameters","--","--","--","--","--","vertices",":","array","Vertices",".","faces",":","array","|","None","Face","definitions",".","vertex_colors",":","array","|","None","Vertex","colors",".","face_colors",":","array","|","None","Face","colors",".","color",":","instance","of","Color","Color","to","use",".","fname",":","str","|","None","Filename","to","load",".","If","not","None",",","then","vertices",",","faces",",","and","meshdata","must","be","None",".","meshdata",":","MeshData","|","None","Meshdata","to","use",".","If","not","None",",","then","vertices",",","faces",",","and","fname","must","be","None",".","shading",":","str","Shading","to","use",",","can","be","None",",","'smooth","'",",","'flat","'",",","or","'auto","'",".","Default","(","'auto","'",")","will","use","None","if","face_colors","is","set",",","and","'smooth","'","otherwise",".","Returns","--","--","--","-","mesh",":","instance","of","Mesh","The","mesh","."]
code: def mesh(
      self,
      vertices=None,
      faces=None,
      vertex_colors=None,
      face_colors=None,
      color=(0.5, 0.5, 1.0),
      fname=None,
      meshdata=None,
      shading="auto",
  ):
      """Show a 3D mesh
  
      Parameters
      ----------
      vertices : array
          Vertices.
      faces : array | None
          Face definitions.
      vertex_colors : array | None
          Vertex colors.
      face_colors : array | None
          Face colors.
      color : instance of Color
          Color to use.
      fname : str | None
          Filename to load. If not None, then vertices, faces, and meshdata
          must be None.
      meshdata : MeshData | None
          Meshdata to use. If not None, then vertices, faces, and fname
          must be None.
      shading : str
          Shading to use, can be None, 'smooth', 'flat', or 'auto'.
          Default ('auto') will use None if face_colors is set, and
          'smooth' otherwise.
  
      Returns
      -------
      mesh : instance of Mesh
          The mesh.
      """
      self._configure_3d()
      if shading == "auto":
          shading = "smooth"
          if face_colors is not None:
              shading = None
      if fname is not None:
          if not all(x is None for x in (vertices, faces, meshdata)):
              raise ValueError(
                  "vertices, faces, and meshdata must be None "
                  "if fname is not None"
              )
          vertices, faces = read_mesh(fname)[:2]
      if meshdata is not None:
          if not all(x is None for x in (vertices, faces, fname)):
              raise ValueError(
                  "vertices, faces, and fname must be None if "
                  "meshdata is not None"
              )
      else:
          meshdata = MeshData(
              vertices,
              faces,
              vertex_colors=vertex_colors,
              face_colors=face_colors,
          )
      mesh = scene.Mesh(
          meshdata=meshdata,
          vertex_colors=vertex_colors,
          face_colors=face_colors,
          color=color,
          shading=shading,
      )
      self.view.add(mesh)
      self.view.camera.set_range()
      return mesh
  
file_path: vispy/vispy/plot/plotwidget.py
imports: from ..None import scene
  from ..io import read_mesh
  from ..geometry import MeshData
label_desc: Use image node_id 6 for calling the PlotWidget obj's underlying member method code with example usage: obj.mesh(vertices, faces, vertex_colors, face_colors, color, fname, meshdata, shading) and returns: mesh