Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

automatic downloaded subtitles are overlapped #20566

Closed
victordesfe opened this issue Apr 4, 2019 · 4 comments
Closed

automatic downloaded subtitles are overlapped #20566

victordesfe opened this issue Apr 4, 2019 · 4 comments
Labels

Comments

@victordesfe
Copy link

@victordesfe victordesfe commented Apr 4, 2019

Hi i've been using yt-dl with no trouble but now i found something annoying.

When i download a youtube video with automatic subtitles everything goes ok but when i want to watch in on a media player, subtitles doesn't look right.

The thing is that when a new phrase shows, the old one goes over it and constantly does it, as if it was scrolling down from old to new. Technically that's how youtube subtitles show up but in a regular player looks worse because youtube player pops the sentences word by word as the person is speaking, but in a regular player it just shows the entire sentence so it doesn't look right.

This is hard to explain so i've done an animation showing what happens (this happens with any media player). link

There is any way to disable that effect and instead, get single-line subtitles? When downloading subtitles from "https://downsub.com" that effect is no present, so just the actual sentence being said is the only one showing in the screen. The "effect" is inherent to the subtitle file, and i noticed that subtitles downloaded from downsub weight the half respect the ones downloaded with yt-dl, so i opened the subtitle file with a text editor file and i noticed that each sentence is copied multiple times while on downsub each sentence is only present one time. So maybe if this is not a bug/issue, can an option be implemented so we can have "classic" subtitle format?

Tried changing the subtitle format with --convert-subs srt but doen't solve this.
Neither adding or not adding --embed-subs, or even setting the language with --sub-lang en

You can try this yourself by downloading a youtube video with automatic captions and watching it. Then download a video but without captions, you instead download captions from downsub and load them onto the video. Notice the difference. IMO yt-dl generated subtitles are very confusing while watching the video.

Hope you understood me and can help on this.
thanks in advance.

@remitamine
Copy link
Collaborator

@remitamine remitamine commented Apr 4, 2019

post an example URL with this problem.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Apr 4, 2019

  1. youtube-dl does not generate any Youtube subtitles, does not modify them in any way and provides as is. Everything is generated by Youtube, all blames go there.
  2. Lines are duplicated in vtt captions by Youtube, ttml as well has overlapping timings. Both are perfectly valid and probably intentionally made by Youtube.
@victordesfe
Copy link
Author

@victordesfe victordesfe commented Apr 5, 2019

@dstftw thanks for the information and quick response. I didn't know original vtt files were in that format. Sorry if i blamed yt-downloader because of that.

I've tried changing the input subtitle format with "--sub-format" but every time i got a message like "WARNING: No subtitle format found matching "srt" for language en, using vtt"
so it seems like youtube automatic captions are only in that format. Is there a built-in option or function on yt-dl to change the subtitle style? If that's not the case i would like to know if i can request that to be implemented if you are okay with it. I think it would be great as other people may also find the youtube automatic caption default style annoying.

@remitamine here is an URL example (sorry if i forgot to post it before):
https://www.youtube.com/watch?v=jzIiMKEpXJY

Here are the steps i followed:

  • Opened up a cmd window in windows 7 x64
  • introduced the following command (yt-dl.exe used is the lastest build available on here):
    "youtube-dl.exe --embed-subs --write-auto-sub https://www.youtube.com/watch?v=jzIiMKEpXJY"
  • Opened up the resultant file with MPC-HC. Subtitles are showing as the ones in the previously mentionated gif animation (again, technically this is the expected result as youtube subtitles are exactly like that, but anyways i found them annoying).

Thanks for you patience.
Regards.

remitamine added a commit that referenced this issue Apr 5, 2019
@remitamine
Copy link
Collaborator

@remitamine remitamine commented Apr 5, 2019

the web player uses a diffrent format that does not contain duplicate lines, you will be able to download this format in the next version, and use external tools to convert it into a usable format for the video player.
https://github.com/sterpe/yt-timedtext2srt advertises that it support srv3 format convertion to srt.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.