Nikow Posted January 30, 2015 Share Posted January 30, 2015 Hi! I use in my game, bar.mask = graphics;It's working perfectly on chrome and firefox, but in safari, there isn't my mask ... Do you know why ?? Thanks ! Link to comment Share on other sites More sharing options...
Nikow Posted February 1, 2015 Author Share Posted February 1, 2015 up ? Link to comment Share on other sites More sharing options...
Nikow Posted February 3, 2015 Author Share Posted February 3, 2015 Up again, pleaaase Link to comment Share on other sites More sharing options...
mxmlb Posted February 3, 2015 Share Posted February 3, 2015 Hello, I remember reading Pixi can handle only 1 single mask on a canvas, while it can have several on WebGL. Maybe your game runs on WebGL in Firefox & Chrome but not in Safari ? Nikow 1 Link to comment Share on other sites More sharing options...
Nikow Posted February 5, 2015 Author Share Posted February 5, 2015 Hi ^^ I test it but it's not the prob... Link to comment Share on other sites More sharing options...
Nikow Posted February 6, 2015 Author Share Posted February 6, 2015 Hello, I remember reading Pixi can handle only 1 single mask on a canvas, while it can have several on WebGL. Maybe your game runs on WebGL in Firefox & Chrome but not in Safari ? Hi ! I test again, phaser is in WEBGL render mode on chrome and firefox, but in CANVAS mode on safari and IE, i think it s the prob with the mask, but i have an error if i put phaser.WEBGL mode everytime ...? Do you know why ? Link to comment Share on other sites More sharing options...
Nikow Posted February 6, 2015 Author Share Posted February 6, 2015 My code is : Creating the maskgraphics = game.add.graphics(0, 0);graphics.lineStyle(6, 0x33FF00);graphics.moveTo(390,400);graphics.lineTo(valBar, 400);bar.mask = graphics;Updating the mask : graphics.clear();graphics.lineStyle(6, 0x33FF00);graphics.moveTo(360,400);graphics.lineTo(valBar, 400); Link to comment Share on other sites More sharing options...
Nikow Posted February 9, 2015 Author Share Posted February 9, 2015 up :,( ...Really need help ! Link to comment Share on other sites More sharing options...
mxmlb Posted February 9, 2015 Share Posted February 9, 2015 Hi, What is your error ? I would say your versions of IE and Safari does not support WebGL if you got an error msg, but it's always useful if you can provide it. Can you try alpha masking with BitmapData ? The technical requirements may not be the same, but you'll have to adjust your code a little. http://examples.phaser.io/_site/view_full.html?d=bitmapdata&f=alpha+mask.js&t=alpha%20mask Link to comment Share on other sites More sharing options...
Nikow Posted February 9, 2015 Author Share Posted February 9, 2015 hi ! Thank you first !Yes, Safari and IE which i tested are not supported WebGL .. I will try as soon as i can alpha masking with BitmapDate ! Link to comment Share on other sites More sharing options...
Nikow Posted February 10, 2015 Author Share Posted February 10, 2015 Hi ! Masking using BtmapData is working on safari ! Now, i need to move this mask, how can i do that ? Link to comment Share on other sites More sharing options...
Nikow Posted February 11, 2015 Author Share Posted February 11, 2015 I find ! It was just a prob with the draw method, with a rectangle, all is ok ! THanks for all ! Nikow 1 Link to comment Share on other sites More sharing options...
Recommended Posts