HTTP streaming and external subtitle, looking for a solution
#1
Hi,

I want to stream movies through http links, example:

Code:
http://somedomain.com/lalalalala.mkv

The problem is how to set an external subtitle url?

Code:
http://somedomain.com/lalalalala.srt

Can I set both in a .m3u playlist? maybe .strm? Or only solution is to make a custom python plugin?

I've tested a simple .m3u with only the movie url, it is working very well, except the lack of subtitle and no resume point is stored.

I need a noob guidance.

Thank you.
I wish to have Rotten Tomatoes (user+critics) + IMDB both ratings display in skin.
Reply
#2
mux the sub into mkv?
Reply
#3
I have no access to all files for now and, enough bandwidth (upload) to update them, because they are stored remotely.

Python plugin is the only way? like the Youtube one.
I wish to have Rotten Tomatoes (user+critics) + IMDB both ratings display in skin.
Reply
#4
Go to http://pastebin.com/3cU514Sv

copy paste that text into autoexec.py and place it in userdata.

Also change name do your ip and/or your ip.

This is for https, you need to change that line to http as well.
Reply
#5
@marantz, Thank you!

Here is what I'm doing now, be free to laungh...

1) making a bogus/blank movie.title.bluray.180p.mkv in local media folder;
2) scraping the movie to database, run artwork downloader;
3) renaming the bogus file to same.name.m3u adding the streaming url;
4) in your script I'm adding if conditional for each media to point the right subtitle url, something like:

Code:
if "filename_here" in filename:
    xbmc.Player().setSubtitles('http://the_subtitle_url')

elif "other_media_filename" in filename:
    xbmc.Player().setSubtitles('http://other_media_subtitle_url')
.
.
.

(I need to use this way because the urls doesn't has the filename, its is something like domain.com/downloader?someidhere7687368833887 same for the subtitle, each one with an unique id. Headers redirects to direct filename on download though. Imagine a sharing url from gdrive, mine is similar, but from another provider)

Or instead to checking filename, using full url by playing_file.

5) I edit the movies sqlite database renaming files table, .mvk to .m3u.

Working quite fine..

The cons:

1) very boring editing the autoexec.py for each single media file;
2) no way to save watching progress (markers may work) or mark media as watched on end (doing it manually for now);
3) no media info on playing osd;

This is the better I can do for now, I have almost zero python knowledge.

Any quick suggestion to turn my life less painful is welcome.

Thank you guys!
I wish to have Rotten Tomatoes (user+critics) + IMDB both ratings display in skin.
Reply
#6
Don't use http then.
If I have helped you or increased your knowledge, click the 'thumbs up' button to give thanks :) (People with less than 20 posts won't see the "thumbs up" button.)
Reply
#7
At this point you're basically looking at writing some kind of add-on for further improvement. Many add-ons actually work this way, pulling data from HTTP, including support files (be it subtitles or something else), and putting it all together.
Reply
#8
Writing addon is out of my knowledge for now.

Instead to use the bogus .mkv file, I'm using .strm file with the http url inside. Now Kodi is scraping the movie automatically, I don't need to edit manually the SQLite database anymore.

But still not saving the watched progress properly.

After to partially watch a movie (on stop) it updates the File table adding the remote file url, something like:

Image

(#2)

Would amazing if you could simply to set the remote media url and the subtitle in .srtm file by some tag and specially Kodi to use the playlist.strm filename, so no need to add a new entry to the db. Maybe this can solve the progress watch status, it is saved correctly, I can see the "Resume from xx:xx" from item menu on library, but when I select this option Kodi just start playing from the begging.

What I said makes any sense? any dev to comment about upon?

Cloud/remote http hosting is being very popular nowadays, supporting it by a simple way would benefit many people.

thx
I wish to have Rotten Tomatoes (user+critics) + IMDB both ratings display in skin.
Reply

Logout Mark Read Team Forum Stats Members Help
HTTP streaming and external subtitle, looking for a solution0