Jump to content

Phaser Pixel Scaler plugin


beeglebug
 Share

Recommended Posts

I spent some time at the weekend trying to work out how to scale my game up without losing the lovely crisp pixels, and eventually settled on the technique that Rich wrote about in this tutorial: http://www.photonstorm.com/phaser/pixel-perfect-scaling-a-phaser-game

 

I thought this was a nice solution, so I ported the code to a Phaser Plugin to make it super easy to use. All you do is initialize it and it takes care of hiding the existing canvas, creating a new canvas and the relevant draw call to copy and scale the game.

 

You can find the plugin here if you want to to try it out (or contribute):

 

https://github.com/beeglebug/phaser-pixel-scaler

 

At the moment it just scaled the game by a fixed amount, but i'd like to extend it eventually so it can do full screen (similar to the existing ScaleManager).

 

Link to comment
Share on other sites

Hmmm, personally I think it's better where it is.

 

If it gets copied into that uber repo it just makes things confusing for people who want to raise issues or submit pull requests.

 

I don't see the problem with each plugin having it's own repo, it's how the rest of the open source world works.

Link to comment
Share on other sites

  • 3 weeks later...

Hey, thanks for making a proper pixel-scaler for Phaser! I'm just getting started with Phaser, & still learning about its features. Can you briefly touch upon how this method is different from the "Pixelation" feature that's built-in to the underlying Pixi.js framework? Thanks!

 

PickPacket

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...