kittykatattack / learningPixi

A step-by-step introduction to making games and interactive media with the Pixi.js rendering engine.
4.41k stars 849 forks source link

the value of PIXI.utils.isWebGLSupported() is false, i want to konw why #153

Open chunmingdeng opened 4 years ago

chunmingdeng commented 4 years ago

thsi is my device params image image

when i check the function 'PIXI.utils.isWebGLSupported', i found the code below var t = { stencil: !0, failIfMajorPerformanceCaveat: !0 }; try { if (!window.WebGLRenderingContext) return !1; var e = document.createElement("canvas"), n = e.getContext("webgl", t) || e.getContext("experimental-webgl", t), i = !(!n || !n.getContextAttributes().stencil); if (n) { var r = n.getExtension("WEBGL_lose_context"); r && r.loseContext() } return n = null, i } catch (o) { return !1 } but i didn't found anywhere call this function 'PIXI.utils.isWebGLSupported' so, how does pixi.js judge which mode to use, 'canvas' or 'webgl' ? can you help me? thanks!!

chunmingdeng commented 4 years ago

the pixi.js version i use is 4.8.9