Adding a new cell type

VTK supports many cell types that can be used in unstructured meshes or as cells in a new mesh type. Sometimes, the cell types provided by VTK may not suffice for representing cells using a highly tailored data model. In some instances, it has been necessary to extend VTK so it contains new mesh types, which in turn often use specialized cell types. This page covers how to write a new cell type to extend the VTK data model.

Currently supported cells

The cells that are guaranteed to be supported are:


Many algorithms support the following cell types:


Of course, many algorithms have support for the general vtkCell interface as well.

Adding support for a new cell type

If you can't use any of the cell types above, you've got two major steps:

  1. Choose which derived type of vtkCell to use. This may involve using an existing derived type of vtkCell or writing your own (which this page does not discuss).
  2. Making sure all of VisIt's algorithms support the vtkCell you want to add support for.

Probably, you should inspect every operator and plot. But that's a lot of work. If you inspect the following, you will have run into the majority of the problems (hopefully!):

  • Volume rendering (you will have to add a new derived type of avtExtractor to the avtSamplePointExtractor module)
  • Contouring
  • Slicing
  • Transform
  • Pick
  • Threshold
  • Recentering the variable (as in the expression)
  • Facelists (Pseudocolor with no operator)
  • Mesh
  • Mesh quality expressions
  • Clip
  • Query->Volume / Query->Weighted Variable Sum.

After you finish this process, add the newly supported type of vtkCell to the list of supported cell types at the top of this page.