Log in

View Full Version : VobSub with negative timecode


nel-son
27th August 2019, 09:48
Hi,

some time ago i merged some videos (bonus materials) into one large file using mkvmerge, but i never watched the video. now i found out that something with the subtitles (vobsub) isn't ok. at a point the timecode changed to a negative value. i opened the idx file in a text editor and found this

timestamp: 06:37:40:545, filepos: 003dde000
timestamp: 06:37:42:543, filepos: 003de1000
timestamp: -06:37:37:000, filepos: 003de2000
timestamp: -06:37:32:537, filepos: 003de380

it seems the difference between a line and the line before is ok and i tried to fix this. it got a working subtitle file and teh subs was displayed with vlc. but they were a little bit out of sync and i tried to fix that using bdsup2sub. after saving the new file i have the negative timecodes again. every time i save the file again with bdsup2sub i have negative timecodes.

is there any other format i can try? xml/png isn't supported by matroska and the timecode are 40sec earlier then vobsub.

mkver
28th August 2019, 09:24
At the typical 90kHz MPEG clock, 2^31 amounts to 6:37:40.929, so what you got here is likely just signed integer overflow. (Although the fact that 6:37:42 is more than this is a bit at odds with this explanation -- maybe it internally uses difference to the timestamp of the first subtitle or so?)
Is the video really 6:37:40 long or not? (If I am not mistaken, then the idx file can specify a delay, so that the actual timestamps aren't that big.)
MKVToolNix can apply a simple, constant delay; if you want vobsubs outside of Matroska, you can extract them with mkvextract afterwards.