Neueste Beiträge

#11
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von Cypheros - September 29, 2024, 21:30:50
Your workflow is correct. So if I see it right, the problem is not srt file but the subtitle stream itself.

What is strange for me, is the fact, that the delay of 3 seconds is not existing in the original files but after merging the files together. Under normal circumstances TS-Doctor does not change the timers and the relation between the times in any way, only if problems are detected.

Could you be so kind and post the log files TS-Doctor created during the first step of your workflow, the merging of the files? The log file has the same name as the new created files but with the file extension .log.
#12
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von flexmcmurphy - September 29, 2024, 14:33:47
These are the files that were made by the Xoro 9000 for just one movie recording:

000.dvr
000.ts
001.dvr
001.ts
002.dvr
002.ts
003.dvr
003.ts
004.dvr
004.ts
info3.dvr

In TSDoctor I go to File > Open UPNP and select the one file the dialg box shows me. The name is "000". The dialg box also says Files=10 and entire size=4,352,787KB.

Then I open that in TSDoctor, I do nothing else but click on "Save new file" then it says "Stream cleaning successfully completed".

When I play that file in VLC or through my enigma2 box the subtitles are out of sync, they start about 3.5secs too early. From my efforts above I found that the timings of the subtitles are correct relative to one another but they appear a few seconds too early relative to the audio.

Am I doing something wrong? This is the method I have used in TSDoctor for a few other such Xoro recordings without issue. Maybe it's just bad luck and there is some problem with the subtitle stream in this recording? It would be amazing for my workflow if there was some setting in the TSDoctor Preferences that could fix this so I don't have to use other tools.

Cheers,

Flex
#13
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von Cypheros - September 29, 2024, 14:14:16
Merging dvr files should not lead to sync problems. How did you merge? Did you use the File Merger under Tools or did you open just one file and got the message "File is part of a multi part recording. Open complete multi part recording?" ?

Do you have an info.dvr or an info3.dvr together with the ts files?
#14
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von flexmcmurphy - September 29, 2024, 13:22:14
@MAM
Thank you for your help but what you didn't understand is that I am asking you this question:

Zitat"Can TSDoctor" fix subtitles being out of sync with audio?

After hours of trying and searching I realise now the answer is NO.
TsDoctor is not designed to fix out of sync subtitles. It does not provide an all in one solution.
TSDoctor can use OCR to export a .srt file of subtitles and its "SRT Time Changer" feature can change time offsets in that .srt file but nothing more.

I managed to fix my problem but I needed other tools with functionality that TSDoctor does not have. In my opinion it really should.

For anyone reading this thread in the future here is an answer to my question above.

1. Use TSDoctor to export a .srt file of subtitles in your .ts file. To do this you load up the .ts file in TSDoctor, go to the Preferences and tick the box in the Teletext/Subtitles tab to "Extract DVB subtitles (srt format)" then save that .ts file and it will output the .srt file.
2. Load that .srt file in to "Subtitle Edit" to sync the subtitles with the audio. The "Visual Sync" method from the "Synchronization" menu will probably be enough. All this does is correct the timecodes in the .srt file.
3. Use "Subtitle Edit" to export this .srt file in VobSub format.
4. Use ffmpeg to ADD this subtitle stream to your existing .ts file. This keeps all the existing streams in the .ts file and no encoding is performed.

ffmpeg -probesize 60M -analyzeduration 60M ^
-i "input.ts" ^
-i "subtitles.idx" ^
-map 0 -map 1 -vcodec copy -acodec copy -c:s:0 copy -c:s:1 dvbsub ^
-metadata:s:s:0 language=eng -metadata:s:s:0 handler_name=English -metadata:s:s:0 title=Bad ^
-metadata:s:s:1 language=eng -metadata:s:s:1 handler_name=English -metadata:s:s:1 title=Good ^
OUTPUT.ts

Feedback about TSDoctor:
I have a Xoro HRC 9000 dvb satellite decoder PVR, the TV recordings it makes are created in multiple 1GB .ts files with sibling .dvr files. I was using TSDoctor to combine all the .ts files in to one .ts file.

When I view these individual 1GB .ts files the subtitles are in-sync however after TSDoctor combines them they are not in sync. Yet, TSDoctor reported "No Errors". I think this is a bug in TSDoctor or the absence of needed functionality to identify when a subtitle stream has been assembled in such a way to be out of sync with the audio in the .ts file.

