Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Programming and Hacking > Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 8th August 2018, 11:31   #1  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
SupMover - Shift timings and Screen Area of PGS/Sup subtitle

Out of desperation i've created this tool to shift the timming of BD subtitles in sup format and i've called it SupMover.

It doesn't do much cheeking of input file or the inputted parameters (yet, as i expected to not distribute it).

Here the repo https://github.com/MonoS/SupMover/

EDIT: after a couple of years i took the time to add some new functionality to this mine little utility, now it can resync subtitltes and crop the picture area without reencoding the picture data.

Last edited by MonoS; 20th September 2020 at 15:33. Reason: New version
MonoS is offline   Reply With Quote
Old 8th August 2018, 12:50   #2  |  Link
Ghitulescu
Registered User
 
Ghitulescu's Avatar
 
Join Date: Mar 2009
Location: Germany
Posts: 5,769
That is a very welcomed tool. To my knowledge the only one thus even more valuable.
__________________
Born in the USB (not USA)
Ghitulescu is offline   Reply With Quote
Old 8th August 2018, 13:21   #3  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
Quote:
Originally Posted by Ghitulescu View Post
That is a very welcomed tool. To my knowledge the only one thus even more valuable.
I've really spent TOO MUCH TIME searching a tool like this, the only one i found is BDSup2Sub but it reencodes the subpict and sometimes doesn't go well.

Alongside SECut from @Selur my tool is very useful, but i guess it should be trivial to include a cut mode in my tool without too much hassle.
MonoS is offline   Reply With Quote
Old 9th August 2018, 07:54   #4  |  Link
Ghitulescu
Registered User
 
Ghitulescu's Avatar
 
Join Date: Mar 2009
Location: Germany
Posts: 5,769
bdsub2sup has indeed some time manipulations but AFAIK it only can do fps conversions. It does not time-shifting (to take logos and stuff into account) nor stretching (other than fps conversions).
__________________
Born in the USB (not USA)
Ghitulescu is offline   Reply With Quote
Old 9th August 2018, 08:44   #5  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 2,308
If it's only a time shift you need, this also can be done in the container. If you're making an mkv, you can with mkvtoolnix for exemple, enter a timing shift for the subtitles. This is probably why you've never found a tool like this, because it can be done in another way. Of course, if your purpose is not an mkv, it's another story. And, also, the best way is indeed to shift the timing in the subtitles.
__________________
My github.
jpsdr is offline   Reply With Quote
Old 10th August 2018, 11:26   #6  |  Link
Ghitulescu
Registered User
 
Ghitulescu's Avatar
 
Join Date: Mar 2009
Location: Germany
Posts: 5,769
The trouble with each and every such PGS subtitle tools is that all of their authors are assaulted by hoards of people asking him to add more and more functions having little to do with the initial functionality - in this case to be able to process SRT, or ASS or whatever TXT based ones. It's what I call The Office Syndrome.
It is so difficult to find one PGS processing software, when all the developers are caught in endless discussions concerning exemplia gratia the dash before the second line of subtitles which should not appear in Hindu language, or whether the space before the question mark should be there or not.
__________________
Born in the USB (not USA)
Ghitulescu is offline   Reply With Quote
Old 12th August 2023, 04:52   #7  |  Link
wswartzendruber
hlg-tools Maintainer
 
wswartzendruber's Avatar
 
Join Date: Feb 2008
Posts: 412
Quote:
Originally Posted by Ghitulescu View Post
The trouble with each and every such PGS subtitle tools is that all of their authors are assaulted by hoards of people asking him to add more and more functions having little to do with the initial functionality - in this case to be able to process SRT, or ASS or whatever TXT based ones. It's what I call The Office Syndrome.
It is so difficult to find one PGS processing software, when all the developers are caught in endless discussions concerning exemplia gratia the dash before the second line of subtitles which should not appear in Hindu language, or whether the space before the question mark should be there or not.
That's precisely why I'm focusing on a .NET library only.
wswartzendruber is offline   Reply With Quote
Old 10th August 2018, 13:45   #8  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
Quote:
Originally Posted by jpsdr View Post
If it's only a time shift you need, this also can be done in the container. If you're making an mkv, you can with mkvtoolnix for exemple, enter a timing shift for the subtitles. This is probably why you've never found a tool like this, because it can be done in another way. Of course, if your purpose is not an mkv, it's another story. And, also, the best way is indeed to shift the timing in the subtitles.
My problem was to cut the subtitle at different point, so with some gaps, and then merge them together, i tried with mkvmerge but the resulting subtitle had some issues with the timings, retiming the single part and then merging them resulted in a perfect stream.

