Reference Guide > U–V Routines > vtkLIGHT Procedure
  

vtkLIGHT Procedure
Adds a light to a VTK window.
Usage
vtkLIGHT
Input Parameters
None.
Keywords
Name—Specifies a name to be used to create this object. If an undefined variable is used or no name specified, then a random name is used. This name can be used in calls to vtkCOMMAND to modify this object.
Color—The color for the light. See the vtkWINDOW Procedure for possible ways to specify the color. (Default: 'white')
Position—An array of three floating point numbers describing the x, y, and z position for the light. The default behavior is to have the light follow the camera position.
FocalPoint—An array of three floating point numbers describing the x, y, and z position for the light’s focal point.
Intensity—Float value between 0.0 and 1.0 specifying the intensity of the light.
DirectionAngle—An array of two floating point numbers that set the position and focal point of a light based on elevation and azimuth. The light is moved to shine from the given angle. Angles are given in degrees.
Discussion
A white light, which follows the camera position, is created by default for a VTK Window.
 
note
Other light parameters not supported in this wrapper can be set using the assigned Name and vtkCOMMAND.
Example
pyramid_list = [[0,0,0],[0,1,0],[1,0,0],[1,1,0],[.5,.5,1]]
vertex_list=[3,0,2,4,3,2,3,4,3,3,1,4,3,1,0,4,4,0,1,3,2]
vtkPolyshade, pyramid_list, vertex_list
     vtkLight, Color='0000FF'XL, Position=[10,10,10]
     vtkLight, Color='00FF00'XL, Position=[10,10,-10]
     vtkLight, Color='FF0000'XL, Position=[-10,-10,-10]

Version 2017.0
Copyright © 2017, Rogue Wave Software, Inc. All Rights Reserved.