mirror of
https://github.com/misskey-dev/misskey.git
synced 2026-06-04 00:44:22 +02:00
Update engine.ts
This commit is contained in:
@@ -36,7 +36,7 @@
|
|||||||
// TODO: 近くのオブジェクトの原点に軸を揃えるオプション
|
// TODO: 近くのオブジェクトの原点に軸を揃えるオプション
|
||||||
|
|
||||||
const BAKE_TRANSFORM = false; // 実験的
|
const BAKE_TRANSFORM = false; // 実験的
|
||||||
const SNAPSHOT_RENDERING = false; // 実験的
|
const SNAPSHOT_RENDERING = true; // 実験的
|
||||||
const SNAPSHOT_RENDERING_NON_SUPPORTED_OBJECTS = ['tv', 'aquarium', 'lavaLamp'];
|
const SNAPSHOT_RENDERING_NON_SUPPORTED_OBJECTS = ['tv', 'aquarium', 'lavaLamp'];
|
||||||
const IGNORE_OBJECTS: string[] = []; // for debug
|
const IGNORE_OBJECTS: string[] = []; // for debug
|
||||||
|
|
||||||
@@ -786,14 +786,21 @@ export class RoomEngine {
|
|||||||
});
|
});
|
||||||
|
|
||||||
if (SNAPSHOT_RENDERING) {
|
if (SNAPSHOT_RENDERING) {
|
||||||
window.setTimeout(() => {
|
const sr = new BABYLON.SnapshotRenderingHelper(this.scene);
|
||||||
this.engine.snapshotRendering = true;
|
|
||||||
this.engine.snapshotRenderingMode = BABYLON.Constants.SNAPSHOTRENDERING_FAST;
|
|
||||||
}, 3000);
|
|
||||||
|
|
||||||
window.setInterval(() => {
|
window.setTimeout(() => {
|
||||||
this.engine.snapshotRenderingReset();
|
sr.enableSnapshotRendering();
|
||||||
}, 10000);
|
|
||||||
|
if (USE_GLOW) {
|
||||||
|
const gl = new BABYLON.GlowLayer('glow', this.scene, {
|
||||||
|
//mainTextureFixedSize: 512,
|
||||||
|
blurKernelSize: 64,
|
||||||
|
});
|
||||||
|
gl.intensity = 0.5;
|
||||||
|
|
||||||
|
sr.updateMeshesForEffectLayer(gl);
|
||||||
|
}
|
||||||
|
}, 3000);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user