Lights (wip)

You can easily create the following lights :

Example :

<PointLight color="#ffffff" :intensity="0.5" />

Common Props (see Light.ts)

NameDescriptionTypeDefault
castShadowCasting shadowBooleanfalse
colorLight colorString, Number#ffffff
intensityLight intensityNumber1
positionLight positionObject{ x: 0, y: 0, z: 0 }
shadowMapSizeShadow map sizeObject{ width: 512, height: 512 }

Access ThreeJS light

You should set a ref on your light :

<PointLight ref="light" />

You can then access ThreeJS light in your component script :

const light = this.$ref.light.light;