AVPlayerItem textStyleRules should work for subtitles in TX3G format

Originator:marcelofabri.mf
Number:rdar://14923755 Date Originated:05-Sep-2013 07:54 PM
Status:Open Resolved:No
Product:iOS SDK Product Version:6.1.3
Classification:Enhancement Reproducible:Always
 
Summary:
AVPlayerItem textStyleRules property should work for subtitles in TX3G format, but it only works for WebVTT content (https://devforums.apple.com/message/868318#868318).

Steps to Reproduce:
1. Setup an AVPlayer with a local video that contains subtitles in TX3G
2. Select the subtitle with the code:

AVMediaSelectionGroup *subtitle = [asset mediaSelectionGroupForMediaCharacteristic: AVMediaCharacteristicLegible];
[videoPlayer.currentItem selectMediaOption:subtitle.options[0] inMediaSelectionGroup: subtitle];

3. Apply textStyleRules:

AVTextStyleRule *rule = [[AVTextStyleRule alloc] initWithTextMarkupAttributes:@{
                         (id)kCMTextMarkupAttribute_ForegroundColorARGB : @[ @1, @1, @0, @0 ],
                         (id) kCMTextMarkupAttribute_ItalicStyle : @(YES)}];

videoPlayer.currentItem.textStyleRules = @[rule];

Expected Results:
The subtitles should appear in red and italic.

Actual Results:
The subtitles are showed with regular style.

Version:
iOS 6.1.3

Notes:
I also created rdar://14923673 to update the documentations about this current limitation.

Configuration:


Attachments:

Comments

This still seems to be broken, also when working with WebVTT. I cannot change the font nor the opacity of the background color. Not sure about other attributes.

By baldur.helgason at Feb. 16, 2016, 5 p.m. (reply...)

Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!