vtk_openCARP_methods_ibt.openCARP package

Submodules

vtk_openCARP_methods_ibt.openCARP.exporting module

format_vector_to_str(v, precision)[source]
write_mesh(filename, pts, mesh, elem_tags, fiber_long=None, fiber_sheet=None)[source]
write_mesh_from_vtk_obj(filename, mesh, tag_name='elemTag', fiber_name='fiber', sheet_name='sheet')[source]
write_to_elem(filename, mesh, tag)[source]
Parameters:
  • filename – Filename with .elem extension

  • mesh – Mesh which should be stored as element file.

  • tag – Tags which are attached to the mesh

Returns:

write_to_lon(filename_lon, elem, sheet=None, precession=4)[source]
write_to_pts(filename_pts, pts)[source]

vtk_openCARP_methods_ibt.openCARP.importing module

convert_openCARP_to_vtk(pts_file_path, elem_file_path, lon_file_path='', poly_data=True)[source]

Convert a .pts and .elem file to a .vtk file. :type pts_file_path: :param pts_file_path: Filepath of the .pts file with .pts extension :type elem_file_path: :param elem_file_path: Filepath of the .elem file with .elem extension :type lon_file_path: :param lon_file_path: Filepath of the .lon file with .lon extension. Optional. :return: vtk polydata object

convert_openCARP_to_vtk_single_name(file_name)[source]
load_elem(elem_file_path)[source]
load_lon(lon_file_path)[source]
load_pts(pts_file)[source]

Loads a .pts file and converts it to an vtkPoints array The file is expected to start with the number of points, then lists the point coordinates. :type pts_file: :param pts_file: the .pts file name with extension .pts :return: vtkPoints array

parse_args()[source]

Module contents