make_model#

vivid3d.make_model(*args, **kwargs)#

Overloaded function.

  1. make_model(input_points: Point3DList, masks: List[List[bool]], output_path: str = ‘’, color_field: List[float] = [], color_field_min: float = 0, color_field_max: float = 0, label: str = ‘VIVID_MODEL’, opacity: List[float] = [], file_type: str = ‘glb’, noise_displacement: float = 0.001) -> vivid3d._core.Model

makes a model from one line, using a vector of masks, each mask will result in a surface, see voronoi user guide for further detail. if an output path is given the functions writes the model to file.

Parameters
  • input_points (array[array[float]]) – The input point data in x,y,z form.

  • mask (array[array[bool]]) – array of masks, Each inner array is a Boolean mask of true and false points, has to be the same size as input_points.

  • output_path (str, optional) – Path and name for output file If given the model will be written to file, otherwise not.

  • color_field (array[float], default: []) – Vector containing the color field of each point If left empty color will be basic white

  • color_field_min (float, optional) – Set minimum value for color_field, anything below will be set to color_field_min If left empty will be set to min(color_field)

  • color_field_max (float, optional) – Set max value for color_field, anything below will be set to color_field_max If left empty will be set to max(color_field)

  • label (str, default: "VIVID_MODEL") – Optional name of the object, not required to be unique.

  • opacity (array[float], default: []) – Array of Floats in the range of 0.0 - 1.0 indicating how transparent the material is. A value of 0.0 indicates fully transparent, 1.0 is fully opaque.

  • file_type (str, default: "glb") – File format for export, out of Assimp supported formats

  • noise_displacement (float, default: 0.001) – The Voronoi algorithm struggles with equidistant point data, a small noise displacement improves algorithm speed

Returns

vivid3d.Model – Output model.

  1. make_model(input_points: Point3DList, surface_field: List[float], surface_thresholds: List[float], output_path: str = ‘’, color_field: List[float] = [], color_field_min: float = 0, color_field_max: float = 0, label: str = ‘VIVID_MODEL’, opacity: List[float] = [], file_type: str = ‘glb’, noise_displacement: float = 0.001) -> vivid3d._core.Model

makes a model from one line, using surface field and a vector of thresholds, each threshold resulting in a surface. if an output path is given the functions writes the model to file.

Parameters
  • input_points (array[array[float]]) – The input point data in x,y,z form.

  • surface_field (array[float]) – surface field value for each point, has to be same size as input_points.

  • surface_thresholds (array[float]) – thresholds to create surfaces.

  • output_path (str, optional) – Path and name for output file If given the model will be written to file, otherwise not.

  • color_field (array[float], default: []) – Vector containing the color field of each point If left empty color will be basic white

  • color_field_min (float, optional) – Set minimum value for color_field, anything below will be set to color_field_min If left empty will be set to min(color_field)

  • color_field_max (float, optional) – Set max value for color_field, anything below will be set to color_field_max If left empty will be set to max(color_field)

  • label (str, default: "VIVID_MODEL") – Optional name of the object, not required to be unique.

  • opacity (array[float], default: []) – Array of Floats in the range of 0.0 - 1.0 indicating how transparent the material is. A value of 0.0 indicates fully transparent, 1.0 is fully opaque.

  • file_type (str, default: "glb") – File format for export, out of Assimp supported formats

  • noise_displacement (float, default: 0.001) – The Voronoi algorithm struggles with equidistant point data, a small noise displacement improves algorithm speed

Returns

vivid3d.Model – Output model.

User Guide