Skip to content

Commit fcf526d

Browse files
authored
MeshPhysicalMaterial: Update version for certain transmission changes. (#22379)
1 parent bd67e49 commit fcf526d

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

src/materials/MeshPhysicalMaterial.js

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@ import * as MathUtils from '../math/MathUtils.js';
3434

3535
class MeshPhysicalMaterial extends MeshStandardMaterial {
3636

37+
#transmission = 0;
38+
3739
constructor( parameters ) {
3840

3941
super();
@@ -88,6 +90,25 @@ class MeshPhysicalMaterial extends MeshStandardMaterial {
8890

8991
}
9092

93+
get transmission() {
94+
95+
return this.#transmission;
96+
97+
}
98+
99+
set transmission( value ) {
100+
101+
if ( this.#transmission > 0 !== value > 0 ) {
102+
103+
this.version ++;
104+
105+
}
106+
107+
this.#transmission = value;
108+
109+
}
110+
111+
91112
copy( source ) {
92113

93114
super.copy( source );

0 commit comments

Comments
 (0)