Changes
Co-authored-by: Reifonas <211114984+Reifonas@users.noreply.github.com>
This commit is contained in:
@@ -767,12 +767,14 @@ function VisibilityApplier() {
|
||||
// For each ifcElement descendant inside this model root
|
||||
root.traverse((el) => {
|
||||
if (!el.userData?.ifcElement) return;
|
||||
touched++;
|
||||
const key = elementKey(modelId, el);
|
||||
const hidden = hiddenElementKeys.has(key);
|
||||
const isolated = isolatedElementKeys ? !isolatedElementKeys.has(key) : false;
|
||||
el.visible = !(hidden || isolated);
|
||||
|
||||
const selected = selectedElementKeys.has(key);
|
||||
if (selected) highlighted++;
|
||||
el.traverse((m) => {
|
||||
if (!(m instanceof THREE.Mesh)) return;
|
||||
const mats = Array.isArray(m.material) ? m.material : [m.material];
|
||||
@@ -796,6 +798,7 @@ function VisibilityApplier() {
|
||||
});
|
||||
});
|
||||
});
|
||||
console.log('[VisibilityApplier] ran', { touched, highlighted, selectedKeys: Array.from(selectedElementKeys) });
|
||||
}, [scene, nonce, models, opacity, renderMode, checklist]);
|
||||
|
||||
return null;
|
||||
|
||||
Reference in New Issue
Block a user