MediaStreamRecorder icon indicating copy to clipboard operation
MediaStreamRecorder copied to clipboard

MultiStreamRecorder video/audio durations different/inconsistent

Open RobertLowe opened this issue 9 years ago • 4 comments

$ ffprobe -i ./some.webm -show_entries format=duration -v quiet -of csv="p=0" 3.003000 $ ffprobe -i ./some.wav -show_entries format=duration -v quiet -of csv="p=0" 2.986667

Slightly out of sync.

Any thoughts on how to align with ffmpeg?

May relate to #26

Cheers

RobertLowe avatar Nov 23 '15 00:11 RobertLowe

I found the same problem. I'm recording 20s chunk and on the ondataavailable event I'm uploading the chunks on a node server to merge and encode a final webm video via ffmpeg. I'm passing a bufferSize of 16384 to MultiStreamRecorder. I've noticed that audio and video have different durations (in the order of 300-500ms) and seem to be out of sync more and more with the increasing of the overall recording.

Is it only related to the large bufferSize or is there something wrong in the code of the recorder?

Thanks a lot for your work and for your reply

fabripeco avatar Dec 11 '15 15:12 fabripeco

Was this resolved? I seem to have this issue as well.

borabilgin avatar Jun 18 '16 03:06 borabilgin

I'm doing the same thing @fabripeco , but I'm not experiencing the same issue. Or I'll double check on my end.

noahjerreel avatar Jun 20 '16 07:06 noahjerreel

How are you merging files with ffmpeg? I can't even use ffmpeg as timing info is not added to webm files (using Chrome). I ended up using mkvmerge which concatenates the files but I'm also seeing sync issues between audio and video tracks.

borabilgin avatar Jun 20 '16 11:06 borabilgin