view: enable alpha blending

This commit is contained in:
Matthias Schiffer 2018-10-31 00:19:02 +01:00
parent 7a9cd36337
commit 7b9d467386
Signed by: neocturne
GPG key ID: 16EF3F64CB201D9C

View file

@ -14,6 +14,10 @@ export default class Renderer {
this.gl.clearColor(0.0, 0.0, 0.0, 1.0); this.gl.clearColor(0.0, 0.0, 0.0, 1.0);
this.gl.enable(this.gl.BLEND);
this.gl.blendFunc(this.gl.ONE, this.gl.ONE_MINUS_SRC_ALPHA);
this.gl.pixelStorei(this.gl.UNPACK_PREMULTIPLY_ALPHA_WEBGL, 1);
this.setSize(); this.setSize();
} }