Jump to content

No memory released on mesh.dispose()


simon_bg
 Share

Recommended Posts

Hi guys!

I have this scene where I import different meshes with lots of polygons, like here: http://babylonjs-playground.com/#1OI6LZ#11 
You'll see that I'm importing the same mesh repeated times instead of using instances on purpose. 

So at some moment, I'd like to remove some of these meshes. 
In the example above, when you click on the skulls, the mesh.dispose() is called.

When I track the memory with the Chrome JS Heap timeline tool I can't really see the memory released though when the dispose() function is called.

Here the four skulls were loaded and then I clicked on every one of them, so shouldn't there be some drops visible?:unnamed.thumb.png.1a92fb2715b66cc00efec6

Is there something I'm missing? 

Link to comment
Share on other sites

Thanks, David!


I made another test though, and I haven't used Action Managers at all this time: http://babylonjs-playground.com/#1OI6LZ#21

Here, I'm loading four meshes into an array, and when I rotate the camera and a mesh is not longer active, I dispose it and also delete it from the array. 
I get this graphic now, and again, I can't see memory being released:

arrayTest.thumb.PNG.b4ee0b39f75a4dfbf35b

:(

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...