Namespaces
| Type | Name |
|---|---|
| namespace | Analysis |
| namespace | Common |
| namespace | Editors |
| namespace | Preferences |
| namespace | SystemData |
| namespace | Tools |
| namespace | Wizards |
Classes
| Type | Name |
|---|---|
| class | APINetCallback |
| interface | IOpticalSystem Represent a complete optical system. A IOpticalSystem corresponds to a single .ZMX file. See IZOSAPI_Application for information on how to get or create a IOpticalSystem. |
| interface | IPreferences |
| interface | ISTARMaterials Top-level access to material properties for STAR module. |
| interface | ISTARSubsystem Controls the STAR module at the optical system level. |
| interface | IZAPI_BaseObject |
| interface | IZOSAPI_Application This interface contains all information about the current ZOS-API connection, as well as methods for accessing an Optical System. This interface can only be retrieved from a connection interface - ZOSAPI.IZOSAPI_Connection for more information. |
| interface | IZOSAPI_Callback |
| interface | IZOSAPI_Connection This is the initial interface to Optic Studio. All applications that wish to use the ZOS-API must first establish a connection, using the T:ZOSAPI.ZOSAPI_Connection class. |
| interface | IZOSAPI_Events COM classes can inherit from this interface if they wish to receive status changed notifications. See also ZOSAPI_Connection.SystemStatusChangedEvent. |
| class | ZOSAPI_Connection |
Enumerations
| Type | Name |
|---|---|
| enum | SystemType { Sequential , NonSequential } |
| enum | LicenseStatusType { Unknown = 0 , KeyNotWorking , NewLicenseNeeded , StandardEdition , ProfessionalEdition , PremiumEdition , TooManyInstances , NotAuthorized , KeyNotFound , KeyExpired , Timeout , InstanceConflict , OpticsViewer , OpticStudioHPCEdition , EnterpriseEdition , StudentEdition } |
| enum | UpdateStatus { CheckFailed = -2 , NotSupported = -1 , NotChecked = 0 , UpToDate = 1 , AvailableEligible = 2 , AvailableIneligible = 3 } |
| enum | ZOSAPI_Mode { Server , Operand , Plugin , UserAnalysis , UserAnalysisSettings } |
| enum | LensUpdateMode { None = 0 , EditorsOnly = 1 , AllWindows = 2 } |
| enum | SessionModes { FromPreferences = 0 , SessionOn = 1 , SessionOff = 2 } |
| enum | STARUpdateMode { Normal , Suspended } |
Functions
| Type | Name |
|---|---|
| delegate void | OpticalSystemStatusChangedHandler (int systemId, string newStatus) |
Detailed Description
The ZOSAPI namespace contains classes for initially connecting to zemax. See also ZOSAPI_Connection, and IZOSAPI_Application for more information.Enumeration Type Documentation
LensUpdateMode
enum ZOSAPI.LensUpdateMode
LicenseStatusType
enum ZOSAPI.LicenseStatusType
// Save Ray Path Analysis to Text File
if (TheApplication.LicenseStatus == ZOSAPI.LicenseStatusType.PremiumEdition)
{
IA_ RayPath = TheSystem.Analyses.New_Analysis(AnalysisIDM.PathAnalysis);
ZOSAPI.Analysis.RayTracing.IAS_PathAnalysis RayPath_settings = RayPath.GetSettings() as ZOSAPI.Analysis.RayTracing.IAS_PathAnalysis;
RayPath_settings.RayDatabaseFile = "e10_API_RayTrace.ZRD";
RayPath.ApplyAndWaitForCompletion();
IAR_ Rays = RayPath.GetResults();
Rays.GetTextFile(TheApplication.SamplesDir + "\\API\\CS\\e10_RayPathAnalysis.txt");
}
else
{
Console.Write("\nThe RayPathAnalysis is a premium feature only\n\nPress any key to continue\n");
Console.ReadKey();
}
// Save Ray Path Analysis to Text File
if (TheApplication->LicenseStatus == ZOSAPI_Interfaces::LicenseStatusType::LicenseStatusType_PremiumEdition) {
IA_Ptr RayPath = TheSystem->Analyses->New_Analysis(AnalysisIDM_PathAnalysis);
ZOSAPI_Interfaces::IAS_PathAnalysisPtr RayPath_settings = RayPath->GetSettings();
RayPath_settings->RayDatabaseFile = "e10_API_RayTrace.ZRD";
RayPath->ApplyAndWaitForCompletion();
IAR_Ptr Rays = RayPath->GetResults();
Rays->GetTextFile(TheApplication->SamplesDir + "\\API\\CPP\\e10_RayPathAnalysis.txt");
}
% Save Ray Path Analysis to Text File
if TheApplication.LicenseStatus == ZOSAPI.LicenseStatusType.PremiumEdition
RayPath = TheSystem.Analyses.New_Analysis(ZOSAPI.Analysis.AnalysisIDM.PathAnalysis);
RayPath_settings = RayPath.GetSettings();
RayPath_settings.RayDatabaseFile = 'e10_API_Raytrace.ZRD';
RayPath.ApplyAndWaitForCompletion();
Rays = RayPath.GetResults();
Rays.GetTextFile(System.String.Concat(TheApplication.SamplesDir, '\API\Matlab\e10_RayPathAnalysis.txt'));
else
fprintf('\nThe RayPathAnalysis is a premium feature only\n');
end
# Save Ray Path Analysis to Text File
if (TheApplication.LicenseStatus == ZOSAPI.LicenseStatusType.PremiumEdition):
# there is a bug in ZOS16.5 SP4 with COM; need to use ZOS16.5 SP5 or higher to run this code successfully
RayPath = TheSystem.Analyses.New_Analysis(ZOSAPI.Analysis.AnalysisIDM.PathAnalysis)
RayPath_settings = RayPath.GetSettings()
zrd = "e10_API_RayTrace.ZRD"
RayPath_settings.RayDatabaseFile = zrd
RayPath.ApplyAndWaitForCompletion()
Rays = RayPath.GetResults()
Rays.GetTextFile(TheApplication.SamplesDir + "\\API\\Python\\e10_RayPathAnalysis.txt")
SessionModes
enum ZOSAPI.SessionModes
STARUpdateMode
enum ZOSAPI.STARUpdateMode
SystemType
enum ZOSAPI.SystemType
UpdateStatus
enum ZOSAPI.UpdateStatus
ZOSAPI_Mode
enum ZOSAPI.ZOSAPI_Mode
Function Documentation
OpticalSystemStatusChangedHandler()
delegate void ZOSAPI.OpticalSystemStatusChangedHandler(
int systemId,
string newStatus
)