patrickfabrizius Posted October 20, 2015 Share Posted October 20, 2015 I've had some issues (PIXI 3.0.7) with large spritesheets lately and recently learned a lot about it by searching around this forum and the PIXI github comments. There are still a few things that puzzles me, however: * Does the MAX_TEXTURE_SIZE limit apply only for WebGL renderer, or canvas renderer as well? (During a test I did it seemed like using the canvas renderer let me use bigger spritesheets than WebGL).* Are there any "best practices" as of spritesheet size limits; I understand it all depends on the device, but what choices have YOU made, and why? Is it safe to say that 4096x4096 spritesheets are OK for reasonable backward compatibility, or do you use 2048x2048, or less? * I've tested splitting up my spritesheets (using the multipack feature in Texturepacker), but wonder how PIXI handles several spritesheets under the hood. Are there any disadvantage of having say, 10 sprites with 10 different assets from 10 spritesheets over using just one spritesheet? (Other than loading time, of course). And what about movieclips with frames loaded from different spritesheets? * In general, what would you guys say is the best practice for dealing with large assets (full screen retina backgrounds, full screen movieclips, etc)? Let the loader load it all, or do I need to carefully load / unload them from memory as I go? * I've seen that some of you repeatedly advice to use: new PIXI.Sprite(PIXI.loader.resources[myFrame]) over:new PIXI.Sprite(PIXI.utils.TextureCache[myFrame])ornew PIXI.Sprite.fromFrame(myFrame).. when using the PIXI loader, that you might end up having duplicates in memory. It seems I get slightly worse performance taking that advice, though (a couple 100ms longer render time and slightly more memory usage)? Is this something that has changed with PIXI v3 or am I doing something wrong? Thanks in advance, and thanks for all your great work with PIXI! 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.