News for hackers. Stuff that matters.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by vhiremath4 on Wednesday June 01, 2016 @02:16PM (#11816809)
"but for ease of reading we refer to NGINX Plus throughout"

Uhuh. Suuuure. :p

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @05:19PM (#11818246)
I also would hesitate to call it "Live" without showing how to adjust for GOP sizes, key frames, B and I frames, etc.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @01:36PM (#11816431)
The one thing I've always wanted from nginx-rtmp was the ability to pull from a source input instead of running a separate process with ffmpeg to push the stream over. If they could get that working my life would become less complicated quickly.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jc4p on Wednesday June 01, 2016 @01:54PM (#11816622)
yeah I use nginx-rtmp for local video capturing (basically the functionality of a mirror) and the lag that needing to re-encode + chunk + starting off at the beginning of the chunks in the playlist introduces is meh. I think I'm going to transition my project over to WebRTC though, since the mobile device I'm using to display the video can handle that now.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by rawnlq on Wednesday June 01, 2016 @10:39PM (#11819991)
iOS still doesn't support webrtc...
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jc4p on Thursday June 02, 2016 @01:45AM (#11820615)
Neither does a lot of Android! Luckily the product I'm using uses https://crosswalk-project.org/ -- that sounded like an ad!
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by nickysielicki on Wednesday June 01, 2016 @04:05PM (#11817694)
> [I'd prefer] the ability to pull from a source input instead of running a separate process with ffmpeg to push the stream over.

Could you elaborate on this? I don't understand what you mean by 'push' and 'pull' in this context.

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @04:58PM (#11818113)
Currently to get the stream from ffmpeg into nginx you have to do the following: ffmpeg -re -i input_file -c copy -f flv rtmp://nginx_server_url:1935/app

It would be nice to have the ability to set up an app block that looked kind of like this

application source1 { exec fffmpeg -f decklink -i 'DeckLink Quad (1)@8' -f flv rtmp://localhost/app/$name }

ffmpeg is still pushing the stream to nginx, but nginx is in charge of starting that process.

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by benwilber0 on Wednesday June 01, 2016 @05:23PM (#11818283)
I think you might be looking for the exec_pull (or exex_static) directive

https://github.com/arut/nginx-rtmp-module/wiki/Directives#ex...

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @05:27PM (#11818319)
I've tried, and it doesn't work so well. I don't think it works for every OS either.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by rhizome on Wednesday June 01, 2016 @05:25PM (#11818295)
Is there an advantage that an nginx process like that has over streaming servers like liquidsoap?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @05:35PM (#11818389)
liquidsoap is audio only right?

Most streaming servers are bloated and slow. If nginx can do for video streaming what they've done for web servers it would be great.

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by vertex-four on Wednesday June 01, 2016 @05:58PM (#11818573)
Nope, liquidsoap does video. http://liquidsoap.fm/doc-svn/video.html
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by alexcroox on Wednesday June 01, 2016 @01:06PM (#11816123)
I wish there was a decent HTML5 low latency (< 2s) solution. Nothing comes close to RTMP + Flash still.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by dmm on Wednesday June 01, 2016 @01:26PM (#11816313)
The scalability of DASH/HLS comes from the fact that the video segments are just static files sitting on a http server so they can be cached and distributed with the many techniques for serving static files over http.

If you don't need the scalability of DASH/HLS you can use the WebRTC apis for low latency streaming, usually <1s. WebRTC can be used for client-server applications just as easily as peer-to-peer using a gateway like Janus[1].

[1] https://janus.conf.meetecho.com/

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by alexcroox on Wednesday June 01, 2016 @02:40PM (#11817020)
Yer I've looked into WebRTC before but the browser support isn't good enough yet :(
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by dmm on Wednesday June 01, 2016 @05:45PM (#11818480)
What browser doesn't support WebRTC but does support flash/RTMP ?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by alexcroox on Wednesday June 01, 2016 @05:48PM (#11818508)
Internet Explorer 9, 10, 11...
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @01:52PM (#11816606)
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by alexcroox on Thursday June 02, 2016 @11:15AM (#11823108)
Not using browsers, those experiments were done using the MP4Client as a client
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by benwilber0 on Wednesday June 01, 2016 @01:20PM (#11816252)
HD RTMP to the client is extremely difficult to scale without an enormous investment in infrastructure. AFAIK BAM/MLB.TV are the only ones doing it.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by wrigby on Wednesday June 01, 2016 @04:40PM (#11817971)
Abusing WebRTC can be a viable option in latency-critical applications, but it brings a bunch of other concerns with it (browser support, no way to leverage a CDN, etc).
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by aleksanb on Wednesday June 01, 2016 @12:41PM (#11815880)
The setup seems rather similar to https://github.com/arut/nginx-rtmp-module which I've used in the past. Perhaps they've bundled it with Nginx Plus without crediting the original authors? The project has a bit too permissive license for my taste.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by benwilber0 on Wednesday June 01, 2016 @01:18PM (#11816223)
Roman Arutyunyan is (or was previously) an engineer at nginx when he developed nginx-rtmp.

https://www.youtube.com/watch?v=1boJWioxsWc

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by gshulegaard on Wednesday June 01, 2016 @02:36PM (#11816984)
I work at Nginx, although not on the core development team, and to the best of my knowledge Roman Arutyunyan is still an engineer with us.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by rch on Wednesday June 01, 2016 @01:01PM (#11816075)
> Both NGINX and NGINX Plus support the features we’re discussing
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by schellkenig on Wednesday June 01, 2016 @03:22PM (#11817358)
But the nginx-rtmp-module does not support DASH with ABR to the best of my knowledge. Seems to be still an open issue https://github.com/arut/nginx-rtmp-module/issues/480
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by callmeed on Wednesday June 01, 2016 @01:20PM (#11816255)
This looks cool. I'm very interested in live video but can someone enlighten me on the creation side of this equation?

How do I create an RTMP stream in the first place?

What camera can/should I use? Can I use webcam? Is there an iOS app that can do it?

What hardware/software is needed to create this RTMP stream that I'll be pushing to nginx?

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by benwilber0 on Wednesday June 01, 2016 @01:24PM (#11816295)
Streamers typically use something like [1] OBS, or [2] FMLE to stream their desktop or webcam to an RTMP ingest server like Twitch, Youtube, Streamup, Streamboat.tv, etc. Can even just use ffmpeg.

[1] https://obsproject.com/

[2] http://www.adobe.com/products/flash-media-encoder.html

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by dylz on Wednesday June 01, 2016 @01:22PM (#11816279)
ffmpeg, vlc, OBS Studio (this one is probably easiest; you can just add an image or add a webcam source etc then configure a rtmp url to push to)
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by ericcholis on Wednesday June 01, 2016 @01:34PM (#11816404)
Wirecast from Telestream is a good paid option as well.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jacquesm on Thursday June 02, 2016 @02:40AM (#11820773)
Wowza is another one. It scales very well.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by nickysielicki on Wednesday June 01, 2016 @04:02PM (#11817667)
Lots of people in here commenting about nginx plus, but can anyone recommend a free alternative to BITMOVIN?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by corobo on Wednesday June 01, 2016 @05:14PM (#11818212)
I had the same wonder and through some digging found videojs-contrib-dash[1] which uses dash.js, referenced on the bitmovin site[2]. I'm going to give this a go and see what does and doesn't work.

[1] https://github.com/videojs/videojs-contrib-dash

[2] https://bitmovin.com/mpeg-dash-open-source-player-tools/

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by hayksaakian on Wednesday June 01, 2016 @04:06PM (#11817708)
video.js with the HLS plugin is fine if you don't need dash (there may be flash) but obviously that's very bare bones. It seems like there's things like ad support among other features you get with the suggested player.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jordanbaucke on Wednesday June 01, 2016 @02:03PM (#11816700)
Anyone have any insight on RTMP + HLS / MPEG-DASH -> WebRTC? Ala www.beam.pro (what they call FTL)?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by NEDM64 on Wednesday June 01, 2016 @01:23PM (#11816290)
Is there a way to mux subtitles written on the fly?

For example, I want to mux a subtitle stream, with the real time clock in it, into a video stream.

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by kalimoxto on Wednesday June 01, 2016 @01:30PM (#11816360)
ffmpeg can do that fairly easily. To adjust the command in the example, you need to to take the srt file and pass it as a second -i input file. There's some helpful guides on how to do that if you search around.

e.g. https://en.wikibooks.org/wiki/FFMPEG_An_Intermediate_Guide/s...

Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by NEDM64 on Wednesday June 01, 2016 @03:00PM (#11817192)
But I don't have a subtitles file. I would need it to read from a stream, not a static file.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by nitrogen on Wednesday June 01, 2016 @04:18PM (#11817782)
Try having it read from a fifo instead.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by NEDM64 on Saturday June 04, 2016 @11:04AM (#11836564)
But how? I've searched the documentation.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by mountaineer22 on Wednesday June 01, 2016 @12:36PM (#11815820)
How does this compare to Wowza?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by bcryptd on Wednesday June 01, 2016 @01:28PM (#11816338)
It's not running on Java so it should be faster with the same hardware.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jacquesm on Thursday June 02, 2016 @02:41AM (#11820777)
There may be a lot to complain about with Java but it is insanely efficient when it comes to serving data out a network port. Wowza will scale well beyond most companies' needs, I've used their stuff for years and it is the one program that convinced me that Java actually can be very efficient for applications like these.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by benwilber0 on Wednesday June 01, 2016 @01:28PM (#11816335)
basically the same. I find nginx + ffmpeg to be easier and simpler than deploying Wowza. As well as free-er.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by kasparsklavins on Thursday June 02, 2016 @02:19AM (#11820702)
Working on a similar product but using peer to peer live video streaming. Since the data does not touch the server, there are no scaling problems.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by slederer on Thursday June 02, 2016 @03:25AM (#11820906)
There are a couple of cool P2P companies out there like http://www.streamroot.io/ or https://www.peer5.com/
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by corobo on Thursday June 02, 2016 @07:04AM (#11821584)
Who's the target market? I think I'm a bit jaded as my first thought was this would open up the streamer to get DDoSed every time they try to stream
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by jacquesm on Thursday June 02, 2016 @02:36AM (#11820760)
One-to-many or one-to-one?
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by kasparsklavins on Thursday June 02, 2016 @03:52AM (#11820990)
one to many
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by newman314 on Wednesday June 01, 2016 @04:12PM (#11817751)
FYI. The rtmp module broke recently with the recent nginx 1.11.0 release.
Re:Scalable Live Video Streaming Using NGINX and MPEG-DASH/HLS by excalibur on Wednesday June 01, 2016 @01:20PM (#11816246)