I am recording video by MediaRecorder in Chrome. My code is similar to an example from MediaStream docs. I am receiving videos that do not have Duration
metadata.
I compared it by mediainfo
with exemplary webm file from:
https://file-examples-com.github.io/uploads/2020/03/file_example_WEBM_480_900KB.webm
On the left, there are metadata of file recorded by MediaRecorder, on the right from the exemplary webm file.
Detailed comparison on DiffChecker
There are three key differences:
In the file from MediaRecorder:
- there is lacking
Duration
. - there is lacking
Bit rate
. - there is added
IsTruncated: Yes
.
In effect when I add this file to the video tag on website with controls attribute, then I can use controls only when file is displayed to the end.
I need to fix it and save non truncated files with this duration. Both frontend and backend solutions are accepted.