Bug 203649 - Add experimental TextTrackCue API
Summary: Add experimental TextTrackCue API
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Eric Carlson
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-10-30 17:37 PDT by Eric Carlson
Modified: 2019-11-01 15:50 PDT (History)
18 users (show)

See Also:


Attachments
WIP (74.88 KB, patch)
2019-10-30 17:54 PDT, Eric Carlson
no flags Details | Formatted Diff | Diff
WIP (75.09 KB, patch)
2019-10-30 18:17 PDT, Eric Carlson
no flags Details | Formatted Diff | Diff
Patch (88.48 KB, patch)
2019-11-01 11:42 PDT, Eric Carlson
no flags Details | Formatted Diff | Diff
Patch for landing (88.45 KB, patch)
2019-11-01 13:55 PDT, Eric Carlson
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Carlson 2019-10-30 17:37:44 PDT
Add the "Generic" TextTrackCue API presented at TPAC and FOMS. The API is disabled-by-default.
Comment 1 Eric Carlson 2019-10-30 17:38:03 PDT
<rdar://problem/55675172>
Comment 2 Eric Carlson 2019-10-30 17:54:43 PDT
Created attachment 382399 [details]
WIP
Comment 3 Eric Carlson 2019-10-30 18:17:35 PDT
Created attachment 382402 [details]
WIP
Comment 4 Jer Noble 2019-11-01 10:40:32 PDT
Comment on attachment 382402 [details]
WIP

View in context: https://bugs.webkit.org/attachment.cgi?id=382402&action=review

> Source/WebCore/Modules/mediacontrols/MediaControlsHost.cpp:180
> +void MediaControlsHost::updateCaptionDisplaySizes(bool forceUpdate)

A parameter of “enum class ForceUpdate { Yes, No }” might be nice here

> Source/WebCore/html/shadow/MediaControlElements.cpp:1193
> +        for (size_t i = 0; i < activeCues.size(); ++i) {

Can this be?: for (auto& cue : activeCues)

> Source/WebCore/html/shadow/MediaControlElements.cpp:1199
> +                RefPtr<TextTrackCueBox> displayBox = cue->getDisplayTree(m_videoDisplaySize.size(), m_fontSize);

Auto?

> Source/WebCore/html/shadow/MediaControlElements.cpp:1223
> +    if (!region) {

Or: if (auto region = ....)  { ... } else { ... }
Comment 5 Eric Carlson 2019-11-01 11:42:33 PDT
Created attachment 382604 [details]
Patch
Comment 6 Eric Carlson 2019-11-01 13:55:49 PDT
Created attachment 382624 [details]
Patch for landing
Comment 7 WebKit Commit Bot 2019-11-01 15:50:02 PDT
Comment on attachment 382624 [details]
Patch for landing

Clearing flags on attachment: 382624

Committed r251950: <https://trac.webkit.org/changeset/251950>
Comment 8 WebKit Commit Bot 2019-11-01 15:50:04 PDT
All reviewed patches have been landed.  Closing bug.