Remove unnecessary onBeforeRender assignment in configureFogVolumeMesh methods

This commit is contained in:
2026-04-07 11:20:30 +02:00
parent 55290572e0
commit 4238bce5f5
4 changed files with 0 additions and 4 deletions

View File

@@ -399,7 +399,6 @@ export class RuntimeHost {
configureFogVolumeMesh(mesh, materials) {
const fogMaterials = materials.filter((material) => material instanceof ShaderMaterial && material.uniforms["localCameraPosition"] !== undefined);
if (fogMaterials.length === 0) {
mesh.onBeforeRender = null;
return;
}
mesh.onBeforeRender = (_renderer, _scene, camera) => {

View File

@@ -592,7 +592,6 @@ export class RuntimeHost {
);
if (fogMaterials.length === 0) {
mesh.onBeforeRender = null;
return;
}

View File

@@ -1738,7 +1738,6 @@ export class ViewportHost {
configureFogVolumeMesh(mesh, materials) {
const fogMaterials = materials.filter((material) => material instanceof ShaderMaterial && material.uniforms["localCameraPosition"] !== undefined);
if (fogMaterials.length === 0) {
mesh.onBeforeRender = null;
return;
}
mesh.onBeforeRender = (_renderer, _scene, camera) => {

View File

@@ -2363,7 +2363,6 @@ export class ViewportHost {
);
if (fogMaterials.length === 0) {
mesh.onBeforeRender = null;
return;
}