Skip to content

Commit

Permalink
fix: Fade down was sending command in each loop in setInterval not re…
Browse files Browse the repository at this point in the history
…specting drivers dispatchResolution
  • Loading branch information
olzzon committed Jul 26, 2021
1 parent ece0623 commit 283cad0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions server/utils/MixerConnection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -531,12 +531,12 @@ export class MixerGenericConnection {
this.mixerTimers[mixerIndex].chTimer[channelIndex] = setInterval(() => {
outputLevel -= step
dispatchTrigger += step
this.mixerConnection[mixerIndex].updateFadeIOLevel(
channelIndex,
outputLevel
)

if (dispatchTrigger > dispatchResolution) {
this.mixerConnection[mixerIndex].updateFadeIOLevel(
channelIndex,
outputLevel
)

store.dispatch(
storeSetOutputLevel(mixerIndex, channelIndex, outputLevel)
)
Expand Down

0 comments on commit 283cad0

Please sign in to comment.