Interface ZOSAPI::ISTARTools
Last update: 13.03.2026
Definition:
General collection of STAR tools that do not interact with the current Optical System.
Members
- DataTypeFromFileHeader
- ReadDeformationsFromFEAFile
- ReadDeformationsWithWeightFromFEAFile
- ReadDirectIndexFromFEAFile
- ReadStressFromFEAFile
- ReadTemperaturesFromFEAFile
Public functions
Function DataTypeFromFileHeader
int ZOSAPI.ISTARTools.DataTypeFromFileHeader(string filename)
Check the header of the file - if any - to see what data type it contains.
Parameters:
- filename: Full path of the file containing the FEA data
Returns:
Returns the type of data contained in the file, according to the header, encoded as the following integer: table {"type":"element","name":"table","attributes":{"cols":"16","rows":"1"},"children":[{"type":"element","name":"row","attributes":{},"children":[{"type":"text","text":"\n"},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Value "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Meaning "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"-2 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"OpticStudio was unable to open the file, or the header is malformed. "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"-1 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Unknown: the file has no header. "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"0 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Deformation. "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"1 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Deformation with weight. "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"2 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Temperature "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"3 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Direct Index "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"4 "}]},{"type":"text","text":"\n"}]},{"type":"element","name":"entry","attributes":{"thead":"yes"},"children":[{"type":"element","name":"para","attributes":{},"children":[{"type":"text","text":"Stress Tensor "}]},{"type":"text","text":"\n"}]}]},{"type":"text","text":"\n"}]}
Parameters:
- string filename
Return type: int
Function ReadDirectIndexFromFEAFile
ISTAR_PointWithIndex[] ZOSAPI.ISTARTools.ReadDirectIndexFromFEAFile(string filename)
Parameters:
- string filename
Return type: ISTAR_PointWithIndex[]
Function ReadTemperaturesFromFEAFile
ISTAR_PointWithTemperature[] ZOSAPI.ISTARTools.ReadTemperaturesFromFEAFile(string filename)
Parameters:
- string filename
Return type: ISTAR_PointWithTemperature[]
Function ReadDeformationsFromFEAFile
ISTAR_PointWithDeformation[] ZOSAPI.ISTARTools.ReadDeformationsFromFEAFile(string filename)
Parameters:
- string filename
Return type: ISTAR_PointWithDeformation[]
Function ReadDeformationsWithWeightFromFEAFile
ISTAR_PointWithDeformationAndWeight[] ZOSAPI.ISTARTools.ReadDeformationsWithWeightFromFEAFile(string filename)
Parameters:
- string filename
Return type: ISTAR_PointWithDeformationAndWeight[]
Function ReadStressFromFEAFile
ISTAR_PointWithStress[] ZOSAPI.ISTARTools.ReadStressFromFEAFile(string filename)
Parameters:
- string filename
Return type: ISTAR_PointWithStress[]