Display
小于 1 分钟
Display
显示器物体,根据日常显示器参数设置大小、视频来源,继承自Thing,拥有Thing、THREE.Object3D一切属性和方法。
构造器
new VT.Display({
    // 造型参数
    geometry: {
        width: 0,
        height: 0,
        inches: 45,
        aspect: "16:9",
        depth: 0.01,
        border: 0.01,
    },
    // 材质
    material: {
        color: "#000000",
        metalness: 0.5,
        roughness: 0.3,
    },
    // 视频
    video: {
        src: "",
    }
})
属性成员
type
- 类型: 
{String}Display,是,不可修改 
isDisplay
- 类型: 
{Boolean}是否Display,是,不可修改 
box
- 类型:
{Box}Box 几何物体 
videoPlane
- 类型:
{VideoPlane}VideoPlane 视频平面 
video
- 类型:
{Video}HTMLElement Video 对象 
方法
updateGeometry
更新几何造型参数
- updateGeometry(geometry)
 - 类型:
Function - 参数: 
- geometry 
{Object}几何造型参数,见下 
 - geometry 
 - 返回:无
 
{
    // 宽度,可选
    width: 0,
    // 高度,可选
    height: 0,
    // 英寸
    inches: 45,
    // 分辨率
    aspect: "16:9",
    // 深度
    depth: 0.01,
    // 边框
    border: 0.01,
}
play
播放视频
- play()
 - 类型:
Function - 参数:无
 - 返回:无
 
pause
暂停播放视频
- pause()
 - 类型:
Function - 参数:无
 - 返回:无
 
updateVideo
更新视频
- updateVideo(video)
 - 类型:
Function - 参数: 
- video 
VideoHTMLElement Video 对象 
 - video 
 - 返回:无