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 > General > Subtitles

Reply
 
Thread Tools Search this Thread Display Modes
Old 17th July 2017, 10:32   #1361  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,063
Quote:
Originally Posted by Scorpius666 View Post
It is exactly that.

If you select the "Change Frame" option then you will need to enter a source frame rate and the program will translate the times for you. If you don't, the Target FPS is still used only for the formats that will use it.
It's almost true. The Target FPS is used anyway, regardless of the format of the input or output stream, but the stream is not stretched or shrunk. The only change is that the output timings are rounded so that they will coincide exactly with the frames of a movie at the specified target FPS. In other words, if you save the stream, it will still be more or less compatible with the original movie, but with imprecise time codes. And it will NOT be equal to the original. The difference might be negligible, but it exists. For example, a subtitle at 01:37:20.418 will be (slightly) moved to 01:37:20.400. A difference of 18ms is not much, but it exists. (You can see the rounded timecodes in the lower pane of BDSup2Sub.) It's why I suggest, when the stream is loaded, to set by default the same Target FPS than the source FPS (detected usually correctly, even when a format without FPS is loaded). That way, by default, the timings will never be changed. Plus, for the formats using the FPS (like XML/PNG), the correct value will be included. Currently, you have to pay attention to the Target FPS, without any good reason. Why keep this obligation if it can be avoided simply?

Quote:
Originally Posted by Scorpius666 View Post
But if you export to IDX/SUB for example that is totally ignored since it is not needed.
No, it's important to have the correct frame rate stored in the XML, because if you save it with, say, 25fps, when you will reload it, the program will wrongly assume that the FPS Source is 25. So, the current behaviour is misleading, unless you fix manually the little discrepancy of the wrong FPS Target in the first window.

Quote:
Originally Posted by Scorpius666 View Post
The question remains: Why is there a frame rate setting in the first place for formats that have absolute time? I'm pretty sure if you delete the frame rate line from the XML file it will always work. I would test it, but that format is so messy creating thousands of files that I really want to stay away from it.
IMO, it's an excellent thing to tag the stream with the frame rate. I agree that that should not influence the absolute times (except for the rounding to exact frame starts), but don't forget that a subtitle stream has no interest at all without a movie, and the movie has a specific frame rate. The timings for a PAL movie are totally different than for the same movie in NTSC, and again different for a film at 24fps. When the frame rate is included in the stream, you know for what target frame rate the stream has been designed. It's an extremely important information. Most sync problems peoples are experiencing with downloaded subtitles come from the absence of the frame rate in the SRT format. At least, with XML/PNG, that problem is avoided... if the frame rate stored in the XML is correct, of course.

Quote:
Originally Posted by Scorpius666 View Post
Also, the ONLY format that BDSup2Sub that needs a frame rate is XML/PNG. What I would do is test an XML file without the frame rate option, and if it works, then delete the output of that line in BDSup2Sub. I'm sure it will work!!
Yes, it will probably work, but please don't do that. Despite what you think about the XML/PNG format, it's certainly the more professional format supported by BDSup2Sub. It is extremely interesting to modify some things that you can't do with the GUI. I use it in BD3D2MK3D, for example, to convert the subtitles to 3D Half-SBS or Half-T&B. The presence of the frame rate tag in the XML is really useful to verify that the stream is compatible with the movie. Note also that XML/PNG is the format necessary for many authoring programs, like Sonic or Scenarist. You cannot simply say that it is useless because you don't like it.

However, I agree that it saves a lot of PNG files. And currently, it doesn't force the user to create a new directory to keep all these files together. Perhaps you could add (as an option?) the automatic creation of a sub-directory when the XML is saved? That way, you won't need to pay attention to where you save it. It's just a suggestion...

Quote:
Originally Posted by Scorpius666 View Post
EDIT: Reading the wiki at https://github.com/mjuhasz/BDSup2Sub...ported-Formats seems like not only the frame rate value is needed, but the values are not absolute values but things that are really weird, like the time codes are related an integer frame rate (24 instead of 23.976). I would really stay away from this format.
Oh, yes, I hate also the problem of the drop or non-drop frames with all NTSC frame rates, but it's an inheritance of the crappy NTSC Video format, and we have to live with that. (And, BTW, I don't understand at all why the US has forced the rest of the world to use the infamous 23.976 frame rate for HD and 3D movies, instead of the film standard of 24 fps, much more simple and without the drop frame nightmare! After all, we are in the 21st century, and keeping obscure limitations inherited from the frequency of the US AC at 110v is completely hallucinating!)

