ladybug_vtk.display_polydata module¶
DisplayPolyData object to control the representation of a Polydata object.
- class ladybug_vtk.display_polydata.DisplayPolyData(name: str, identifier: str, *, polydata: List[PolyData] = None, color: Color = None, display_mode: DisplayMode = DisplayMode.Surface, hidden: bool = False)[source]¶
- Bases: - object- A collection of PolyData with display attributes. - All the PolyData must have data with the same names attached to them. - This object is similar to an AnalysisGeometry object in ladybug-display. - Parameters:
- name – A display name. 
- identifier – A unique identifier for this DisplayPolyData. This identifier should be unique among all the DisplayPolyData in a VisualizationSet. 
- polydata – A list of PolyData objects. 
- color – A Ladybug color to set the diffuse color for DisplayPolyData to use when there is no data available. 
- display_mode – Display model. It can be set to Surface, SurfaceWithEdges, Wireframe and Points. 
- hidden – A boolean to note whether the geometry is hidden by default and must be un-hidden to be visible in the 3D scene. Default is False. 
 
 - classmethod from_analysis_geometry(geometry: AnalysisGeometry) DisplayPolyData[source]¶
- Create DisplayPolyData from an AnalysisGeometry. 
 - classmethod from_context_geometry(geometry: ContextGeometry) DisplayPolyData[source]¶
- Create DisplayPolyData from a ContextGeometry. 
 - classmethod from_visualization_geometry(geometry: AnalysisGeometry | ContextGeometry) DisplayPolyData[source]¶
 - to_folder(folder, sub_folder=None) str[source]¶
- Write data information to a folder. - Parameters:
- folder – Target folder to write the dataset. 
- sub_folder – Subfolder name for this dataset. By default it will be set to the name of the dataset. 
 
 
 - property color: Color¶
- Diffuse color. - By default the dataset will be colored by this color unless color_by property is set to a dataset value. 
 - property color_by: str¶
- Get and set the field that the DataSet should colored-by when exported to vtkjs. - By default the dataset will be colored by surface color and not data. 
 - property display_mode: DisplayMode¶
- Display model (AKA Representation) mode in VTK Glance viewer. - Valid values are:
- Surface 
- SurfaceWithEdges 
- Wireframe 
- Points 
 
 - Default is 0 for Surface mode. 
 - property edge_visibility: bool¶
- Edge visibility. - The edges will be visible in Wireframe or SurfaceWithEdges modes. 
 - Visualization default state on load. - A boolean to note whether the geometry is hidden by default and must be un-hidden to be visible in the 3D scene. 
 - property is_empty¶
 - property opacity: float¶
- Get and set the visualization opacity.