Jump to content

Phaser image editor


odelia
 Share

Recommended Posts

I have a project where the user have a menu of items (let's call them stickers) and he place them on the stage.

I want them to be able to edit them (scale and rotation).

I don't want it to be a toolbar but a display on the element itself.

I found what I need but it's on fabric.js

Can I use that code on Phaser? Can I find a library that does the same thing for Phaser?

Link to comment
Share on other sites

Nope, fabric really wants to control the canvas. Phaser and fabric can't use the same canvas element.

Depending on what your code needs to do, though, you could have two canvases. One on top of the other. The Phaser canvas could be underneath and the fabric canvas could be on top. When you need to drag or reposition something you could set it to renderable=false in Phaser and stick its image in fabric until the user is done, then pull the values out of fabric and set them on the Phaser.Sprite and set it renderable=true again.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

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