Product Lighting Controls
Control lighting in your 3D product scenes to create optimal product presentation and highlight key features. Perfect lighting is essential for e-commerce and product configurators to show products in their best light. Light functions allow you to control and manipulate lighting in your product scenes. You can retrieve information about existing lights and update their properties to create the perfect product presentation atmosphere.
getLights
getLights(callback: Function)
Gets a list of all lights in the scene.
js
api.getLights(function (lights) {
console.log(lights);
});
1
2
3
2
3
updateLight
updateLight(options: object, [callback: Function])
Updates a light by setting some options. To get all options of a given light, use the getLights function.
js
api.getLights(function (lights) {
light = lights[0];
light.intensity = 0.5;
api.updateLight(light);
});
1
2
3
4
5
2
3
4
5