Forum rules
Under no circumstances is spamming or advertising of any kind allowed. Do not post any abusive, obscene, vulgar, slanderous, hateful, threatening, sexually-orientated or any other material that may violate others security. Profanity or any kind of insolent behavior to other members (regardless of rank) will not be tolerated. Remember, what you don’t find offensive can be offensive to other members. Please treat each other with the kind of reverence you’d expect from other members.
Failure to comply with any of the above will result in users being banned without notice. If any further details are needed, contact: “The team” using the link at the bottom of the forum page. Thank you.
Penafo
Posts: 7
Joined: Mon Oct 03, 2016 6:21 pm

Have OSDownloader save subtitle file name matching video file name

Tue Oct 04, 2016 1:29 pm

When I tell OSDownloader to download a subtitle for
Chicago.Fire.S02E06.HDTV.x264-LOL.mp4
and it downloads the subtitle
Chicago.Fire.S02E06.HDTV.XviD-AFG.srt
(notice the different release on the filename) shouldn't the subtitle be saved with the same name as the movie file?
Last edited by SmallBrother on Tue Oct 04, 2016 4:04 pm, edited 1 time in total.

User avatar
SmallBrother
Site Admin
Posts: 3724
Joined: Sun Mar 04, 2012 12:59 pm
Location: Somewhere on this globe

Re: Have OSDownloader save subtitle file name matching video file name

Tue Oct 04, 2016 4:20 pm

By the way, using this post to ask another question.
Please, don't mix two different subjects in one topic. It makes it much more difficult for others to find an answer if they have the same question. And for admins it's 'kinda hell' to split one post in two pieces, make a new topic, copy/edit/move your post, etc. etc.
Next time :)
shouldn't the subtitle be saved with the same name as the movie file?
Yes and no ;-)

Many video players have least difficulty with using subtitles if the video file and the subtitle file have the same name. And this is probably what the uploader has done.

But many subs are not only matching that specific video file, but also other releases. Have a look at for example http://www.opensubtitles.org/en/subtitl ... yriding-nl . This subtitle is uploaded as a "LOL" subtitle (see the matching subtitle file name and release name), but it can be used for DIMENSION and AFG (and probably some more) as well.

By now, this subtitle has some additional hashcodes (not only for LOL, but also DIMENSION and AFG), so when your software searches for matching subtitles for your AFG video, it finds this LOL subtitle. And the same for AFG subs found when searching for DIMENSION, etc. etc.
Nowadays a VPN is a must for everyone. A VPN allows you safe surfing and protects you against spying governments and companies.
I advise AirVPN - from € 2,75 per month. Click the below banner for more info.


Image

Penafo
Posts: 7
Joined: Mon Oct 03, 2016 6:21 pm

Re: Have OSDownloader save subtitle file name matching video file name

Wed Oct 05, 2016 2:37 am

Sorry about that. Thanks for editing to a new topic and for the prompt reply.

I understand what you mean. But if I may add my 5 cents ... I think when someone downloads a subtitle, that file from that moment on for that person only has a local meaning. This is, the user doesn't care if it works with other releases he/she just wants the subtitle to work with the release he has.

I raised the issue because when you use SickBeard and go on to process the video file name to the flavour you like (mine is like "The Newsroom - 1x01 - We Just Decided To.mp4") if the subtitle file doesn't has the same name as the video file it won't be processed and later on won't be recognized on media players (WDTV won't show it, BS Player won't recognise it either).. making me later change all subtitles names one by one by hand.

Right now OSDownloader is not working for me (all files get stuck forever in the question mark icon), but during the 10 minutes it did work I tested it on a couple seasons and had to manualy rename the files so SickBeard could process them. Now I'm using a small program called Subtitles that downloads and renames the subtitle to the video filname and thus saving me the extra step in the process. (I'm assuming Subtitles changes the filename as I already used it with A LOT of files and the subtitle always ends with the same name as the video file)

