Sign in to follow this  
megmut

Container vs ParticleContainer

Recommended Posts

Hey guys, just a really quick question on containers. I see that you can use a PIXI.particles.ParticleContainer. In the documentation is says that it doesn't support features such as tinting, alpha, masking etc.. However, as this class is extending from the normal Container, I am curious as to what is different, and how it achieves this.

 

Thanks,

Nick

Share this post


Link to post
Share on other sites

It inherits from Container, but overrides a few critical methods related to updating the transforms and for rendering, in both cases optimising them for particle usage. 

The quickest way sometimes to look at the code rather then going though github is to go via the docs: http://pixijs.download/dev/docs/particles_ParticleContainer.js.html

Share this post


Link to post
Share on other sites

Ah okay, thanks! I've been playing around with a simple particle emitter because, why not.. and I've got it to roughly 30k with multiple textures still at 60fps. I crated some simple pooling and lightweight gravity and velocity "physics". Thanks for the response :)

Share this post


Link to post
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...
Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.