Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for live streaming #90

Closed
SebastianSchildt opened this issue Mar 4, 2013 · 8 comments
Closed

Add support for live streaming #90

SebastianSchildt opened this issue Mar 4, 2013 · 8 comments

Comments

@SebastianSchildt
Copy link
Contributor

As far as I could see the current implementation for a video stream is "start it and wait until omxplayer is finished", however I think it would be useful to optionally specify a duration, in the case of continuous running livestreams:

Switch to the stream for 5 min, then go on to the next asset. As far as I could see omxplayer does not support this directly, but I guess spawning a shell process and doing a "sleep x; kill <omx_pid>" might do the trick just fine (killall omxplayer probably not a good idea, if omxplayer finishes, crashes before the timeout is reached you might accidentally kill another instance already playing the next asset.).

Maybe I will come around to do this myself later this month, however I just thought of putting it here, in case somebody picks it up before me :)

@vpetersson
Copy link
Contributor

I think we'd need to be a lot more careful in implementing such feature.

Have you tried streaming videos with omxplayer? I haven't tried yet, so I'm not sure it works.

@SebastianSchildt
Copy link
Contributor Author

Well I guess as with normal videos, omxplayer need to be spoon-fed with the right format, however I had a quick try with VLC today: I just took a h264 BigBuck Bunny and set the streaming assistant of vlc to share it via HTTP. When omxplayer was directed to the stream it just started playing at whatever position VLC was at the moment (there were the usual few distorted frames first, before hitting a new keyframe).

So basically omxplayer is capable of doing it. What exactly can be thrown at it might need some futher investigation

@vpetersson
Copy link
Contributor

Great. So that confirms that omxplayer can in fact stream video (assuming the format is right).

We'll go ahead and add this to the feature request list.

@Cyberprog
Copy link

Was discussing Screenly with a friend at the weekend, and he said he was looking for a system that could be configured for example to switch to a news tv feed at the top of each hour for 10mins or so, then go back to doing something else for the next 50 mins or so...

@xbmcnut
Copy link

xbmcnut commented Mar 3, 2015

+1. It seems setting the video length is currently not possible, even if you upload your own clip? (2015-02-25). I have the same issue with live streams; they work well but can't be timed. I also tried uploading my own MP4 at 133s and I can't set the video to play for anything less than the full length. Video timings do not seem to 'stick'.

@cole-seph
Copy link

+1
Would like to be able to loop videos at least in their entirety as setting a duration for them does not work.
Any way this could possibly be considered?

@vpetersson vpetersson changed the title Duration for Livestream Video assets Add support for live streaming May 3, 2016
@krzimmer
Copy link

krzimmer commented Jul 1, 2016

I was able to add an HLS stream asset. It plays properly with audio for mulitple hours, but continues playing even when the asset has been turned off. I agree that it would be nice to be able to turn the live stream off and continue to the next asset. However, this would be a great alernative to installating an IPTV set top box for displays that only play the same TV station 24/7.

@vpetersson
Copy link
Contributor

We've added a bounty here.

Here's what's required for acceptance:

  • Clear and documented code that follows PEP8
  • Should introduce a new duration setting for the live feed
  • Should support popular feeds in RTSP (rtsp://...) and RTMP (rtmp://...) and formats (these are the feeds supported by omxplayer according to this page)
    • This needs to be posted as proper
  • Should have tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants