HLS supports subtitle as a part of HLS manifest (.m3u8)

In this example, the EXT-X-STREAM-INF tag specifies the video stream information and includes a SUBTITLES attribute that specifies the subtitle track with a GROUP-ID of "subs". The EXT-X-MEDIA tag defines the subtitle track information, including the URI of the WebVTT file.

It's worth noting that the format and syntax of the HLS manifest may vary depending on the specific requirements of your use case. This is just a basic example.


#EXTM3U
#EXT-X-VERSION:7
#EXT-X-STREAM-INF:BANDWIDTH=200000,CODECS="avc1.4d001f,mp4a.40.2",SUBTITLES="subs"
video/200kbps.m3u8
#EXT-X-MEDIA:TYPE=SUBTITLES,GROUP-ID="subs",NAME="English",DEFAULT=YES,FORCED=NO,URI="subtitles/eng.vtt"