Navigation: Scripting Reference Manual > Functions & Subroutines > AddRaytraceCtrl

 

AddRaytraceCtrl

 

Contact Us: fredsupport@photonengr.com

 

Description

Adds a new Raytrace Control to the associated FRED document.

 

Syntax

id = AddRaytraceCtrl ( rtCtrl )

 

Parameters

id (Long)

Identifier of the new Raytrace Control.

 

rtCtrl As T_RAYTRACECTRL

Structure containing data for the new Raytrace Control.

 

 

Remarks

This function adds a new Raytrace Control to the associated FRED document and returns the identifier of the new raytrace control.  If it fails, an error is posted and the function returns a value of -1.

 

Each surface has a raytrace control and a coating assigned to it.  The raytrace control and the coating work together to determine what happens when a ray intersects the surface.  The coating sets transmitted and reflected ray properties such as power, phase, polarization, etc.  The raytrace control specifies the conditions under which transmitted and reflected rays may be created and allowed to propagate.  In other words, the raytrace control specifies which of the possible transmitted and reflected rays are actually created, and the coating sets the properties of those rays.

 

See Also

T_RAYTRACECTRL

InitRaytraceCtrl 

SetRaytraceCtrl

GetRaytraceCtrl

GetRaytraceCtrlCount

Examples

Raytrace Controls

 

 

 

 

 

Copyright © Photon Engineering, LLC