Description Retrieves the parameters of a source's Laser Diode Beam ray direction specification.
Syntax success = GetSourceDirLaserDiode( srcNode, ld )
Parameters success (Boolean) Returned boolean indicating the status of the query. True if the source's ray direction specification is Laser Diode Beam, False otherwise.
srcNode As Long Node number of the source whose ray direction specification is being queried.
ld As T_SOURCEDIRLASERDIODE Data structure containing the parameters of the Laser Diode Beam ray direction specification.
Example The following script demonstrates how to query, retrieve and modify the Laser Diode Beam ray direction specification of a source node.
Sub Main
Dim ld As T_SOURCEDIRLASERDIODE Dim srcNode As Long Dim success As Boolean
'Source node being queried srcNode = FindFullName( "Optical Sources.LaserDiodeSource" )
'Does the source node have laser diode beam ray directions? If IsSourceDirLaserDiode( srcNode ) Then
'Retrieve the source's laser diode direction specifications success = GetSourceDirLaserDiode( srcNode, ld ) Print "Current Laser Diode Parameters: " Print Chr(9) & "Angle Type: " & Chr(9) & ld.angleType Print Chr(9) & "X Focus: " & Chr(9) & ld.focusX Print Chr(9) & "Y Focus: " & Chr(9) & ld.focusY Print Chr(9) & "X Samples: " & Chr(9) & ld.numX Print Chr(9) & "Y Samples: " & Chr(9) & ld.numY Print Chr(9) & "X Semi Ang: " & Chr(9) & ld.semiAngX Print Chr(9) & "Y Semi Ang: " & Chr(9) & ld.semiAngY
'Set the default ray directions back to the source InitSourceDirLaserDiode ld SetSourceDirLaserDiode srcNode, ld Print "Source reset to default laser diode ray directions."
End If
End Sub
See Also
|