Skip to main content
Solved

Access coating properties in ZOS-API?

  • January 20, 2023
  • 2 replies
  • 123 views

joshdfreeman
Ultraviolet
Forum|alt.badge.img

Is there a way to access the properties of a coating in the ZOS-API? 

The article below shows how to access the name of the coating, but does not show how to get the properties of the coating.

I’m not finding any handles that give the actual coating information. 

Thanks!

Best answer by David.Nguyen

Hi Josh,

 

I don’t think you’ll find those handles in the CoatScatterData property. I’m not sure if they are elsewhere either. That being said CoatScatterData will give you the name of the coating as you mentioned. Also, you can retrieve which coating file is used in your lens from the ZOS-API:

TheSystem.SystemData.Files.CoatingFile

By default, it is a text file called COATING.DAT located in your {Documents}\Zemax\Coatings folder. And the syntax is described in the Help File under: The Libraries Tab > Coatings Group > Defining Coatings > Coating File Data Syntax. Therefore, you can use MATLAB to open this text file and search for the relevant information. Does that make sense? I don’t have MATLAB but I’m sure this should be possible.

Take care,

 

David

View original
Did this topic help you find an answer to your question?

2 replies

David.Nguyen
Luminary
Forum|alt.badge.img+2
  • Luminary
  • 1085 replies
  • Answer
  • January 20, 2023

Hi Josh,

 

I don’t think you’ll find those handles in the CoatScatterData property. I’m not sure if they are elsewhere either. That being said CoatScatterData will give you the name of the coating as you mentioned. Also, you can retrieve which coating file is used in your lens from the ZOS-API:

TheSystem.SystemData.Files.CoatingFile

By default, it is a text file called COATING.DAT located in your {Documents}\Zemax\Coatings folder. And the syntax is described in the Help File under: The Libraries Tab > Coatings Group > Defining Coatings > Coating File Data Syntax. Therefore, you can use MATLAB to open this text file and search for the relevant information. Does that make sense? I don’t have MATLAB but I’m sure this should be possible.

Take care,

 

David


Forum|alt.badge.img+2

Hi Josh

I am actually working on a coating converter between Zemax and Speos, and indeed there is not much you can read about our coatings in the API. So it is mainly the names and the layers.
As David mentioned, you could read the text file if needed.
Let us know if we can help.


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings