简体   繁体   English

Three.js:英特尔 Mac 上的巨大 Chrome 性能问题

[英]Three.js: Huge Chrome Performance Issue on Intel Macs

I have created a three.js based web application for showcasing 3d tiles.我创建了一个基于 three.js 的 web 应用程序来展示 3d 块。 You can find the showcase following this link:https://www.karak.at/workbench/dd6228117c6faec166b208710b5a52d5您可以通过以下链接找到展示柜:https://www.karak.at/workbench/dd6228117c6faec166b208710b5a52d5

How it works: an OBJ file is loaded and cloned multiple times using InstancedMesh to create a wall of tiles.工作原理:使用 InstancedMesh 多次加载和克隆 OBJ 文件以创建瓷砖墙。 Next one point- and one spotlight are added to the scene.接下来将一个点和一个聚光灯添加到场景中。 The light's positions react on the current mouse position. The scene is rerendered on mousemove.灯光的位置对当前鼠标 position 做出反应。场景在 mousemove 上重新渲染。

Rendering works super smooth in all browsers on M1 based Macs and on all browsers excpet Chrome on Intel based Macs.在基于 M1 的 Mac 上的所有浏览器和基于 Intel 的 Mac 上除 Chrome 之外的所有浏览器中,渲染都非常流畅。 Using Chrome version 98 on an Intel based Macs the computer is under heavy workload, fans go up, framerate drops and in worst case scenarios the app crashes.在基于 Intel 的 Mac 上使用 Chrome 版本 98,计算机工作负载很重,风扇 go 启动,帧率下降,在最坏的情况下,应用程序会崩溃。

Here are my renderer settings:这是我的渲染器设置:

    this.renderer = new THREE.WebGLRenderer({
        antialias: AA,
        powerPreference: "high-performance",
        depth: true,
        alpha: false,
        stencil: false
    });

Here is a Pen for showcasing the issue in an isolated environment: https://codepen.io/Huangart/pen/VwrVjpj这是一个用于在隔离环境中展示问题的 Pen: https://codepen.io/Huangart/pen/VwrVjpj

Is there something wrong on the implementation side of my app?我的应用程序的实施方面有问题吗? Is this a known issue?这是一个已知的问题? Any ideas on how to overcome this Chrome issue?关于如何克服这个 Chrome 问题的任何想法?

I was having this same issue on the same hardware.我在同一硬件上遇到了同样的问题。

I think that's related to this bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1245448我认为这与此错误有关: https://bugs.chromium.org/p/chromium/issues/detail?id=1245448

Changing the ANGLE graphics backend flag on about:flags to Metal improved the performance a lot on my machine.about:flags上的 ANGLE 图形后端标志更改为Metal ,大大提高了我机器上的性能。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM