Jump to content

Emby Theater on Windows does not display HLS WebVTT subtitles, while server generates them and web client work


Recommended Posts

solidsnakex37
Posted

Environment

  • Server: Emby Server 4.9.x on Unraid Docker

  • Client: Emby Theater for Windows 2.234.2.0

Summary

When playing an item with subtitle tracks, Emby Theater requests HLS subtitles but none are displayed. The server generates WebVTT subtitle pipelines and HLS video plays normally. The same title shows subtitles in the web app. Theater does not.

Expected result

Emby Theater should display the selected subtitle track when the server is generating HLS VTT segments and the web app can show them.

What I've Found: 

Theater sets up mpv with its subtitle defaults, so the client is ready to render text:

[cplayer] Set property: sub-font="...GoNotoEmby.ttc" -> 1
[cplayer] Set property: sub-font-size=55.000000 -> 1

Theater requests the HLS master with subtitles enabled:

"DirectStreamUrl": "/videos/16342036/master.m3u8?...ManifestSubtitles=vtt&SubtitleMethod=Hls..."
"TranscodingUrl":   "/videos/16342036/master.m3u8?...ManifestSubtitles=vtt&SubtitleMethod=Hls..."
[stream_callback] Opening http://<server>:8097/emby/videos/16342036/master.m3u8?...ManifestSubtitles=vtt...

mpv’s ffmpeg HLS demuxer then rejects every subtitle rendition advertised in that master:

[ffmpeg/demuxer] hls: Can't support the subtitle(uri: subtitle...SubtitleStreamIndex=3...)
[ffmpeg/demuxer] hls: Can't support the subtitle(uri: subtitle...SubtitleStreamIndex=4...)
...
[ffmpeg/demuxer] hls: Can't support the subtitle(uri: subtitle...SubtitleStreamIndex=16...)

Theater is pulling HLS video fine. Server log shows the Dynamic HLS service handling EmbyTheater/2.234.2.0 requests and serving .ts segments without issue.

ffmpeg pipelines are created that generate WebVTT subtitle outputs for the selected tracks. You can see the VTT segment lists and files being prepared:

... -segment_format webvtt -segment_list "/transcode/transcoding-temp/9602B9/9602B9_s11_%d.vtt"
...
... -segment_format webvtt -segment_list "/transcode/transcoding-temp/3B2D61/3B2D61_s16_%d.vtt"

So the server is doing the subtitle work correctly. The video HLS stream is healthy, and the subtitle HLS pipelines exist.

In that same window there are many GETs for .ts video chunks, but no corresponding client fetches for .vtt. That fits the client-side demuxer messages above: Theater refuses the HLS subtitle groups, so it never requests the VTT files the server made.

 

Questions

  • Is Emby Theater on Windows expected to support HLS WebVTT subtitle groups in the master playlist produced by Emby Server 4.9?

  • Do the mpv messages about “Can’t support the subtitle” indicate a known limitation with the bundled mpv/ffmpeg demuxer?

  • Is there a client setting or server-side option to deliver text subtitles to Theater without HLS, so Theater can render them until HLS subtitle handling is fixed?

Attachments available

  • Emby Theater client logs with debug enabled

  • Emby Server log for the same session window

  • Two ffmpeg-transcode logs created during the single playback attempt

Subtitle Settings

  • Delivery preference (Text Subtitles):
    Burn in at the server (hard-sub) is selected.

  • Allow subtitle extraction on the fly: ON

  • Allow subtitle font extraction on the fly: ON

 

Client Logs.zip Emby Server Logs.zip

Posted

Thanks for the detailed report. 

Unfortunately, that's a known issue.

Generally, MPV does not properly support HLS with multiple subtitle tracks. Actually, it's more a shortcoming of FFmpeg.
Two or three years ago I had implementted this properly - in our own FFmpeg and the old Emby Theater had an MPV version that was built with out FFmpeg.

But when the Windows app was released, our FFmpeg was too old for building the latest MPV with it, so we had to use upstream FFmpeg instead and the feature got lost. Nobody noticed it, and I realized just way later that this happened, because our new subttile features had been put on hold and I didn't have any attention for this area anymore. 

Earlier this year, I have submitted this to FFmpeg and it's included in the next release. Also our FFmpeg update is ongoing - so either way, it will be working again in the near future. 
There's an updte in the pipeline which temprorarily disables this , so that you no longer get into a situation where you don't see anything.

  • Thanks 1
solidsnakex37
Posted
4 minutes ago, softworkz said:

Thanks for the detailed report. 

Unfortunately, that's a known issue.

Generally, MPV does not properly support HLS with multiple subtitle tracks. Actually, it's more a shortcoming of FFmpeg.
Two or three years ago I had implementted this properly - in our own FFmpeg and the old Emby Theater had an MPV version that was built with out FFmpeg.

But when the Windows app was released, our FFmpeg was too old for building the latest MPV with it, so we had to use upstream FFmpeg instead and the feature got lost. Nobody noticed it, and I realized just way later that this happened, because our new subttile features had been put on hold and I didn't have any attention for this area anymore. 

Earlier this year, I have submitted this to FFmpeg and it's included in the next release. Also our FFmpeg update is ongoing - so either way, it will be working again in the near future. 
There's an updte in the pipeline which temprorarily disables this , so that you no longer get into a situation where you don't see anything.

Thank you for the response on this! Glad to hear it's known and will eventually get fixed

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...