rebuilt with the sdk fix

This commit is contained in:
or-else
2022-03-23 17:32:08 -07:00
parent ae2d7a12ad
commit 60b52b342d
6 changed files with 11 additions and 11 deletions
+3 -3
View File
@@ -9707,7 +9707,7 @@ class AudioPlayer extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureComp
}; };
this.initAudio = this.initAudio.bind(this); this.initAudio = this.initAudio.bind(this);
this.initCanvas = this.initCanvas.bind(this); this.initCanvas = this.initCanvas.bind(this);
this.calcPreviewBars = this.calcPreviewBars.bind(this); this.resampleBars = this.resampleBars.bind(this);
this.visualize = this.visualize.bind(this); this.visualize = this.visualize.bind(this);
this.handlePlay = this.handlePlay.bind(this); this.handlePlay = this.handlePlay.bind(this);
this.handleSeek = this.handleSeek.bind(this); this.handleSeek = this.handleSeek.bind(this);
@@ -9780,7 +9780,7 @@ class AudioPlayer extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureComp
this.canvasRef.current.height = this.canvasRef.current.offsetHeight * CANVAS_UPSCALING; this.canvasRef.current.height = this.canvasRef.current.offsetHeight * CANVAS_UPSCALING;
this.canvasContext = this.canvasRef.current.getContext('2d'); this.canvasContext = this.canvasRef.current.getContext('2d');
this.canvasContext.lineCap = 'round'; this.canvasContext.lineCap = 'round';
this.viewBuffer = this.calcPreviewBars(this.state.preview); this.viewBuffer = this.resampleBars(this.state.preview);
this.visualize(); this.visualize();
} }
@@ -9838,7 +9838,7 @@ class AudioPlayer extends (react__WEBPACK_IMPORTED_MODULE_0___default().PureComp
drawFrame(); drawFrame();
} }
calcPreviewBars(original) { resampleBars(original) {
const barCount = Math.min(original.length, (this.canvasRef.current.width - SPACING) / (LINE_WIDTH + SPACING) | 0); const barCount = Math.min(original.length, (this.canvasRef.current.width - SPACING) / (LINE_WIDTH + SPACING) | 0);
const factor = original.length / barCount; const factor = original.length / barCount;
let amps = []; let amps = [];
+1 -1
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
+4 -4
View File
File diff suppressed because one or more lines are too long
+1 -1
View File
File diff suppressed because one or more lines are too long