Skip to main content
Solved

ZPL language question

  • May 31, 2021
  • 1 reply
  • 405 views

Hi


This Shayne from Clouldight, Vincent's colleague.


I would like to know how to use operand of ZPL 'SPRO' . Is it same as SETSURFACEPROPERTY, SURP?


Thanks!


Sincerely,


Shayne

Best answer by Csilla Timar-Fulep

Hello,


Thanks for your question here on the MyZemax forums!


SPRO() is a numeric macro function, so it will return the surface properties, but it will not make any changes.

In order to pull the surface property you are interested in, you will need to input the surface number and the code for the specific surface property:


The codes for the surface properties are same as for the SETSURFACEPROPERTY keyword.

The difference is that SETSURFACEPROPERTY is a keyword, which means it will not only report the value, but it will make changes to the system.


You may read more about the differences of functions and keywords in this kowledgebase article:

Introduction to Zemax Programming Language (ZPL) · MyZemax


I hope this helps, but if you have any further questions, please do not hesitate to ask!


Best,

Csilla

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

1 reply

Csilla Timar-Fulep
Zemax Staff
Forum|alt.badge.img+2

Hello,


Thanks for your question here on the MyZemax forums!


SPRO() is a numeric macro function, so it will return the surface properties, but it will not make any changes.

In order to pull the surface property you are interested in, you will need to input the surface number and the code for the specific surface property:


The codes for the surface properties are same as for the SETSURFACEPROPERTY keyword.

The difference is that SETSURFACEPROPERTY is a keyword, which means it will not only report the value, but it will make changes to the system.


You may read more about the differences of functions and keywords in this kowledgebase article:

Introduction to Zemax Programming Language (ZPL) · MyZemax


I hope this helps, but if you have any further questions, please do not hesitate to ask!


Best,

Csilla


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