ZOSAPI.Analysis Namespace Reference
Last update: 17.07.2025Namespaces | |
| namespace | Data |
| namespace | PhysicalOptics |
| namespace | RayTracing |
| namespace | Settings |
| namespace | Tolerancing |
Classes | |
| interface | I_Analyses |
| Methods and interfaces for opening, closing, and retrieving analyses. This interface can be accessed via the IOpticalSystem interface. More... | |
| interface | IA_ |
| Base interface for all analysis windows. This interface can be accessed via the I_Analyses interface. More... | |
| interface | IColorTranslator |
| interface | IMessage |
| interface | IMessages |
| interface | IUser2DLineData |
| Properties and methods for configuring a 2D line User Analysis plot. This interface can be accessed via the IUserAnalysisData interface. More... | |
| interface | IUserAnalysisData |
| Properties and methods used to generate a User Analysis. This interface can be accessed via the IZOSAPI_Application interface. Note that this interface is only available when creating a User Analysis plugin application. More... | |
| interface | IUserGridData |
| Properties and methods for configuring a 2D grid User Analysis plot. This interface can be accessed via the IUserAnalysisData interface. More... | |
| interface | IUserGridRGBData |
| Properties and methods for configuring a 2D rgb grid User Analysis plot. This interface can be accessed via the IUserAnalysisData interface. More... | |
| interface | IUserTextData |
| Properties and methods for configuring a text User Analysis window. This interface can be accessed via the IUserAnalysisData interface. More... | |
Enumeration Type Documentation
◆ AnalysisIDM
All available analysis types. See the I_Analyses interface for more information.
◆ Beam
| enum ZOSAPI.Analysis.Beam |
◆ BestFitSphereOptions
◆ ColorPaletteType
◆ DetectorViewerShowAsTypes
Usage (see Example 10 for a full sample)
C#
// Open Detector Viewer, view previously saved .zrd file
IA_ DetectorView = TheSystem.Analyses.New_DetectorViewer();
IAS_DetectorViewer DetectorView_Settings = DetectorView.GetSettings() as IAS_DetectorViewer;
DetectorView_Settings.RayDatabaseFilename = "e10_API_RayTrace.ZRD";
DetectorView_Settings.ShowAs = DetectorViewerShowAsTypes.FalseColor;
DetectorView_Settings.Filter = "X_HIT(2, 4)"; // Detector will only display rays which hit object 2 exactly 4 times
DetectorView.ApplyAndWaitForCompletion(); // Apply Settings to Detector Viewer
Base interface for all analysis windows. This interface can be accessed via the I_Analyses interface.
Definition: IA_Base.cs:29
IMessage ApplyAndWaitForCompletion()
Re-runs the analysis with the current settings and waits for it to finish calculating.
C++
// Open Detector Viewer, view previously saved .zrd file
IA_Ptr DetectorView = TheSystem->Analyses->New_DetectorViewer();
IAS_DetectorViewerPtr DetectorView_Settings = DetectorView->GetSettings();
DetectorView_Settings->RayDatabaseFilename = "e10_API_Raytrace.ZRD";
DetectorView_Settings->ShowAs = DetectorViewerShowAsTypes_FalseColor;
// Detector will only display rays which hit object 2 exactly 4 times
DetectorView_Settings->Filter = "X_HIT(2, 4)";
// Apply Settings to Detector Viewer
DetectorView->ApplyAndWaitForCompletion();
Matlab
% Open Detector Viewer, view previously saved .zrd file
DetectorView = TheSystem.Analyses.New_DetectorViewer();
DetectorView_Settings = DetectorView.GetSettings();
DetectorView_Settings.RayDatabaseFilename = 'e10_API_Raytrace.ZRD';
DetectorView_Settings.Filter = 'X_HIT(2, 4)'; % Detector will only display rays which hit object 2 exactly 4 times
DetectorView.ApplyAndWaitForCompletion(); % Apply Settings to Detector Viewer
Definition: IAS_FieldCurvatureAndDistortion.cs:5
The ZOSAPI namespace contains classes for initially connecting to zemax. See also ZOSAPI_Connection,...
Definition: IAS_FieldCurvatureAndDistortion.cs:5
Python
# Open Detector Viewer, view previously saved .zrd file
DetectorView = TheSystem.Analyses.New_DetectorViewer()
DetectorView_Settings = DetectorView.GetSettings()
DetectorView_Settings.RayDatabaseFilename = "e10_API_Raytrace.ZRD"
DetectorView_Settings.ShowAs = ZOSAPI.Analysis.DetectorViewerShowAsTypes.FalseColor
DetectorView_Settings.Filter = "X_HIT(2, 4)" # Detector will only display rays which hit object 2 exactly 4 times
DetectorView.ApplyAndWaitForCompletion() # Apply Settings to Detector Viewer