There is no use in TSDoctor having the "SRT Time Changer" feature when you anyway need to find another tool or tools that can actually re-sync subtitles with audio in a .ts file... in this case the combination of "Subtitle Edit" and "ffmpeg".

Thank you,

Flex


#15
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von Mam - September 29, 2024, 07:17:02
Zitat von: flexmcmurphy am September 28, 2024, 23:18:41Or does "SRT Time Changer" simply add additional time to the all the timecodes in a .srt file?
Yes, you can add or subtract time to the timecodes.

And yes too, it will make a significant difference if you perform it correctly.

Where it cannot help you at all is when the gaps between the titles are wrong. For instance if they are designed for a 24hz movie which is now played at 25hz. Over the playtime the titles will move more and more apart from the sync point.

Maybe you should try with larger values that will be better visible? try 0,5 or even 1 second.
It also depends on the player that you are using. SRTs are simple text files. The player needs to generate the graphics from the text and mix it into the picture (at the correct time).
#16
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von flexmcmurphy - September 28, 2024, 23:18:41
It doesn't make any difference what changes I make to the .srt file in "Subtitle Edit" or what offset I enter into "SRT Time Changer" in TSDoctor the same out-of-sync still exists in the .ts file that TSDoctor generates.

Does "SRT Time Changer" change how subtitles are sync'd to audio in the .ts file that TSDoctor generates?

Or does "SRT Time Changer" simply add additional time to the all the timecodes in a .srt file?

Because if it is the later then "SRT Time Changer" is no help to me whatsoever in which case as to my earlier question:

Can TSDoctor fix these out of sync subtitles in the .ts file or do I have to use another tool?

If not then what tool should I be using?

Ideally I could avoid re-encoding the .ts file but interested to hear what the options are.

Cheers,

Flex
#17
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von Mam - September 28, 2024, 18:25:03
Zitat von: flexmcmurphy am September 28, 2024, 16:52:40and set the offset to 0ms.
The point is NOT to use 0ms but guess (or try) a better value. 0 never can work because audio and subs are stored ahead of video (the frames are much smaller).
They are buffered until the "correct" video frame is to be about to be played. In every case this will be LATER, never a 0 (which means "play it NOW!").
So experiment with the values, sadly there is no general value to start with because it depends on the settings of the original encoder (which are lost by the extraction/conversion)
Good news is that once you have found a working delay, it usually stays the same for THIS STATION.
#18
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von flexmcmurphy - September 28, 2024, 16:52:40
Thanks for the swift reply.

Do you have any advice about how I calculate the exact offset to add to the timings in the .srt file?

What I have tried:
I used TSDoctor to export a .srt file of the DVB stream. I then opened this in Subtitle Edit and was able to sync the audio and subtitles together correctly. I then saved that .srt file with the new timings fixed using Subtitle Edit.

I then used TSDoctor > Tools > SRT Time Changer to add in that new .srt file and set the offset to 0ms. Now when TSDoctor creates the new .ts file the subtitles are still out of sync. I have tried several times now. Maybe I am using the "SRT Time Changer" wrong but it feels like it doesn't make any difference what changes I make to the .srt file in "Subtitle Edit" or what offset I enter into "SRT Time Changer" the same out-of-sync still exists in the .ts file that TSDoctor generates.

It seems that the subtitles are otherwise fine relative to one another, they just start too early. What am I doing wrong or what is the way to get the exact offset I need?

Cheers,

Flex
#19
TS-Doctor 4.x / Antw:How to fix subtitles that...
Letzter Beitrag von Cypheros - September 28, 2024, 15:39:15
Sometime such problem origins from mistakes happening in the playout center. Under tools you can find the SRT time changer to adjust SRT subtitle files.
#20
TS-Doctor 4.x / How to fix subtitles that are ...
Letzter Beitrag von flexmcmurphy - September 28, 2024, 14:48:33
Hello,

I have a lot of DVB-S recordings made from satellite on an old Xoro 9000 box. The recordings are composed of several 1GB .ts files. I just discovered TSDoctor which is brilliant software. I am using v4.1.9 to combine them in to one .ts file.

I have come across one example where in the re-combined .ts file the audio and video are fine but the subtitles are out of sync. TSDoctor didn't mention or report any errors.

I figured out how to use TSDoctor to extract a .srt file of the DVB subtitles with timings. What are my options now to fix these out of sync subtitles in the .ts file? I don't think I can do anything else in TSDoctor?

Ideally I could avoid re-encoding the .ts file but interested to hear what the options are.

Any help much appreciated.

Flex

www.cypheros.de