Subtitles

In order to show subtitles you have three options:

  • Use an HLS stream with embedded subtitles
  • Use an HLS stream as FPExternalMedia and configure the URL to subtitles
  • Upload the VTT files to Flowplayer Platform and use FPFlowplayerMedia

HLS stream with embedded subtitles

If you HLS stream contains subtitles you are all set. FPFlowplayer will detect them and load them when loading the provided media.

Flowplayer Platform hosted video & subtitles

You can upload subtitles as VTT files for a video in the Flowplayer Platform UI from the "Files" view. The labels and languages configured will show up in the player.

Using FPExternalMedia with VTT files

If you are using FPExternalMedia, you can configure the subtitles by hand:

let track = FPTrack(
        lang: "en",
        src: "https://mycdn.example.com/subs.vtt",
        label: "English subs",
        kind: ""
)

let externalMedia = FPExternalMedia(
        mediaUrl: "https://mycdn.example.com/video.m3u8",
        adSchedule: nil,
        metadata: nil,
        subtitles: [track]
 )

Please note that subtitles only work with HLS streams, also when using FPExternalMedia.

By using this website you agree to our privacy policy
Results