diff options
Diffstat (limited to 'video_player/README.md')
-rw-r--r-- | video_player/README.md | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/video_player/README.md b/video_player/README.md new file mode 100644 index 0000000..68697d9 --- /dev/null +++ b/video_player/README.md @@ -0,0 +1,58 @@ +# QuickMedia Video Player +The video player internally used by QuickMedia. Uses libmpv.\ +The video player window is embedded inside QuickMedia and QuickMedia and this video player communicate over a file descriptor (socketpair) using json (json without newline formatting; one command per line). +# IPC commands +## time-pos +Return seeking position in file in seconds +### request +``` +{ + "command": "time-pos" +} +``` +### response on success +``` +{ + "status": "success", + "data": 112.432 +} +``` +### response on error +``` +{ + "status": "error", + "message": "error message" +} +``` +## sub-add +Add a subtitle file/url that is loaded asynchronously +### request +``` +{ + "command": "sub-add", + "data": { + "file": "path/to/file/or/url", + "title": "title", // Optional + "language": "en_us" // Optional + } +} +``` +### response on success +``` +{ + "status": "success" +} +``` +### response on error +``` +{ + "status": "error", + "message": "error message" +} +``` +# IPC event +``` +{ + "name": "file-loaded" +} +```
\ No newline at end of file |