Disable antialiasing and depth buffer for WebGL2 contexts

This commit is contained in:
Juan Campa
2019-01-15 16:36:38 -05:00
parent 66735ba671
commit 1d7a39bcfd
+2 -1
View File
@@ -82,7 +82,8 @@ export class WebglRenderer extends EventEmitter implements IRenderer {
this._renderDebouncer = new RenderDebouncer(this._terminal, this._renderRows.bind(this));
this._canvas = document.createElement('canvas');
this._gl = this._canvas.getContext('webgl2') as IWebGL2RenderingContext;
const contextAttributes = { antialias: false, depth: false };
this._gl = this._canvas.getContext('webgl2', contextAttributes) as IWebGL2RenderingContext;
if (!this._gl) {
throw new Error('WebGL2 not supported');
}