Using the browser API, I capture video (html5 .webm) and send fragments to a remote server. I am not particularly familiar with codecs, but it turns out that the first fragment is being played and the following ones are already gone. I understand that in the chunk there are not enough headlines. - Is it possible on the server side, using ffmpeg, to package the segment so that it becomes a full-fledged video file (and played)? - Will this operation be less costly compared with the operation of transcoding a file into flv and then sending it to rtmp?
mediaRecorder.ondataavailableit returns data from Blob and clears it. After that we take this fragment and send it to the remote server by any type of transport. On the server, these fragments (roughly) get the webm extension and are written to disk, being added in parallel to index.m3u8 (by analogy with hls and dash). But as already mentioned with this approach, the first piece is played, and the next one is not. So I think, maybe you can skip the fragment through ffmpeg on the server and make a full-fledged webm video file out of it? - Egor Mikheevffmpeg -i input.mp4 -c copy -map 0 -segment_time 8 -f segment output%03d.mp4- KoVadim