File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed
Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -91,7 +91,7 @@ const compressFile = async (file: File) => {
9191
9292 // Display the final media file
9393 videoElement . style . display = '' ;
94- videoElement . src = URL . createObjectURL ( new Blob ( [ output . target . buffer ! ] ) ) ;
94+ videoElement . src = URL . createObjectURL ( new Blob ( [ output . target . buffer ! ] , { type : output . format . mimeType } ) ) ;
9595 void videoElement . play ( ) ;
9696
9797 compressionFacts . style . display = '' ;
Original file line number Diff line number Diff line change @@ -180,7 +180,7 @@ const generateVideo = async () => {
180180 videoInfo . style . display = '' ;
181181
182182 // Display and play the resulting media file
183- const videoBlob = new Blob ( [ output . target . buffer ! ] , { type : 'video/mp4' } ) ;
183+ const videoBlob = new Blob ( [ output . target . buffer ! ] , { type : output . format . mimeType } ) ;
184184 resultVideo . src = URL . createObjectURL ( videoBlob ) ;
185185 void resultVideo . play ( ) ;
186186
You can’t perform that action at this time.
0 commit comments