thingorigin2.0
    正在准备搜索索引...

    自定义光源的基类,用于

    索引

    构造函数

    属性

    tScene: TScene
    AmbientLight: number = 0
    DirectionalLight: number = 1
    HemisphereLight: number = 2
    PointLight: number = 3
    RectAreaLight: number = 4
    SpotLight: number = 5

    访问器

    • get lightList(): Light<LightShadow<Camera>>[]

      获取光源列表

      返回 Light<LightShadow<Camera>>[]

    方法

    • 添加环境光

      参数

      • name: string
      • 可选color: string | number | Color
      • 可选intensity: number

      返回 any

    • 添加平行光

      参数

      • name: string
      • 可选color: string | number | Color
      • 可选intensity: number
      • lightConfig: { position: { x: number; y: number; z: number } } = ...

      返回 DirectionalLight

    • 添加光源

      参数

      • id: string

        光源的位移标识符

      • light: Light

        光源

      返回 void

    • 添加点光源

      参数

      • 可选color: string | number | Color
      • 可选intensity: number
      • 可选distance: number
      • 可选decay: number

      返回 void

    • 清空所有光源

      返回 void

    • 删除光源

      参数

      • id: string

      返回 void

    • 获取光源

      参数

      • id: string

      返回 Light

    • 根据光源id查找

      参数

      • id: string

      返回 boolean

    • 窗口变动更新光源事件

      参数

      • container: HTMLElement

      返回 void