Previous Document Next Document
EffectExtrude.SetLight

Sub SetLight(Index As Long, Position As cdrExtrudeLightPosition, LightIntensity As Long)

Member of EffectExtrude

The SetLight method enables the given light source and specifies its properties for an extrusion.

See also LightPresent, LightPosition, and LightIntensity properties.

Parameters
Description
Index
Specifies the index where the light property is set
Position
Specifies the position of the light property in the extrude effect. This value returns cdrExtrudeLightPosition
LightIntensity
Sets the light intensity

The following code example creates an extrusion with two light sources:

Sub Test() 
 Dim s As Shape 
 Set s = ActiveLayer.CreateArtisticText(2.75, 5, "Text") 
 With s.Text.FontProperties 
  .Name = "Arial Black" 
  .Size = 150 
 End With 
 s.Fill.UniformColor.RGBAssign 0, 0, 255 
 With s.CreateExtrude(cdrExtrudeSmallBack, cdrVPLockedToShape, 4, _ 
   8, , cdrExtrudeSolidFill, CreateRGBColor(255, 0, 0)).Extrude 
  .SetLight 1, cdrLightBackTopRight, 100 
  .SetLight 2, cdrLightFrontCenter, 50 
  .LightPresent(3) = False 
 End With 
End Sub 

Previous Document Next Document Back to Top

Copyright 2007 Corel Corporation. All rights reserved.