Navigation: Scripting Reference Manual > Functions & Subroutines > AddModelMaterial

 

AddModelMaterial

 

Contact Us: fredsupport@photonengr.com

 

Description

Adds a new model glass material to the associated FRED document.

 

Syntax

id = AddModelMaterial ( material )

 

Parameters

id (Long)

        Identifier of the new model material.

 

material As T_MODELMATERIAL

Structure containing the name, description, refractive index and Abbe number (dispersion) values for the new model material.

 

 

Remarks

This function adds a new Model glass Material to the associated FRED document and returns the identifier of the added material.  If it is unable to create the material or add it to the document, it posts an error and returns a value of -1.

 

A model glass material is an approximation to a real optical glass with the same refractive index and dispersion.

 

See Also

T_MODELMATERIAL

InitModelMaterial

SetModelMaterial

GetModelMaterial

Examples

Materials

 

 

 

 

 

Copyright © Photon Engineering, LLC