【性能兼容问题】Firefox 运行范例集合帧数异常很低 FPS 为 10 左右

  • Creator 版本:2.0.7

  • 目标平台: MacOS 10.13.6、Firefox 64.0

  • 详细报错信息,包含调用堆栈:

Cocos Creator v2.0.7 CCGame.js:398:8
Error: WebGL warning: texSubImage2D: Texture has not been initialized prior to a partial upload, forcing the browser to clear it. This may be slow. render-engine.js:8262:6
Error: WebGL warning: texSubImage2D: This operation requires zeroing texture data. This is slow. render-engine.js:8262:6
Error: WebGL warning: clear: Calling gl.clear(0) has no effect. render-engine.js:9774:2
Error: WebGL: No further warnings will be reported for this WebGL context. (already reported 32 warnings) render-engine.js:9774:2

  • 重现方式:2.0.7 版本使用范例集合创建一个项目,用 Firefox 打开运行就能看到如上错误信息。

  • 出现概率:必现

  • 额外线索:Safari、Chrome 均无上面报错,并且 FPS 正常。正在开发的项目也出现和范例集合一样的问题,麻烦解决一下。

这么严重? 我们测试下,看看什么情况!

测试没有这个问题,你可能是开了多个浏览器,导致firefox的处理能力降低了,导致这个帧率降低。

单独开 Firefox 也是一样,帧率25左右,Chrome 帧率55。暂时放着吧,找不到原因。

确实如此,开发环境和楼主一样,碰到的问题也和楼主一样.
报错信息:
Cocos Creator v2.0.7 CCGame.js:398:8
Error: WebGL warning: texSubImage2D: Texture has not been initialized prior to a partial upload, forcing the browser to clear it. This may be slow. render-engine.js:8262:6
Error: WebGL warning: clear: Calling gl.clear(0) has no effect.
render-engine.js:9774:2
Error: WebGL: No further warnings will be reported for this WebGL context. (already reported 32 warnings) render-engine.js:9774:2