How can i get through focus mtf data with zpl ?
Hello Sheng-BO,
Thanks for your question here!
You can use the GETTEXTFILE keyword in the macro to get access to the text output of the analysis tools. It creates a text file from any OpticStudio analysis window that supports text. The correct syntax is as follows:
GETTEXTFILE textfilename, type, settingsfilename, flag
The type argument is a 3 character string code that indicates the type of analysis to be performed. For the FFT Through Focus MTF the code is Tfm, for Huygens Through Focus MTF it is Htf, and for Geometric Through Focus MTF the code is Tfg. You can find the full list of string codes in the Help file under: The Programming Tab > String Codes
To modify the settings of the analysis, you can use the MODIFYSETTINGS keyword: The Programming Tab > About the ZPL > KEYWORDS (about the zpl) > MODIFYSETTINGS (keywords). If a valid file name in quotes or a string variable name is used for the settingsfilename argument, OpticStudio will use or save the settings used to compute the text file, depending upon the value of the flag parameter.
The detailed description of how to use the GETTEXTFILE keyword can be found in the Help under:
The Programming Tab > About the ZPL > KEYWORDS (about the zpl) > GETTEXTFILE (keywords)
After writing the results to a text file using the GETTEXTFILE keyword, you can read back the data into the macro if you need by using the READ keyword: The Programming Tab > About the ZPL > KEYWORDS (about the zpl) > READ
If you have any further questions please let us know, and we will be happy to help!
Best,
Csilla
Thank you
Reply
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.