mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-06-05 16:24:10 +02:00
wip
This commit is contained in:
@@ -44,7 +44,7 @@ export class RoomController {
|
|||||||
this.worker.postMessage({ type: 'init', canvas: offscreen, roomState: this.roomState.value }, [offscreen]);
|
this.worker.postMessage({ type: 'init', canvas: offscreen, roomState: this.roomState.value }, [offscreen]);
|
||||||
this.isReady.value = true;
|
this.isReady.value = true;
|
||||||
} else {
|
} else {
|
||||||
const babylonEngine = new BABYLON.WebGPUEngine(canvas);
|
const babylonEngine = new BABYLON.WebGPUEngine(canvas, { doNotHandleContextLost: true });
|
||||||
babylonEngine.compatibilityMode = false;
|
babylonEngine.compatibilityMode = false;
|
||||||
await babylonEngine.initAsync();
|
await babylonEngine.initAsync();
|
||||||
this.engine = new RoomEngine(this.roomState.value, { canvas, engine: babylonEngine });
|
this.engine = new RoomEngine(this.roomState.value, { canvas, engine: babylonEngine });
|
||||||
|
|||||||
@@ -311,6 +311,7 @@ class ModelManager {
|
|||||||
}
|
}
|
||||||
merged.freezeWorldMatrix();
|
merged.freezeWorldMatrix();
|
||||||
merged.metadata = { ...this.root.metadata };
|
merged.metadata = { ...this.root.metadata };
|
||||||
|
if (!this.hasTexture) merged.convertToUnIndexedMesh();
|
||||||
this.bakedMeshes = [merged];
|
this.bakedMeshes = [merged];
|
||||||
|
|
||||||
this.bakedCallback?.([...this.bakedMeshes, ...excludeMeshes]);
|
this.bakedCallback?.([...this.bakedMeshes, ...excludeMeshes]);
|
||||||
@@ -757,6 +758,8 @@ export class RoomEngine extends EventEmitter<RoomEngineEvents> {
|
|||||||
this.emit('loadingProgress', { progress: loadedCount / objects.length });
|
this.emit('loadingProgress', { progress: loadedCount / objects.length });
|
||||||
})));
|
})));
|
||||||
|
|
||||||
|
this.scene.blockMaterialDirtyMechanism = true;
|
||||||
|
|
||||||
if (SNAPSHOT_RENDERING) {
|
if (SNAPSHOT_RENDERING) {
|
||||||
this.sr.enableSnapshotRendering();
|
this.sr.enableSnapshotRendering();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user