visualization.system.surface
Surface Visualization Module
This module contains classes for visualizing optical surfaces in 2D and 3D.
Kramer Harrison, 2024
Classes
|
A class used to represent a 2D surface for visualization. |
|
A class used to represent a 3D surface for visualization. |
- class Surface2D(surface, ray_extent)[source]
A class used to represent a 2D surface for visualization.
- Parameters:
surf (Surface) – The surface object containing the geometry.
extent (tuple) – The extent of the surface in the x and y directions.
- ray_extent
The extent of rays on the surface.
- Type:
tuple
- plot(ax, theme=None, projection='YZ')[source]
Plots the surface on the given matplotlib axis.
- Parameters:
ax (matplotlib.axes.Axes) – The matplotlib axis on which the surface will be plotted.
theme (Theme, optional) – The theme to use for plotting. Defaults to None.
projection (str, optional) – The projection plane. Must be ‘XY’, ‘XZ’, or ‘YZ’. Defaults to ‘YZ’.
- class Surface3D(surface, extent)[source]
A class used to represent a 3D surface for visualization.
- Parameters:
surf (Surface) – The surface object containing the geometry.
extent (tuple) – The extent of the surface in the x and y directions.
- extent
The extent of the surface in the x and y directions.
- Type:
tuple
- get_surface(theme=None)[source]
Retrieves the surface actor based on the symmetry of the surface geometry.
If the surface geometry is symmetric, it retrieves a symmetric surface actor. Otherwise, it retrieves an asymmetric surface actor.
- Returns:
- The surface actor, either symmetric or asymmetric, based on
the surface geometry.
- Return type:
actor