Skip to content

Conversation

@TechAngelX
Copy link
Owner

Overview

This PR introduces a dedicated dispose() method to handle the cleanup of unused wireframe materials and shaders.

Changes

  • Implements a recursive disposal function for GLB wireframe artefacts.
  • Ensures that material textures and shader programs are explicitly freed from GPU memory.
  • Prevents memory leaks during scene transitions or asset reloading.

Technical Notes

By explicitly calling .dispose() on the materials and geometries, we avoid "ghost" wireframes persisting in the buffer, which was previously causing visual artefacts after multiple re-renders.

Closes #1

@vercel
Copy link

vercel bot commented Jan 7, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
softwear Ready Ready Preview, Comment Jan 7, 2026 5:39am

@TechAngelX TechAngelX merged commit 1b263fa into main Jan 7, 2026
3 checks passed
@TechAngelX TechAngelX deleted the fix-dispose-method branch January 7, 2026 05:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Disapearing GLB objects - possibly dissove() method

2 participants