pixijs webgl模式实现刮刮卡的方法
const app = new PIXI.Application({ width: 750, height: 1206, antialias: true}); var guanbi = PIXI.Sprite.from('/moban/images/closebtn1.png'); guanbi.width = 222; guanbi.height = 222; guanbi.name = 'guanbi1'; app.stage.addChild(guanbi); var guanbi = PIXI.Sprite.from('/caitongxiaonian/images/closebtn1.png'); guanbi.width = 222; guanbi.height = 222; guanbi.x=72; guanbi.y=72; guanbi.blendMode = PIXI.BLEND_MODES.XOR; guanbi.name = 'guanbi2'; app.stage.addChild(guanbi); document.body.appendChild(app.view);