Explorar o código

Merge pull request #8933 from Popov72/fix-pbr-ior-cloning

PBR: Fix wrong volumeIndexOfRefraction after cloning
Raanan Weber %!s(int64=5) %!d(string=hai) anos
pai
achega
36be1381f1
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      src/Materials/PBR/pbrSubSurfaceConfiguration.ts

+ 1 - 1
src/Materials/PBR/pbrSubSurfaceConfiguration.ts

@@ -154,6 +154,7 @@ export class PBRSubSurfaceConfiguration {
     @expandToProperty("_markAllSubMeshesAsTexturesDirty")
     public indexOfRefraction = 1.5;
 
+    @serialize()
     private _volumeIndexOfRefraction = -1.0;
 
     /**
@@ -163,7 +164,6 @@ export class PBRSubSurfaceConfiguration {
      * This ONLY impacts refraction. If not provided or given a non-valid value,
      * the volume will use the same IOR as the surface.
      */
-    @serialize()
     @expandToProperty("_markAllSubMeshesAsTexturesDirty")
     public get volumeIndexOfRefraction(): number {
         if (this._volumeIndexOfRefraction >= 1.0) {