1. 投影灯光的辅助线对象

位于 BOS3D.ProjectorHelper

1.1. 类声明

投影灯光的辅助线对象,对投影灯光对象属性的部分更改,会同步更新该辅助线对象,继承于 LineSegments

1.1.1. 参数

名称 说明 类型 是否必须 示例
projectorLight 投影灯光对象 ProjectorLight null
//创建投影灯光对象
let projectorLight2 = new BOS3D.ProjectorLight({
    viewer: viewer3D,
    map: texture,
    alphaMap: BOS3D.textureLoaderObject.load("../../../textures/alphaMap.png"),
    target: new THREE.Vector3(-12000, -5000, 0),
    fov: 45,
    alpha: 0.5,
    aspect: 1.0,
    distance: 6700,
    color: new THREE.Color(0xffffff),
});
//设置投影灯光坐标
projectorLight2.position.set(-12000, -5000, 12000);
//将投影灯光对象场景中
viewer3D.addToRootScene(projectorLight2);

//创建投影灯光的辅助线对象
const helper2 = new BOS3D.ProjectorHelper(projectorLight2);
//将该辅助对象添加至场景中
viewer3D.addToRootScene(helper2);
版权所有@盈嘉互联(北京)科技有限公司 京ICP备15051988号-9 Copyright © 2022 all right reserved,powered by Gitbook该文件修订时间: 2022-06-27 15:28:07

results matching ""

    No results matching ""