From 6350890e9fe18088d702e1fd9f5f54ceec4475a7 Mon Sep 17 00:00:00 2001 From: syuilo <4439005+syuilo@users.noreply.github.com> Date: Thu, 16 Apr 2026 19:04:13 +0900 Subject: [PATCH] Update engine.ts --- packages/frontend/src/utility/room/engine.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/packages/frontend/src/utility/room/engine.ts b/packages/frontend/src/utility/room/engine.ts index 1b79d9bb01..5cc184f0f4 100644 --- a/packages/frontend/src/utility/room/engine.ts +++ b/packages/frontend/src/utility/room/engine.ts @@ -556,7 +556,9 @@ export class RoomEngine extends EventEmitter { this.engine = options.engine; this.scene = new BABYLON.Scene(this.engine); - this.scene.performancePriority = BABYLON.ScenePerformancePriority.Intermediate; + // なんかレンダリングがおかしくなるときがあるのでコメントアウト + // オブジェクトを選択し、後ろを向いて別のオブジェクトを選択した後、最初のオブジェクトに振り返ると消えているなど + //this.scene.performancePriority = BABYLON.ScenePerformancePriority.Intermediate; this.scene.autoClear = false; //this.scene.autoClearDepthAndStencil = false; this.scene.skipPointerMovePicking = true; @@ -646,6 +648,7 @@ export class RoomEngine extends EventEmitter { blurKernelSize: 64, }); gl.intensity = 0.5; + this.scene.setRenderingAutoClearDepthStencil(gl.renderingGroupId, false); if (SNAPSHOT_RENDERING) { this.sr.updateMeshesForEffectLayer(gl); @@ -739,6 +742,7 @@ export class RoomEngine extends EventEmitter { this.zGridPreviewPlane.isVisible = false; this.selectionOutlineLayer = new BABYLON.SelectionOutlineLayer('outliner', this.scene); + this.scene.setRenderingAutoClearDepthStencil(this.selectionOutlineLayer.renderingGroupId, false); if (SNAPSHOT_RENDERING) { this.sr.updateMeshesForEffectLayer(this.selectionOutlineLayer); }