name: pixijs-scene-particle-container description: "Use for PixiJS v8 ParticleContainer and Particle: thousands of lightweight sprites, addParticle/removeParticle, particleChildren, dynamicProperties, boundsArea, roundPixels." license: MIT
Use this for very large counts of lightweight sprite-like particles.
Fast Path
import { Particle, ParticleContainer, Texture } from 'pixi.js';
const pc = new ParticleContainer({ dynamicProperties: { position: true, rotation: true } });
pc.addParticle(new Particle({ texture: Texture.WHITE, x: 100, y: 100 }));
app.stage.addChild(pc);
Rules
ParticleContainerstoresParticleinstances inparticleChildren; useaddParticle, notaddChild.- Wrap the
ParticleContainerin a normalContainerwhen it must be grouped with other display objects. - Enable only the
dynamicPropertiesyou mutate (vertex,position,rotation,uvs,color) to keep uploads cheap. - Use shared textures/atlases and stable object pools.
- Set
boundsAreawhen automatic bounds are not useful. - Choose
Sprite/Containerinstead when each object needs filters, masks, events, children, or rich per-object features.
Deep Reads
- Full options, examples, and lifecycle: references/details.md
- Scene graph basics:
pixijs-scene-core-concepts - Assets and atlases:
pixijs-assets - Performance tradeoffs:
pixijs-performance
Common Fixes
addChildfails or acts wrong: useaddParticle.- Per-particle interactivity required: use normal sprites instead.
- Slow updates: disable dynamic properties that never change.