Bug 230813 - Toggling display:none on a video element is delayed
Summary: Toggling display:none on a video element is delayed
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: Safari 14
Hardware: Mac (Intel) macOS 11
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-09-26 20:02 PDT by Sam Wemyss
Modified: 2021-09-29 09:22 PDT (History)
4 users (show)

See Also:


Attachments
Reduced test case showcasing the issue (1.42 KB, text/html)
2021-09-26 20:02 PDT, Sam Wemyss
no flags Details
Video demo of issue (1.34 MB, video/mp4)
2021-09-26 20:04 PDT, Sam Wemyss
no flags Details
Video demo of second issue, repeatedly triggered (266.24 KB, video/mp4)
2021-09-26 20:04 PDT, Sam Wemyss
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Wemyss 2021-09-26 20:02:08 PDT
Created attachment 439303 [details]
Reduced test case showcasing the issue

Safari 15. Though I believe it still occurs on 14 and lower.

Issue:

When toggling display on a parent container of a video there is a visual glitch:

none -> block: The red background will render, then the video will appear. Happens less frequently
block -> none: The video will disappear immediately but the red background will remain for a frame before being removed. This case is much more frequent than the former and can be repeatedly triggered without refreshing.

This can be reproduced in the minimal test case attached.


Expected:
That the video and the red background appear and disappear simultaneously. Same as other browsers.
Comment 1 Sam Wemyss 2021-09-26 20:04:12 PDT
Created attachment 439304 [details]
Video demo of issue

Video demo of both issues occurring. Progress frame by frame to see the visual glitch clearly at both toggle points
Comment 2 Sam Wemyss 2021-09-26 20:04:56 PDT
Created attachment 439305 [details]
Video demo of second issue, repeatedly triggered
Comment 3 Sam Sneddon [:gsnedders] 2021-09-27 01:11:43 PDT
Something compositing related, maybe?
Comment 4 Radar WebKit Bug Importer 2021-09-29 09:22:52 PDT
<rdar://problem/83674133>