Skip to main content

Editor.Components.LightType

Enum

Settings used with Editor.Components.LightSource.

Index

Example

const model = this.pluginSystem.findInterface(Editor.Model.IModel) as Editor.Model.IModel;
const scene = model.project.scene;

// Create a LightSource and set it to Spot type
const obj = scene.createSceneObject('SpotLight');
const light = obj.addComponent('LightSource');
light.lightType = Editor.Components.LightType.Spot;
light.intensity = 2.0;
light.innerConeAngle = 15;
light.outerConeAngle = 30;
console.log(`lightType: ${light.lightType}`);

Enumeration Members

Ambient

Ambient: number

Ambient light uniformly illuminating the scene.


Directional

Directional: number

Directional light emitting parallel rays from a fixed direction.


EnvMap

EnvMap: number

Environment map light using a texture to provide scene illumination.


Estimation

Estimation: number

Light estimated from real-world scene analysis.


Point

Point: number

Point light emitting in all directions from a single position.


Spot

Spot: number

Spot light emitting a cone of light in a specific direction.