Also, if currently, most (if not all, I don't know) timings internal to video, audio and subtitles streams are expressed in absolute and precise times (for their real frame rate), it's not at all the same thing in production, where precise time codes are not handy. They HAVE to be rounded at 24 fps, because we are human beings, and not machines. The fact that XML/PNG permits to use drop or non-drop times is complex, but that means only that that format has been correctly designed with video production and human beings in mind. It's one of its obvious advantages over the other formats. I haven't tried to change the DropFrame="False" option in the XML, but I suppose that it is there to support both drop and non-drop frames timecodes. If it's the case, it should be possible to use exactly the same time codes in the XML than with the other formats.

Of course, when an XML/PNG file is saved at 24 or 25 fps (or any integer FPS), the drop frames problem is totally absent, and XML/PNG can be used very simply.
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 2nd October 2017 at 14:24. Reason: typo
r0lZ is offline   Reply With Quote
Old 17th July 2017, 10:57   #1362  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,063
Quote:
Originally Posted by Scorpius666 View Post
Now since SUP files from BDs and DVDs don't have a frame rate value, BDSup2Sub takes the default value you have for frame rate. If you haven't changed it, it's 25. But you can change it and press the "Store" button to set a new default.
The Store button doesn't work for me. The default FPS Target is always 25.

Quote:
Originally Posted by Scorpius666 View Post
Thanks to this wonderful thread I have found that versions of BDSup2Sup higher than 5.0.0 will lose 15% of the subtitles (totally unusable), but versions 5.0.0 and lower will only lose 1% if any.
So, if I understand correctly, your version is based on the code of v5.0.0. Right?

Are there other changes in later versions (except the problem of the missing subtitles) that have not been ported to your version, or is your version totally compatible with v5.1.2? I use v5.1.2 with BD3D2MK3D, and I would like to replace it with your version, but I don't want to risk some incompatibilities. Can you breifly summarize the changes that your version has not implemented, or direct me to the history of the changes of the old BDSup2Sub?
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 17th July 2017 at 11:04.
r0lZ is offline   Reply With Quote
Old 17th July 2017, 16:32   #1363  |  Link
Scorpius666
Registered User
 
Join Date: Jul 2017
Posts: 7
I based my version from 5.0.0. There are a lot of changes in later versions I guess, but those versions don't really work well. You would have to go to github and read each commit one by one after 5.0.0 to see what was implemented/fixed. They are a lot: https://github.com/mjuhasz/BDSup2Sub/commits/master

I tried to fix 5.1.2. I really tried. But it was so messy with so many errors that I picked the last version that worked (5.0.0) and started from there.

Also I'm wondering what's the use you guys have for this software. Nowadays you can mux a SUP file into an MKV container, so you don't really need to convert SUP to anything else. In my specific use case, I want my MKVs untouched for several reasons and the subtitles external. SUP files can't be external files, they only work when they are inside of a container like MKV. But if I wouldn't mind to modify my MKVs, I would just put the SUPs inside of them, and there wouldn't be a need for BDSup2Sub.

Last edited by Scorpius666; 17th July 2017 at 16:35.
Scorpius666 is offline   Reply With Quote
Old 17th July 2017, 18:43   #1364  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,063
Thanks for the link. I'll have a look...

I agree that untouched BD SUP muxed in MKV is the best solution... if your standalone player or TV supports that format.
Personally, as I wrote above, I distribute BDSup2Sub with BD3D2MK3D (a GUI to convert 3D BDs to SBS or T&B MKVs). It is necessary to convert the 2D subtitles to 3D. The resize and combinations of the 2 views with the correct offset can only be done on XML/PNG streams, hence my interest for that format. But XML/PNG is used only to compose the images of the final 3D stream, that is finally re-converted to BD or DVD SUP format.
BDSup2Sub is also used to extract the forced subtitles from the full stream. It's necessary for MKV, because most players are unable to dynamically display only the forced subs of a stream.
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 17th July 2017 at 18:50.
r0lZ is offline   Reply With Quote
Old 17th July 2017, 18:47   #1365  |  Link
QBhd
QB the Slayer
 
QBhd's Avatar
 
Join Date: Feb 2011
Location: Toronto
Posts: 409
My use for this software is pretty simple... when I remux BDs to MKV I only keep the subs for foreign/alien dialogue. And as we all know, many BD authors do different things to achieve this. I use this software to see what each sub track contains and see what is forced.

QB
__________________
QBhd is offline   Reply With Quote
Old 17th July 2017, 19:25   #1366  |  Link
Scorpius666
Registered User
 
Join Date: Jul 2017
Posts: 7
Quote:
Originally Posted by QBhd View Post
My use for this software is pretty simple... when I remux BDs to MKV I only keep the subs for foreign/alien dialogue. And as we all know, many BD authors do different things to achieve this. I use this software to see what each sub track contains and see what is forced.
You could use Subtitle Editor for that, but it has the same problem than the original BDSub2Sup: It misses several subtitles when importing from a SUP file.

Quote:
Originally Posted by r0lZ View Post
Thanks for the link. I'll have a look...

I agree that untouched BD SUP muxed in MKV is the best solution... if your standalone player or TV supports that format.
Personally, as I wrote above, I distribute BDSup2Sub with BD3D2MK3D (a GUI to convert 3D BDs to SBS or T&B MKVs). It is necessary to convert the 2D subtitles to 3D. The resize and combinations of the 2 views with the correct offset can only be done on XML/PNG streams, hence my interest for that format. But XML/PNG is used only to compose the images of the final 3D stream, that is finally re-converted to BD or DVD SUP format.
BDSup2Sub is also used to extract the forced subtitles from the full stream. It's necessary for MKV, because most players are unable to dynamically display only the forced subs of a stream.
Haven't you thought about writing your own SUP parser inside BD3D2MK3D? It's very simple, and I posted a link some posts ago with the format specifications.
Scorpius666 is offline   Reply With Quote
Old 18th July 2017, 07:59   #1367  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,063
Quote:
Originally Posted by Scorpius666 View Post
Haven't you thought about writing your own SUP parser inside BD3D2MK3D? It's very simple, and I posted a link some posts ago with the format specifications.
Oh, well, perhaps I'll do it, but I don't want to re-invent the wheel. BD3D2MK3D is essentially a GUI, and it uses already a lot of free tools, including BDSup2Sub. Why should I replace it with my own code and not, say, tsMuxeR, Mkvmerge, FRIMSource or x264, also necessary?
But I agree that currently, the conversion to 3D is slow and may be faster if I write the parsing combined with the conversion to 3D myself. However, I'm not sure it is worth doing it. The 3D is slowly dying, BD3D2MK3D is mature and stable, and I don't have the intention to modify it deeply any more.

But perhaps YOU are interested in adding the conversion to 3D inside BDSup2Sub ? If it's the case, I can help you. I know how the images must be combined, how to retrieve the 3D offsets from the so called 3D-Planes (or from the SEI messages of the MVC video stream), and the resize of the bitmaps is already present in BDSup2Sub. IMO, that could be a valuable addition to BDSup2Sub, as currently, as far as I know, there is no subtitle editor or converter that is able to convert the subtitles to 3D, at least with the correct 3D offsets from the original BD. If you're interested, just let me know...
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 18th July 2017 at 08:05.
r0lZ is offline   Reply With Quote
Old 29th July 2017, 17:02   #1368  |  Link
Bandits
Registered User
 
Join Date: Feb 2015
Posts: 15
Quote:
Originally Posted by Scorpius666 View Post
Also I'm wondering what's the use you guys have for this software. Nowadays you can mux a SUP file into an MKV container, so you don't really need to convert SUP to anything else. In my specific use case, I want my MKVs untouched for several reasons and the subtitles external. SUP files can't be external files, they only work when they are inside of a container like MKV. But if I wouldn't mind to modify my MKVs, I would just put the SUPs inside of them, and there wouldn't be a need for BDSup2Sub.
I still use BDSup2Sub 4.0.0 with my Blu-Ray Ripper program to merge forced subtitles into the main movie subtitle track if needed.

This does require to export to XML\PNG > merge forced events > export back to SUP.

I have my own editor GUI but it uses BDSup2Sub 4.0.0 from the command line.
__________________
Blu-Ray Ripper 0.106
Bandits is offline   Reply With Quote
Old 20th September 2017, 18:12   #1369  |  Link
Bandits
Registered User
 
Join Date: Feb 2015
Posts: 15
Quote:
Originally Posted by Scorpius666 View Post
Thanks to this wonderful thread I have found that versions of BDSup2Sup higher than 5.0.0 will lose 15% of the subtitles (totally unusable), but versions 5.0.0 and lower will only lose 1% if any.

Since it still loses a couple of subtitles, I have decided to implement one of the two things missing in BDSub2Sup that makes it lose subtitles.

Basically BDSup2Sub didn't implement two things:
  • Complex compositions. This is when two or more subtitles are shown at the same time. A warning is shown that multiple ODS are defined and only one subtitle will be recognized.
  • Cropping. BluRay subtitles support showing a piece of the image each time, so a line like "Ok! Let's do it" can be shown like "Ok!" first and then "Ok! Let's do it".

The second item is not that terrible. You will only lose the "animation" of the subtitle being shown few words at a time.

But the first item is a big problem. This usually happens when a subtitle is being shown and then another one has to appear, for example a foreign sign have appeared in the screen and the person hasn't finished talking. Since compositions are very common they must be implemented.

So that's what I did here: https://github.com/naikel/BDSup2Sub/tree/enhanced

Also I tried to give a better explanation how PGS works here: http://blog.thescorpius.com/index.ph...btitle-format/
With your new version, tracks 7 and 8 on Close Encounters of the Third Kind (1977) crash.

java.lang.NullPointerException
bdsup2sub.supstream.bd.Sup.BD.(Sup.BD.java:301)
bdsup2sub.core.Core.readSup(Core.java:301)
bdsup2sub.core.Core.run(Core.java:158)
java.lang.Thread.run(Unknown Source)

With 4.0.0, you will receive error:

WARNING: missing PDS/ODS: last epoch is discarded
__________________
Blu-Ray Ripper 0.106
Bandits is offline   Reply With Quote
Old 2nd October 2017, 14:44   #1370  |  Link
r0lZ
PgcEdit daemon
 
r0lZ's Avatar
 
Join Date: Jul 2003
Posts: 7,063
Quote:
Originally Posted by Scorpius666 View Post
That is not a bug.
As an additional evidence that there is really a bug with the way BDSup2Sub handles the frame rates and subtitle timings, have a look at this recent post in the BD3D2MK3D thread.

Users should NEVER have to wonder why their subtitles are not in sync any more after having processed them with BDSup2Sub (including with your version). The fact that they are not in sync except if the user does something obscure that he should NEVER be obliged to do is obviously the signature of a big bug. Please try to understand and fix that bug. It should be extremely easy to fix it, as it is sufficient to simply use the same output frame rate than the input. It's probably simply a single line of code to fix or add, and the nightmare of the out of sync streams produced by BDSup2Sub will be definitively a thing of the past.

(Note that I don't need the fix to use BDSup2Sub with BD3D2MK3D. I have added the "convert from 23.976 fps to 23.976 fps" arguments to the command line used by BD3D2MK3D, and it's sufficient to obtain the correct output. But is it really normal to have to do it? And do you really want to have to explain to all users that have encountered the bug that they have to force a theoretically useless frame rate conversion to obtain the correct output?)
__________________
r0lZ
PgcEdit homepage (hosted by VideoHelp)
BD3D2MK3D A tool to convert 3D blu-rays to SBS, T&B or FS MKV

Last edited by r0lZ; 2nd October 2017 at 14:50.
r0lZ is offline   Reply With Quote
Old 7th October 2017, 17:46   #1371  |  Link
Bandits
Registered User
 
Join Date: Feb 2015
Posts: 15
Quote:
Originally Posted by r0lZ View Post
(Note that I don't need the fix to use BDSup2Sub with BD3D2MK3D. I have added the "convert from 23.976 fps to 23.976 fps" arguments to the command line used by BD3D2MK3D, and it's sufficient to obtain the correct output. But is it really normal to have to do it? And do you really want to have to explain to all users that have encountered the bug that they have to force a theoretically useless frame rate conversion to obtain the correct output?)
I use the same line. This has been known for quite sometime and its not to bad when using it from command line. It just gets confusing to users when they open the GUI and expect it to work when FPS is deselected.
__________________
Blu-Ray Ripper 0.106
Bandits is offline   Reply With Quote
Old 11th November 2017, 14:27   #1372  |  Link
dngnt
Registered User
 
Join Date: Mar 2016
Posts: 1
BDSup2Sub for image extraction...

Hello everybody! I have recently discovered BDSup2Sub512.jar , but my main usage is oddly for conversion from SUP and IDX/SUB to SRT for Asian languages (Korean, Japanese and Chinese)... Thanks to its support for XML/PNG , I am able to extract all the images from the subtitles in a decent form in order to process before OCR by ONeNote and Acrobat.

The image extraction is far better than Vobsub, XilisoftDVD Subtitle Ripper ... because each image focusses on the subtitles , not the whole screen.

I do not use its XML. I further enhance the resulting images with Irfanview in order to OCR with One Note and Acrobat. Subtitle Edit is also used on the Sub/Sup to get a draft of the SRT with the timings ( and its rich conversion skills to other subtitle formats are very helpful), but its OCR capabilities are very limited .

All that combined allows me to get a correct Srt , with some processing and a little proof-reading. But its great fun because of all the scripting involved.

The essential part is the extraction of the png from the sub.sup to convert to text (thanks to the developpers!)...Quite the reverse of the initial philosophy of BDsuptosub I presume .

Last edited by dngnt; 11th November 2017 at 14:30.
dngnt 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 00:41.


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