Flippsor Posted March 11, 2021 Share Posted March 11, 2021 Hey guys, i am using PIXI.js for some months now and i am pretty happy with it. I am building a top down 2D CAD Software which uses a lot of PIXI.Graphics to draw Objects like Arrows/Lines/Rectangles etc. These are often combined in a PIXI.Container with parent/child relationship. So now my questions: Remove PIXI.Container (PIXI.Graphics) the right way If i have to remove a Graphics object, i use removeChild() from parent container. Is this everything i need to do? Or do i have to call .destroy() on the child, too? Redraw Graphics If i need to redraw a Graphic i can choose to either addChild/removeChild a new Graphic or just use the same Graphic with .clear() again. What technique is more performant and should be used? Thanks in advance! Quote Link to comment Share on other sites More sharing options...
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.