官网教程:https://www.pixijs.com/tutorials
教程:https://github.com/kittykatattack/learningPixi
1、谷歌浏览器打开html文件,报错ncaught Error: WebGL unsupported in this browser
解决:
1、谷歌浏览器开启硬件加速,重启谷歌浏览器。(有些软件使用时会特意关闭谷歌的硬件加速,例如使用obs窗口截取谷歌浏览器)
2、改用火狐浏览器 或者 Microsoft Edge浏览器
参考:https://github.com/pixijs/pixi.js/issues/5694
2、图片资源不显示,报错from origin 'null' has been blocked by CORS policy: Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https.
解决:
使用http-server命令开启本地服务器,不要直接双击打开html文件,用本地服务器为域名,网址的方式来访问index.html