VideoComponentData interface
Data specification for VideoComponent, see ComponentManager.create() on how to create a component
Signature:
export interface VideoComponentData extends Component3DData
Extends: Component3DData
Properties
Property | Modifiers | Type | Description |
---|---|---|---|
autoPlay | false | Whether the video should start playing automatically. Defaults to false | |
id? | string | (Optional) if not provided, an auto id will be generated | |
name? | string | (Optional) name for the component. Defaults to "" | |
position? | XYZ | (Optional) Position of the component in the space. Defaults to {x: 0, y: 0, z: 0} | |
preview? | string | (Optional) url of the preview image to show when the video is not playing | |
rotation? | XYZ | (Optional) Rotation of the component in the space. Defaults to {x: 0, y: 0, z: 0} | |
scale? | XYZ | (Optional) Scale of the component in the space. Defaults to {x: 1, y: 1, z: 1} | |
type | "video" | ||
url | string | url of the video file | |
volume? | number | (Optional) Volume of the audio, from 0 to 1. Defaults to 1 |