@babylonjs/viewer
Version:
The Babylon Viewer aims to simplify a specific but common Babylon.js use case: loading, viewing, and interacting with a 3D model.
19 lines (17 loc) • 540 B
JavaScript
let _lightsByJson = null;
function map() {
return _lightsByJson ??= /* @__PURE__ */ new WeakMap();
}
function setGltfPunctualLight(json, lightIndex, light) {
let lights = map().get(json);
if (!lights) {
lights = [];
map().set(json, lights);
}
lights[lightIndex] = light;
}
function getGltfPunctualLight(json, lightIndex) {
return json ? _lightsByJson?.get(json)?.[lightIndex] : void 0;
}
export { getGltfPunctualLight as g, setGltfPunctualLight as s };
//# sourceMappingURL=gltf-light-pointer-state-FBNUQ5Q_.esm.js.map