Forum Discussion

gomad's avatar
gomad
Roku Guru
8 years ago

How to read and set the global Captions language selected in Roku settings?

How to read and set the global captions language selected in Roku settings? I wanted to get the list of supported Captions languages from Roku setting to set the video subtitles, is there any way? Also set the language when user changes it.

6 Replies

  • RokuKC's avatar
    RokuKC
    Roku Employee
    "gomad" wrote:
    How to read and set the global captions language selected in Roku settings? I wanted to get the list of supported Captions languages from Roku setting to set the video subtitles, is there any way? Also set the language when user changes it.

    The Roku OS provides this feature to the user to control.  As long as your content meta-data is specified correctly, it should "just work".
    https://sdkdocs.roku.com/display/sdkdoc/Closed+Caption+Support#ClosedCaptionSupport-PackagedControlSettings
  • Thanks.
    So I am setting the "SubtitleTracks" in the content-meta-data, with the list of subtitle available for a video. The problem is, I have give an option to the user to select the subtitle before he/she goes into a video player screen, so I want the player to take that language as default language, that is not happening, the player lists all the languages but the selected one is System default language.
    Say for example, user selects lang GN, and the video has a list of languages SD,FR,GD,MN,GN. The default Roku system language is, say, FR.
    Now during setting the content-meta-data using the subtitle tracks, i set GN,SD,FR,GD,MN. the player will list in that order, but will play FR subtitle by default. I am not able to change the default to GN through code, unless the user changes it with * options.

    Any help would be appreciated. 

    Thanks.
  • another behaviour: if I switch/change my subtitles very fast, on a slow network, from the video player, the language displayed gets messed up! meaning if i change to 1,2,3,4 and come back to 2 (very fast), 2 will be selected in the options list but 4 will be shown on the player!
  • RokuBen's avatar
    RokuBen
    Community Moderator
    That's because the video is effectively restarting at that point, so the CC engine has to be restarted too.  There was a bug in 8.0 and earlier that would sometimes cause captions to not show after an ad, so this is part of fixing that.
  • Ok thanks.
    How do you suggest we can handle this? Can i only set the video content meta data with subtitle urls?(I have multiple languages url/video)


    regards,
    GM