videojs / video.js

Video.js - open source HTML5 video player
https://videojs.com
Other
38.19k stars 7.47k forks source link

Choppy rtmp video live streanming from nginx to a Video.JS Flash player #1626

Closed vonsuppe closed 10 years ago

vonsuppe commented 10 years ago

Hi all,

I'm streaming live rtmp video from nginx to a Video.JS Flash player across the internet and see the video is consistently choppy.

I verified the delay is about 1 second from reality , and would like to be able to increase this buffer length time on the Video.JS player side to avoid this choppiness (i.e. add more buffering) via configuration. Something like the JWPlayer 'bufferlength' feature.

We asked this question in overstack.com to see if there's anyway to increase this buffer time:

http://stackoverflow.com/questions/26637251/buffer-length-setting-for-video-js-flash-plugin

and it appears they showed it was hardcoded to 1 second in the code:

https://github.com/videojs/video-js-swf/blob/6d262f5c9b6f1d919220201f0c1f0bc113a2271a/src/com/videojs/providers/RTMPVideoProvider.as#L421

So, is there anyway, we can have a configurable bufferlength so I can avoid the choppiness?

By the way, my Video.JS is added via Flash plugin like this:

<link rel="stylesheet" href="bower_components/videojs/dist/video-js/video-js.css">
<script src="bower_components/videojs-contrib-media-sources/src/videojs-media-sources.js"></script>

Thanks!

Henry

mmcc commented 10 years ago

Why are you adding the media-sources plugin? Either way, this belongs on the SWF repo, so would you mind opening this up over there?