The ambientLight command is used to edit the parameters of existing ambientLights, or to create new ones. The default behaviour is to create a new ambientlight.
Flags:
Long Name / Short Name | Argument Types | Properties | |
---|---|---|---|
ambientShade / ambientShade | float | ![]() ![]() ![]() |
|
|
|||
discRadius / drs | float | ![]() ![]() ![]() |
|
|
|||
exclusive / exc | bool | ![]() ![]() |
|
intensity / i | float | ![]() ![]() ![]() |
|
|
|||
name / n | unicode | ![]() ![]() ![]() |
|
|
|||
position / pos | float, float, float | ![]() ![]() |
|
rgb / rgb | float, float, float | ![]() ![]() ![]() |
|
|
|||
rotation / rot | float, float, float | ![]() ![]() |
|
shadowColor / sc | float, float, float | ![]() ![]() ![]() |
|
|
|||
shadowDither / sd | float | ![]() ![]() ![]() |
|
|
|||
shadowSamples / sh | int | ![]() ![]() ![]() |
|
|
|||
softShadow / ss | bool | ![]() ![]() ![]() |
|
|
|||
useRayTraceShadows / rs | bool | ![]() ![]() ![]() |
|
|
Derived from mel command maya.cmds.ambientLight
Example:
import pymel.core as pm
# Create an ambientLight light
light = pm.ambientLight(intensity=0.8)
# Change the light intensity
pm.ambientLight( light, e=True, intensity=0.5 )
# Query it
pm.ambientLight( light, q=True, intensity=True )
# Result: 0.5 #