<pc-model>
The <pc-model>
tag is used to define an entity that instantiates a 3D model from a GLB file.
Usage
- It must be a direct child of a
<pc-scene>
or a<pc-entity>
.
Attributes
All attributes of <pc-entity>
are also available.
Attribute | Type | Default | Description |
---|---|---|---|
asset | String | - | Container asset ID (must reference a container type asset) |
Example
<pc-asset src="assets/car.glb" id="car"></pc-asset>
<pc-scene>
<pc-model asset="car"></pc-model>
</pc-scene>
JavaScript Interface
You can programmatically create and manipulate <pc-model>
elements using the ModelElement API.