Skip to content

Light (JavaScript) ​

Light ​

Scripting Name:Insight.Light

光源类。

Properties ​


color ​

type :Insight.Vector4

光源颜色。

estimationColor ​

type :Insight.Vector4

(只读)真实环境主光源颜色的估算值。

该光源是指通过设备摄像头获取的环境中主光源。调用一次 Tracking 类中的 EstimateIllumination()方法可使 estimationColor 和 estimationIntensity 的值更新。

estimationIntensity ​

type : number

(只读)真实环境主光源强度的估算值。

该光源是指通过设备摄像头获取的环境中主光源。调用一次 Tracking 类中的 EstimateIllumination()方法可使 estimationColor 和 estimationIntensity 的值更新。

intensity ​

type : number

光源强度。

Methods ​


toString ​

public string toString();

将 light 内容以一定格式转为 string 类型。

Inherited Properties(继承自 Component) ​


enabled ​

type : boolean

该组件是否是可用的。

gameObject ​

type :Insight.GameObject

(只读)该组件所依附的 GameObject。

isActiveAndEnabled ​

type : boolean

(只读)该组件是否可用,且其依附的 GameObject 是否是活跃状态。

name ​

type : string

(只读)所依附的 GameObject 的名称。

tag ​

type : string

(只读)所依附的 GameObject 的 Tag。

⚠️ 暂时未启用

transform ​

type :Insight.Transform

(只读)所依附的 GameObject 的 transform。