thatopen-errors-performance

Fix ThatOpen BIM viewer crashes from memory leaks and main-thread blocking.

17|1|Updated Mar 20, 2026
One-click install
npx skills add https://github.com/Impertio-Studio/ThatOpen-Claude-Skill-Package --skill thatopen-errors-performance-impertio-studio
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: thatopen-errors-performance
Source: https://github.com/Impertio-Studio/ThatOpen-Claude-Skill-Package/tree/main/skills/source/thatopen-errors/thatopen-errors-performance
Command: npx skills add https://github.com/Impertio-Studio/ThatOpen-Claude-Skill-Package --skill thatopen-errors-performance-impertio-studio

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

It prevents ThatOpen BIM viewers from crashing or freezing by fixing the most common causes of performance degradation: memory leaks, undisposed GPU resources, missing worker initialization, and blocking main-thread operations.

Core Features & Use Cases

  • Disposal correctness for components and models: Uses components.dispose() for full teardown and fragments.disposeModel(modelId) for per-model unloading without leaving GPU/worker state behind.
  • Three.js GPU memory hygiene: Ensures geometries, materials, textures (and their maps), and render targets are explicitly disposed when created outside components.
  • Worker-first performance guarantees: Ensures FragmentsManager is initialized with the correct worker URL to keep heavy operations off the main thread.
  • Large model stability tactics: Covers fragment conversion strategy (load fragments, not raw IFC repeatedly), IFC class filtering, model federation, selective loading, and performance pitfalls like z-fighting via polygon offset.
  • Practical troubleshooting guidance: Provides DevTools memory profiling steps and a checklist to diagnose leaks across load/unload cycles.

Quick Start

Use the thatopen-errors-performance skill when your ThatOpen viewer crashes, leaks memory after loading/unloading models, or becomes unresponsive due to large BIM models.

Frequently Asked Questions about thatopen-errors-performance

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
Why does my ThatOpen BIM viewer crash or freeze when loading large IFC models?

Browser crashes and UI freezes in ThatOpen viewers are typically caused by memory leaks from undisposed Three.js GPU resources, missing worker initialization, and blocking main-thread operations during large IFC model loading.

How do I properly dispose of Three.js geometries and materials in a ThatOpen viewer?

To dispose of Three.js resources in ThatOpen, use `components.dispose()` for full teardown and `fragments.disposeModel(modelId)` for per-model unloading, ensuring geometries, materials, textures, and render targets are explicitly destroyed to prevent GPU memory leaks.

How do I stop main-thread blocking when raycasting or querying data in ThatOpen fragments?

To stop main-thread blocking during raycasting or data queries, initialize `FragmentsManager` with a correct version-matched worker URL to offload heavy operations, keeping the UI responsive under heavy GPU usage.

What is the best way to optimize ThatOpen performance for repeated IFC loading and unloading?

The best way to optimize ThatOpen performance for repeated workflows is to load fragments instead of raw IFC repeatedly, apply IFC class filtering, and use model federation to manage memory safely across load and unload cycles.

How do I fix z-fighting issues in ThatOpen BIM overlays and highlighting?

To fix z-fighting in ThatOpen BIM overlays and highlighting, apply polygon offset techniques to resolve depth buffer conflicts, ensuring stable rendering performance under heavy GPU usage.

Can I use ThatOpen components for large model optimization without experiencing memory leaks?

Yes, you can use ThatOpen components for large model optimization without memory leaks by following correct disposal ordering, explicitly cleaning up Three.js GPU resources, and using DevTools memory profiling to diagnose leaks across load and unload cycles.