Re:Flv.js – An HTML5 Flash Video Player
by yoz-y on Thursday November 03, 2016 @11:57AM
(#12865083)
I wonder. Could something like this be packaged as an extension and thus enable javascript-powered codecs for browsers that do not have the full set? (webm for Safari comes to mind)
[ Parent
| on HN ]
Re:Flv.js – An HTML5 Flash Video Player
by lambda on Thursday November 03, 2016 @01:26PM
(#12866006)
This is a little different than codec support, though as other replies indicate, that can be done too. This is just demuxing the stream in one format, re-muxing it in a different format, and feeding it into <video> to actually do the decoding and playback.
On the other hand, something like https://github.com/brion/ogv.js/ is actually doing all of the decoding and playback in JavaScript/asm.js, using C libraries compiled with Emscripten.
Anyhow, yes, it probably would be possible to package up extensions that would apply one of these automatically to <video> tags with unsupported codecs or container formats. It's just a simple matter of programming.
Re:Flv.js – An HTML5 Flash Video Player
by douglasfshearer on Thursday November 03, 2016 @12:09PM
(#12865199)
A similar idea, HLS.js [0], allows playback of HLS on platforms that do not support it natively. Open-sourced by Dailymotion, it is used by The NYTime [1] amongst others to reduce the number of video renditions they have to produce for each video.
[0] https://github.com/dailymotion/hls.js
[1] http://open.blogs.nytimes.com/2016/02/08/flash-free-video-in...
Re:Flv.js – An HTML5 Flash Video Player
by TD-Linux on Thursday November 03, 2016 @12:08PM
(#12865187)
Yes, in fact it's even deployed on Wikipedia: https://github.com/brion/ogv.js/
Re:Flv.js – An HTML5 Flash Video Player
by dasil003 on Thursday November 03, 2016 @12:46PM
(#12865609)
Brion gave a talk about this just a few weeks ago: https://www.twitch.tv/demuxed/v/94956075
Re:Flv.js – An HTML5 Flash Video Player
by chris_wot on Thursday November 03, 2016 @12:31PM
(#12865439)
Seriously, the contributions of Brion Vibber to the world are completely undersung.
However, isn't this server side and not clientside?
Re:Flv.js – An HTML5 Flash Video Player
by TD-Linux on Thursday November 03, 2016 @12:46PM
(#12865611)
Nope, it's a clientside "polyfill of <video>", basically. Try out the demo in the page - it does all playback in Javascript and WebGL.
Re:Flv.js – An HTML5 Flash Video Player
by bytesandbots on Thursday November 03, 2016 @01:31PM
(#12866044)
Yes, it is possible. However, note that webm on safari will require transcoding vp8/vp9 into h.264. This is much more compute intensive than just transmuxing a flv (which has to be in h.264/aac) into another container (in this case fragmented mp4).
Here is an example of playing HEVC with this method: https://strukturag.github.io/libde265.js/
Re:Flv.js – An HTML5 Flash Video Player
by cpeterso on Thursday November 03, 2016 @03:38PM
(#12867232)
Broadway.js is Android's H.264 decoder compiled with Emscripten to JavaScript:
Or maybe even include the wasm codec/player along with the video. Then it doesn't matter what the platform supports as long as it can run wasm.