File tree Expand file tree Collapse file tree 3 files changed +3
-3
lines changed
Expand file tree Collapse file tree 3 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -38,7 +38,7 @@ export class NgtsMeshDistortMaterial {
3838 inject ( DestroyRef ) . onDestroy ( ( ) => this . material . dispose ( ) ) ;
3939
4040 injectBeforeRender ( ( { clock } ) => {
41- this . material . time = clock . getElapsedTime ( ) * this . speed ( ) ;
41+ this . material . time = clock . elapsedTime * this . speed ( ) ;
4242 } ) ;
4343 }
4444}
Original file line number Diff line number Diff line change @@ -185,7 +185,7 @@ export class NgtsMeshTransmissionMaterial {
185185 this . side ( ) ,
186186 ] ;
187187
188- material . time = clock . getElapsedTime ( ) ;
188+ material . time = clock . elapsedTime ;
189189 // Render only if the buffer matches the built-in and no transmission sampler is set
190190 // @ts -expect-error - we know material.buffer is not just undefined | null
191191 if ( material . buffer === fboMain . texture && ! transmissionSampler ) {
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ export class NgtsFloat {
6868
6969 const container = this . floatRef ( ) . nativeElement ;
7070
71- const offsetTime = offset + clock . getElapsedTime ( ) ;
71+ const offsetTime = offset + clock . elapsedTime ;
7272 container . rotation . x = ( Math . cos ( ( offsetTime / 4 ) * speed ) / 8 ) * rotationIntensity ;
7373 container . rotation . y = ( Math . sin ( ( offsetTime / 4 ) * speed ) / 8 ) * rotationIntensity ;
7474 container . rotation . z = ( Math . sin ( ( offsetTime / 4 ) * speed ) / 20 ) * rotationIntensity ;
You can’t perform that action at this time.
0 commit comments