Jump to content

Mask with lines in canvas renderer


Recommended Posts

Hi there,

I'm using pixi 3.0.3, and I'm creating a mask using a line


Copying that code in the examples page http://pixijs.github.io/examples/index.html?s=demos&f=masking.js&title=Masking&v=v3.0.3 runs great in every browser supporting webGL. The expected result is shown in the followingimage

Line mask pixi3.0.3 webGL.png

But if I force the renderer to canvas (or disabling webGL in the browser), the result is the one seen in the attached image Line mask pixi 3.0.3 canvas. The mask isn't shown.


Can anyone point me out if this is a bug of pixi?

Thank you

PS: I'd prefer not moving the mask to a polygon, since the mask evolves with the time and will make the geometry too complex.



Link to comment
Share on other sites

Thank you for the reponse.

Why do you say so? So the only possible path will be to create polygons?

It's weird, because in the documentation there is no reference to this restriction, which I think it's quite annoying.

If anyone knows another workaround, I'd be more than happy to implement it

Link to comment
Share on other sites

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.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Recently Browsing   0 members

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