Added clear rect to transparent canvas renderer
This commit is contained in:
parent
f127cfe1ef
commit
13ef9ea96c
3 changed files with 21 additions and 9 deletions
|
@ -7531,11 +7531,17 @@ PIXI.CanvasRenderer.prototype.render = function(stage)
|
|||
|
||||
this.context.setTransform(1,0,0,1,0,0);
|
||||
|
||||
if(this.view.style.backgroundColor !== stage.backgroundColorString && !this.transparent)
|
||||
if(this.view.style.backgroundColor !== stage.backgroundColorString )
|
||||
{
|
||||
this.context.fillStyle = stage.backgroundColorString;
|
||||
this.context.fillRect(0, 0, this.width, this.height);
|
||||
// this.context.clearRect(0, 0, this.width, this.height);
|
||||
if(!this.transparent)
|
||||
{
|
||||
this.context.fillStyle = stage.backgroundColorString;
|
||||
this.context.fillRect(0, 0, this.width, this.height);
|
||||
}
|
||||
else
|
||||
{
|
||||
this.context.clearRect(0, 0, this.width, this.height);
|
||||
}
|
||||
}
|
||||
|
||||
//console.log(this.view.style.backgroundColor)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue