未验证 提交 4bcb1dfe 编写于 作者: M Mr.doob 提交者: GitHub

Merge pull request #14988 from tknickman/patch-1

fix(docs): Update example & link for Detector.js -> WebGL.js
......@@ -15,16 +15,16 @@
</p>
<p>
Add [link:https://github.com/mrdoob/three.js/blob/master/examples/js/Detector.js]
Add [link:https://github.com/mrdoob/three.js/blob/master/examples/js/WebGL.js]
to your javascript and run the following before attempting to render anything.
</p>
<code>
if (Detector.webgl) {
if (WEBGL.isWebGLAvailable()) {
// Initiate function or other initializations here
animate();
} else {
var warning = Detector.getWebGLErrorMessage();
var warning = WEBGL.getWebGLErrorMessage();
document.getElementById('container').appendChild(warning);
}
</code>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册