From c7a523b41a19081d8e4071ea7a8fadbec8f9dec8 Mon Sep 17 00:00:00 2001 From: Quinn Hoener Date: Sat, 20 May 2017 09:18:27 -0700 Subject: [PATCH] Added support for getting a webgl2 context for the graphics object. --- source/Graphics.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/Graphics.js b/source/Graphics.js index 5327de0..469af7e 100644 --- a/source/Graphics.js +++ b/source/Graphics.js @@ -7,7 +7,7 @@ var Graphics = (function() preserveDrawingBuffer: true }; - var _GL = canvas.getContext("webgl", contextOptions) || canvas.getContext("experimental-webgl", contextOptions); + var _GL = canvas.getContext("webgl", contextOptions) || canvas.getContext("experimental-webgl", contextOptions) || canvas.getContext("webgl2", contextOptions); var _AnisotropyExtension = _GL.getExtension("EXT_texture_filter_anisotropic"); var _MaxAnisotropy;