Jump to content

Particles crash chrome tab


zincman320
 Share

Recommended Posts

When I run the following code on google chrome I run out of memory (8 GB) and the tab crashes. I don't have this problem on IE 11.

var bounds = 1000;var starfield = new BABYLON.ParticleSystem("starfield", 2000, scene);starfield.particleTexture = new BABYLON.Texture("/images/star.png", scene);starfield.minSize = 0.8;starfield.maxSize = 1.0;starfield.minLifeTime = 1.0;starfield.maxLifeTime = 2.0;starfield.minEmitPower = 4.0;starfield.maxEmitPower = 4.0;starfield.emitRate = 2000;starfield.blendMode = BABYLON.ParticleSystem.BLENDMODE_ONEONE;starfield.minEmitBox = new BABYLON.Vector3((-1) * bounds, 0, (-1) * bounds);starfield.maxEmitBox = new BABYLON.Vector3(bounds, 0, bounds);starfield.direction1 = new BABYLON.Vector3(0, 0, 0);starfield.direction2 = new BABYLON.Vector3(0, 0, 0);starfield.emitter = new BABYLON.Vector3(0, -5, 0);starfield.disposeOnStop = true;starfield.start();

I know this is the code causing the crash because when I comment it out memory usage stays level.

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...