Just mentioned this cause it would be easier on the user process flow... at least on mine: Download the video -> download the subtitle -> process Sickbeard -> Watch it on PC (BSPlayer) Phone/Tablet (Kodi) or TV (WDTVLive)

Cheers!

User avatar
SmallBrother
Site Admin
Posts: 3724
Joined: Sun Mar 04, 2012 12:59 pm
Location: Somewhere on this globe

Re: Have OSDownloader save subtitle file name matching video file name

Wed Oct 05, 2016 9:00 am

Aha, I understand what you are saying (I think). Basically you would want the subtitle file name to be the same as your video file at the moment you download it, and have it automatically changed if it doesn't match, right?

First of all, I see the advantage of that for your situation. But I also see a disadvantage.
I am using VLC player, which doesn't need matching filenames. You can just drag any subtitle file into the video pane, or choose the one you want from the subtitle menu. Usually I download a bunch of subtitle files, because, although technically 'matching', there could still be differences in synchronisation and/or translation. Like this, I can easily choose the best subtitle myself. If filenames would be the same as the video, I could only have one.

Secondly, I am pretty far from being an expert on API related stuff and software developing, but I think what you want needs to be done on your side, not on the server's side. And I think it should be an option for the user to choose. So the developer of your player/downloader should implement this option. All opensubtitles must and can do, is add something like "change file name to match video: yes/no" to the API.
Nowadays a VPN is a must for everyone. A VPN allows you safe surfing and protects you against spying governments and companies.
I advise AirVPN - from € 2,75 per month. Click the below banner for more info.


Image

Penafo
Posts: 7
Joined: Mon Oct 03, 2016 6:21 pm

Re: Have OSDownloader save subtitle file name matching video file name

Wed Oct 05, 2016 6:32 pm

Can't speak about VLC cause I've never used it before ... BSPlayer never let me down I guess.

Like a coin, any implementation has always two faces, pros and cons, like you I also sometimes find myself downloading a truck load of subtitles for a specific movie/series but in the end I just have to make sure it has exactly the same name as the video file to ease the work needed on the rest of the process.

Of course, the implementation of this would have be on the client side. And I'm talking more specificaly of the OSDownloader that is made by opensubtitles (isn't it?). Perhaps an option on OSDownloader that would allow users to chose the subtitle processing method? :) That software has a lot of potential for the user but sure needs more work put to it.

I'm just debating and suggesting cause i became a "Premium user" specifically to use the software... and as it stands I find the software "Subtitles" more efficient and time savind than OSDownloader for sure (not bitching about the money contribution I made tho... I'm a long Opensubtitles user so it was about time I showed some love :D).

User avatar
SmallBrother
Site Admin
Posts: 3724
Joined: Sun Mar 04, 2012 12:59 pm
Location: Somewhere on this globe

Re: Have OSDownloader save subtitle file name matching video file name

Wed Oct 05, 2016 8:26 pm

On behalf of those who deserve it: thanks for the love :)

As for your suggestion, I think it makes total sense and it would be an improvement if a user can choose how to handle the downloaded subs. But I am just a forum and subtitle mod, not a developer. So others would have to actually do it - if they want. So once again :) I moved this topic to the developing section, hoping that someone will pick it up...

[Edit]
And changed the subject
Nowadays a VPN is a must for everyone. A VPN allows you safe surfing and protects you against spying governments and companies.
I advise AirVPN - from € 2,75 per month. Click the below banner for more info.


Image

User avatar
hector
Posts: 370
Joined: Wed Jan 01, 2014 12:27 pm
Location: Spain

Re: Have OSDownloader save subtitle file name matching video file name

Wed Jan 25, 2017 2:58 pm

In my opinion subtitle file names are mostly crap and useless. I wrote a script to do something similar to what you are asking. Have a look:
viewtopic.php?f=8&t=5309&start=13

To change names automatically you have a command called "rename" at least in UNIX operating systems. Don't know if it can help.

Return to “Developing”

Who is online

Users browsing this forum: No registered users and 35 guests