Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
constructor(ifcModelId, xktFileUrl, metadataFileUrl) {
const viewer = new Viewer({
canvasId: 'xeokit-model-canvas-' + ifcModelId,
transparent: true
});
const cameraControl = viewer.cameraControl;
const scene = viewer.scene;
const cameraFlight = viewer.cameraFlight;
cameraControl.panToPointer = true;
cameraControl.doublePickFlyTo = true;
cameraFlight.duration = 1.0;
cameraFlight.fitFOV = 25;
viewer.camera.eye = [-2.56, 8.38, 8.27];
viewer.camera.look = [13.44, 3.31, -14.83];
viewer.camera.up = [0.10, 0.98, -0.14];
viewer.scene.xrayMaterial.fillAlpha = 0.1;
viewer.scene.xrayMaterial.fillColor = [0, 0, 0];
viewer.scene.xrayMaterial.edgeAlpha = 0.4;