Skip to content

Unable to change subtitle font size (Dash stream) #4491

@islor

Description

@islor

Issue description

I've been trying to change the subtitle font size with the following code, but it does not reflect accordingly.
playerView.getSubtitleView().setApplyEmbeddedStyles(false); playerView.getSubtitleView().setApplyEmbeddedFontSizes(false); playerView.getSubtitleView().setStyle(new CaptionStyleCompat(Color.RED, Color.TRANSPARENT, Color.TRANSPARENT, CaptionStyleCompat.EDGE_TYPE_OUTLINE,Color.BLACK,null)); playerView.getSubtitleView().setFixedTextSize(TypedValue.COMPLEX_UNIT_PX, 100);

There is no issue with changing the style, but when it comes to font sizes I realise that the player is still taking into consideration cellresolution and rawViewHeight instead of the textsize I input.
Is this intended? If so why? and how do I change the font size?

Also, when testing with sideloaded subtitle sources it has no problem showing the font size I set.

Reproduction steps

  1. Insert link into demo app: http://irtdashreference-i.akamaihd.net/dash/live/901161/bfs/manifestARD.mpd
    (I initially used another stream, but this stream seems to have the same issue)
  2. Insert codes as per above

Version of ExoPlayer being used

Tested on 2.8.1 and 2.8.2 (v2-dev)

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions