Skip to content

Playing content with media player app

Rafostar edited this page Sep 5, 2019 · 2 revisions

Play with Media Player App

If you do not have Chromecast, the content can be played using external media player application (e.g. MPV, VLC).

The main idea is that you have a PC with media files and another HTPC connected to TV (but it can also be a laptop or smartphone). Then you can select video on your main computer and play it on the other device (without connecting any additional cables) and the main PC will handle optional video conversion, so the other one can play it smoothly.

Playercast app

For easy streaming to other Linux running device, check out Playercast. It turns media player into Chromecast-like receiver for playing cast files and allows controlling playback over local network from GNOME Shell remote widget.

Where to get the stream

Direct link to selected content is: http://server_ip:port/cast

Where server_ip is the IP address of computer you are running this extension on and port is the port number selected in extension settings (default: 4000).

For example link might be: http://192.168.1.101:4000/cast

Tip: You can quickly try it out on your local computer (server) using "localhost" instead of IP address.

It is recommended to assign your PC a static IP address or custom hostname, then you will not have to check if IP has been changed.

Important Info

This method is not suited for playing in web browser. If you want to play video in browser use integrated web player. To do so provide the link without the word "cast" at the end.

Play using MPV

Video without external subtitles

Simply run mpv using command below (replace IP as needed):

mpv --no-ytdl http://192.168.1.101:4000/cast

Video with external subtitles

Choose subtitles by selecting video and pressing "Add Subtitles" button. Select and cast with your subs.

Play video with external subtitles by using command below.

mpv --no-ytdl http://192.168.1.101:4000/cast --sub-file=http://192.168.1.101:4000/subs

Important Info

The --no-ytdl is an important part. Because the link we provide is a direct link to the video stream, there is no need for youtube-dl to try and extract information from source site. Not only it reduces loading time greatly, but without adding it, playback may not start at all.