Resonite-Issues icon indicating copy to clipboard operation
Resonite-Issues copied to clipboard

Add a way to get subtitles from YouTube easily

Open jae1911 opened this issue 1 year ago • 6 comments

Is your feature request related to a problem? Please describe.

When trying to show a series to friends, the series itself is in French but does have English subtitles. While it is technically possible to setup subtitles in Resonite, it's really time consuming and has lots of steps to make it properly work.

Describe the solution you'd like

Add a way to get and display subtitles easily, so it could be integrated into video players (for instance, the default one). This would also allow for more accessibility for players that are hard of hearing or deaf.

Describe alternatives you've considered

Setting up subtitles manually, tho time consuming.

Additional Context

yt-dlp exposes some arguments to get subtitles:

  • --write-subs
  • --write-auto-subs
  • --sub-lang
  • --sub-format

Requesters

No response

jae1911 avatar Jul 26 '24 00:07 jae1911

Seeking input from @Frooxius - during today's content team meeting options were being discussed for how to present / localize official video / tutorial content on-platform, and the concept of subtitles came up. We could possibly have community members provide localized voiceover and cut versions of our tutorial videos for other regions (notably in Japanese), but subtitles could possibly better fit into the existing localization system- particularly in combination with other functionality like #763.

While looking around to see what existing solutions we have available- I found there is a DynamicSubtitleProvider component which could possibly be used as a native feature on our video players- but I'm unclear on how that could be implemented into the existing video player as-is without requiring the user to manually insert subtitle files into the component for each video loaded.

Another possible option would be that if we include localized subtitle files onto our YouTube uploads directly- we could possibly dynamically pull those in using this request.

LexiBasilisk avatar Oct 08 '24 21:10 LexiBasilisk

I don't see anything too special here.

We can just have it fetch the subtitles from YouTube when available and add something to the video player interface to setup subtitle display.

It seems relatively easy enough to do.

Main thing would be probably how to pick subtitles - we could just have it default to user's locale with an override for language code perhaps?

Frooxius avatar Oct 08 '24 21:10 Frooxius

Main thing would be probably how to pick subtitles - we could just have it default to user's locale with an override for language code perhaps?

This is how I thought it could be done:

Try user's locale -> If available display those -> If not available, try english -> if english not available see the available ones and use them/list them somewhere on the player

Generally having a list of subs could be useful on the player.

jae1911 avatar Oct 08 '24 21:10 jae1911

Giving the user list of available subtitles is a fair bit more complicated. It's something we can add too, but it'll increase the complexity of this request, as we need to add mechanisms to fetch and display that information.

I'd probably suggest splitting that into its own thing, because adding an override first is simpler. Then extra UI can be made that lets you select that override visually, but that can be a separate task.

Frooxius avatar Oct 08 '24 22:10 Frooxius

OK, I'll create a separate issue with other improvements for this then.

jae1911 avatar Oct 08 '24 22:10 jae1911

We should've probably kept this as one issue and focus on the more general support first, rather than splitting it already.

We still have to handle the design and engineering side of this, so it'll depend a bit on how that's implemented, I need to have a look into it.

Frooxius avatar Oct 09 '24 18:10 Frooxius