3D Visualization (VTK)
Advanced 3D visualization functions powered by VTK.js for volumetric data, FEM meshes, and scientific visualization.
vtk.polydata
Create PolyData geometry
vtk.polydata(points, polys)
vtk.volume
Create volumetric visualization
vtk.volume(data, dims)
vtk.isosurface
Extract and render isosurface
vtk.isosurface(data, dims, isovalue)
vtk.femgrid
Visualize FEM unstructured grid
vtk.femgrid(nodes, elements, elementTypes)
vtk.sphere
Create sphere geometry
vtk.sphere()
vtk.cone
Create cone geometry
vtk.cone()
vtk.cube
Create cube/box geometry
vtk.cube()
vtk.cylinder
Create cylinder geometry
vtk.cylinder()
vtk.colormap
Set VTK colormap
vtk.colormap('name')
vtk.opacity
Set VTK opacity
vtk.opacity(value)
vtk.edges
Toggle edge visibility
vtk.edges('on')
vtk.wireframe
Set wireframe rendering
vtk.wireframe()
vtk.surface
Set surface rendering
vtk.surface()
vtk.points
Set point rendering
vtk.points()
vtk.mesh
Visualize an MFEM mesh
vtk.mesh(mesh)
vtk.meshCoordinates
Get mesh vertex coordinates
coords = vtk.meshCoordinates(mesh)
vtk.gridfunction
Visualize MFEM GridFunction with scalar coloring
vtk.gridfunction(mesh, gf)
vtk.displacement
Visualize displacement field on deformed mesh
vtk.displacement(mesh, u)