io

load_polydata(file_name[, is_mni_obj]) Load a vtk polydata to a supported format file.
save_polydata(polydata, file_name[, binary, …]) Save a vtk polydata to a supported format file.
set_input(vtk_object, inp) Generic input function which takes into account VTK 5 or 6

load_polydata

fury.io.load_polydata(file_name, is_mni_obj=False)[source]

Load a vtk polydata to a supported format file.

Supported file formats are OBJ, VTK, FIB, PLY, STL and XML

Parameters:
file_name : string
is_mni_obj : bool
Returns:
output : vtkPolyData

save_polydata

fury.io.save_polydata(polydata, file_name, binary=False, color_array_name=None, is_mni_obj=False)[source]

Save a vtk polydata to a supported format file.

Save formats can be VTK, FIB, PLY, STL and XML.

Parameters:
polydata : vtkPolyData
file_name : string
binary : bool
color_array_name: ndarray
is_mni_obj : bool

set_input

fury.io.set_input(vtk_object, inp)[source]

Generic input function which takes into account VTK 5 or 6

Parameters:
vtk_object: vtk object
inp: vtkPolyData or vtkImageData or vtkAlgorithmOutput
Returns:
vtk_object

Notes

This can be used in the following way::
from fury.utils import set_input poly_mapper = set_input(vtk.vtkPolyDataMapper(), poly_data)