Quote:
Originally Posted by Ghitulescu View Post
The trouble with each and every such PGS subtitle tools is that all of their authors are assaulted by hoards of people asking him to add more and more functions having little to do with the initial functionality - in this case to be able to process SRT, or ASS or whatever TXT based ones. It's what I call The Office Syndrome.
It is so difficult to find one PGS processing software, when all the developers are caught in endless discussions concerning exemplia gratia the dash before the second line of subtitles which should not appear in Hindu language, or whether the space before the question mark should be there or not.
If i will ever add other functionality to this tool would be the ability to cut or change framerate that i expect to not be *THAT DIFFICULT*
MonoS is offline   Reply With Quote
Old 20th September 2020, 15:32   #9  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
I've published a new version that i think can improve the quality of converted subtitle when used in cropped encodes without re-encoding the image inside the subtitle.
I've also added the ability to resync all times by a factor like a lot of other programs.
MonoS is offline   Reply With Quote
Old 4th October 2020, 16:21   #10  |  Link
ScarAce1989
Banned
 
Join Date: Sep 2014
Location: https://t.me/pump_upp
Posts: 16
Can you add an option to only move a selection of subtitles instead of all subtitles?
ScarAce1989 is offline   Reply With Quote
Old 25th October 2020, 10:48   #11  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
Quote:
Originally Posted by ScarAce1989 View Post
Can you add an option to only move a selection of subtitles instead of all subtitles?
It would be useful also for me as i do a lot of cut, delay and then merge of subtitles, but i don't have the time right now and i think will complicate the command line interface quite a bit

You can emulate this functionality using secut, supmover and mkvtoolnix with something like this
Code:
secut filename:"eng1.sup" cut:417-792 outfilename:"1-1.tmp.sup"
secut filename:"eng1.sup" cut:1251-1627 outfilename:"1-2.tmp.sup"
secut filename:"eng1.sup" cut:2085-2461 outfilename:"1-3.tmp.sup"
supmover "1-1.tmp.sup" "1-1.sup" -417
supmover "1-2.tmp.sup" "1-2.sup" -876
supmover "1-3.tmp.sup" "1-3.sup" -1335
mkvmerge.exe --output "1.eng.mks" "(" "1-1.sup" "1-2.sup" "1-3.sup" ")"
It is my intention to implement all those functionality inside my utility.

Last edited by MonoS; 23rd July 2023 at 16:14.
MonoS is offline   Reply With Quote
Old 15th December 2020, 00:27   #12  |  Link
ScarAce1989
Banned
 
Join Date: Sep 2014
Location: https://t.me/pump_upp
Posts: 16
Quote:
Originally Posted by MonoS View Post
It would be useful also for me as i do a lot of cut, delay and then merge of subtitles, but i don't have the time right now and i think will complicate the command line interface quite a bit

You can emulate this functionality using secut, supmover and mkvtoolnix with something like this
Code:
secut filename:"eng1.sup" cut:417-792 outfilename:"1-1.tmp.sup"
secut filename:"eng1.sup" cut:1251-1627 outfilename:"1-2.tmp.sup"
secut filename:"eng1.sup" cut:2085-2461 outfilename:"1-3.tmp.sup"
supmover "1-1.tmp.sup" "1-1.sup" -417
supmover "1-2.tmp.sup" "1-2.sup" -876
supmover "1-3.tmp.sup" "1-3.sup" -1335
C:/Users/MonoS/Desktop/Programmi/RipMux/mkvtoolnix/mkvmerge.exe --output "1.eng.mks" "(" "1-1.sup" "1-2.sup" "1-3.sup" ")"
It is my intention to implement all those functionality inside my utility.
Yes, that's all I need. That would be awesome!
ScarAce1989 is offline   Reply With Quote
Old 7th August 2023, 12:57   #13  |  Link
MonoS
Registered User
 
Join Date: Aug 2012
Posts: 203
Quote:
Originally Posted by ScarAce1989 View Post
Yes, that's all I need. That would be awesome!
Almost three years later, but i've implemented this functionality, still ion beta, but from my test it works fine
MonoS is offline   Reply With Quote
Old 28th October 2023, 19:39   #14  |  Link
Hellboy.
Registered User
 
Join Date: Mar 2020
Posts: 27
Just want to say thanks for this fantastic tool.
Hellboy. is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 10:47.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.