Using JSMpeg (https://github.com/phoboslab/jsmpeg) the video playback is a bit smooth with Firefox but with Chrome the audio is delayed. See this demo: https://cycdpo.github.io/jsmpeg-player/
What are the possible reasons that a browser will cause delayed audio when playing videos with Javascript?
I don't suppose it's network latency:
Here's my local setup:
var player = new JSMpeg.Player('assets/video.ts', {
canvas: canvas,
progressive: true,
maxAudioLag: 0,
videoBufferSize: 1024*1024,
audioBufferSize: 1024*1024,
throttled: false,
disableGl: true,
disableWebAssembly: true,
autoplay: true
});