LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   I want to "push" video to a linux box hooked up to my tv (https://www.linuxquestions.org/questions/linux-software-2/i-want-to-push-video-to-a-linux-box-hooked-up-to-my-tv-885273/)

grizcreative 06-08-2011 03:51 PM

I want to "push" video to a linux box hooked up to my tv
 
I have scoured google, and these forums, and yet I cannot find what I am looking for.

What I basically want to do is have a linux box hooked up to my HD tv and be able to "push" a video or an audio file to it from another computer in the house.

Ultimately I would like to push to multiple boxes and have them play in sync. I want to control this without having to go the the individual box and control the playback from there.

Any way this is possible? Or is this just a pipe dream?

Thank you in advance.

Chromezero 06-08-2011 03:59 PM

Instead of trying to "push" the file, as you said. Why not just mount the remote drive using NFS, Samba, or something similar? Then on the Linux box, you'd just load up your file as if it were stored locally, and hit "play".

Nominal Animal 06-09-2011 03:09 PM

Quote:

Originally Posted by grizcreative (Post 4380294)
What I basically want to do is have a linux box hooked up to my HD tv and be able to "push" a video or an audio file to it from another computer in the house.

Most streaming solutions are "pull" oriented; i.e. you choose the media source on the playback box. The simplest method to do that is what Chromezero suggested: just share the media directories on the other computer(s), mount them on the Linux box, and the Linux box can then play all those files.

Quote:

Originally Posted by grizcreative (Post 4380294)
Ultimately I would like to push to multiple boxes and have them play in sync. I want to control this without having to go the the individual box and control the playback from there.

That's not a problem. You can control the playback remotely. For example, if you use VLC for playback on the Linux box, you can control it remotely using any browser, or by using a Telnet connection.

Quote:

Originally Posted by grizcreative (Post 4380294)
Any way this is possible? Or is this just a pipe dream?

It is quite possible, and it may even be easy; it all depends on how you wish to control it all.

First, make sure you have VLC installed on all your boxes. VLC is able to both broadcast a stream, and play broadcast streams. Here is the VLC Streaming Howto.

Since you may have multiple playback devices playing the same stream, you should always use a multicast address to "broadcast to" and "playback from", instead of their actual IP addresses. You should "allocate" at least one multicast address from 224.0.0.103 to 224.0.0.250 to each machine that can "push" media. Using a multicast address means the "pusher" will only send one data stream to all recipients; your network equipment (switches, routers) will split and direct a copy of the stream to each recipient automatically. This also means that each stream will use roughly the same bandwidth, regardless of the number of playback devices!

At this point, it's just a matter of telling each VLC instance involved what to do. You can use the WWW and Telnet interfaces built into VLC to remotely control each VLC, or the GUI to control VLC locally. I recommend checking out the VLC Play Howto, especially the Basic Use Interfaces section.

If you need to have a polished interface tailored to your own needs, I recommend installing Apache on an always-on Linux box, and writing some PHP or Python CGI scripts to control all this in one-click manner, using a browser on any of your machines. You could have a page for each "pusher" box that lists the media available on that box; clicking on one would open up a detail page, where you could tick the checkboxes corresponding to the playback devices you want to play that media. The listing would need at least one script; the detail page one; and the final "do it" needs one script to do the remote connections to make sure VLC is running and starts playback from the used "pusher". Although this needs a bit of an effort to set up, it would be pretty easy and efficient interface. It should work for any number of "pushers" and playback boxes, in any mix; and the configuration would be centralized on that machine, too.


All times are GMT -5. The time now is 06:57 PM.