-
Notifications
You must be signed in to change notification settings - Fork 42
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
Peerflix #8
Comments
to test:
set |
Yeah, I can't change |
The problem is that autosub is not intended to be used with the command line. Most users will simply start playback from a file explorer, so requiring them to set the media-title from the command line is a no-go. I'm not familiar with peerflix or the torrenting use case, so let me know if there's anything I can do to help. |
That would not be a requirement in the least, but rather a plus. You may stream a normal URL (by drag and drop) and the file name would be in Russian or complete gibberish, and
The idea is to fall back to the file title (or prioritize it, if it exists, through configuration), as opposed to the file name (as it is defined in its path). namely this https://mpv.io/manual/master/#options-force-media-title. $ mpv 'http://domain.stream/film/Маяк.2019.mkv'
# subliminal searches for english subtitles for Маяк.2019.mkv; fails.
$ mpv --force-media-title='the lighthouse (2019)' 'http://domain.stream/film/Маяк.2019.mkv'
# subliminal searches for english subtitles for the lighthouse (2019); successes. |
Yeah, retrieving it is trivial: the I remember using it at some point, but then reverting it because it didn't work in all cases ... |
Yes, it does not always exist using some protocols. |
If it does not exist it uses the filename instead: see https://mpv.io/manual/master/#command-interface-media-title. I just checked the reverting commit, and it seems the reason was because the subtitle filename is then saved as the media-title, which prevents the subtitles from being picked up by MPV. Subliminal unfortunately does not have an option to set a custom subtitle filename. |
Can Lua's OS package or something intervene? or since it's a bit of an edge case, force load subtitles to |
I guess it might be possible to do a check if media-title == filename, and if not to force load the media-title subtitles. |
Checking if there are subs with the same name as the |
If you’re using peerlix I suggest switching to the fork webtorrent-cli. No idea how, but it’s many times faster than any other torrent client for me. mpv-peerlix-hook should use it too, IMO. |
Thanks for saving me from peerflix. I've created an initial script for using it: webtorrent-peerflix-hook. It was a lot easier to write than the peerflix version (still needs work though). |
Referencing: noctuid/mpv-peerflix-hook#3
peerflix
does not display the file title properly (usuallyhttp://localhost:8888
or magnet link inmpv-peerflix-hook
's case), thus making it impossible forautosub
to download subs for said file.--force-media-title
can be used to mitigate this, butautosub
does not seem to use this forced media title. which outside of this use case, can be very helpful with other files and their subs.peerflix
/mpv-peerflix-hook
store the file in/tmp/torrent-stream
, but mpv useshttp://localhost:NNNN
to stream the file, how can one include these inlocal includes
array to automatically get subs?The text was updated successfully, but these errors were encountered: