-
Notifications
You must be signed in to change notification settings - Fork 45
Casting
kawaii-player can work as client as well as server at the same time. This feature was exploited in the past to create peer-to-peer mode. Now this peer-to-peer mode has been extended in v3.5.0 to include master-slave design in order to incorporate PC-To-PC casting feature. Following are some important aspects of this feature.
* Casting of single file or entire playlist from one computer (Master)
to another computer (Slave) running kawaii-player.
* Automatic loading of subtitle (if subtitle name matches the file name)
* Ability to send external subtitle file from master to slave
* Ability to queue items
* Ability to open web interface of slave from internal browser of master,
which contains multiple other options to control playback activity on slave.
How to enable PC-To-PC casting feature?
* Install kawaii-player on two computers say master and slave.
* On master, enable master mode: Preferences->Other->PC To PC Casting->Master.
* On Slave, enable slave mode: Preferences->Other->PC To PC Casting->Slave
* Start media server on both.
* Select any playlist of master. From its contextmenu, start casting files
or playlist from master to slave. Users only need to setup slave address,
when it is prompted by the application, or they can change slave address
from contextmenu itself.
After following above steps, on Master, users will find new contextmenu as shown below from which they can cast items to other Slave computers running kawaii-player.
Above contextmenu has 'Show More Controls' option. This option will open up web interface of slave within master using internal browser. It will allow master to control other playback activities on slave. Following is a screenshot with qtwebengine as browser backend. If internal browser is not working as expected (most probably with qtwebkit backend) then users can open up web interface of slave using any external browser of choice.
For more details on PC-To-PC casting feature, refer the issue
From v3.6 onwards, kawaii-player will contain a separate slave control box, so that users don't have to open up web interface. Control box can be found at 'Preferences->Slave'.
The computer running kawaii-player can be used as youtube-casting or torrent-casting device. Users can directly send youtube video/playlist links using web interface to the application with the help of text commands mentioned in the Using Web Interface section, which will be then played using mpv/mplayer and youtube-dl. If the computer running the application is connected to TV then user can directly view the content on TV. Same is with torrent http/magnet links. Users can preserve everything which has been played into local playlist. Users need to enable remote-control mode to use these features, without which everything you click might start playing in the browser if it's html5 compatible. The playing instance can be easily controlled using web-based remote.
Explanation for some casting commands:
-
yt: command: First users have to select some playlist using web interface and then this command will send some url which will be then saved to that playlist. Users then have to click on the playlist entry manually to make it play on the server.
-
torrent: command: First select Torrent section from web interface, then this command will send torrent http/magnet link to the application. Users then have to go to Torrent->History section and click on the required item to make it start playing.
-
ytq: command: (Available in version 2.8+ onwards) Users can send any ytdl supported link/direct link or torrent magnet/http link to the application, which will be then played instantly without asking anything.
About casting extensions:
Experimental casting extension is available for both firefox and chromium here. This extension will add icon and context menu for casting to kawaii-player. Users just have to setup server ip address initially by clicking on the extension icon. After that users are free to go anywhere on the web and then they can cast supported links (including torrent magnet links) directly to the kawaii-player using either context menu or top icon. Therefore, users don’t have to enter text commands manually for casting. Playback of the video can be controlled using web interface.