lukaMis Posted September 3, 2015 Share Posted September 3, 2015 Hi In my example image wall and wood in the background will never change. Is it better to set that image via css on canvas parent element and then overlay phaser canvas with transparency over it or have the image as background inside phaser on stage. Does that change even impact performance? tnx Link to comment Share on other sites More sharing options...
tips4design Posted September 3, 2015 Share Posted September 3, 2015 When I create applications (not games) I usually use a CSS backgroundso I can make my stage size smaller (background in CSS fills whole screen, phaser app is actually just a part of the center of the screen). If your app cover the entire page, then I guess adding a background image won't hurt performance that much, but if you have to scale your game to fit the browser just to add a background image, you better end up using CSS. Link to comment Share on other sites More sharing options...
VitaZheltyakov Posted September 3, 2015 Share Posted September 3, 2015 Only image. CocoonJS like it. Link to comment Share on other sites More sharing options...
netcell Posted September 4, 2015 Share Posted September 4, 2015 Only image. CocoonJS like it. Do you have information about performance regarding this matter? I'm using CocoonJS and I would like to know if using an img tag for background performs any better than using a Phaser.Image object on the canvas Thanks. Link to comment Share on other sites More sharing options...
Recommended Posts