Bug 37591

Summary: HTML5 "video" tag with poster frame defined "flashes" right before movie displays
Product: WebKit Reporter: Dan Wood <dwood>
Component: MediaAssignee: Eric Carlson <eric.carlson>
Status: RESOLVED FIXED    
Severity: Normal CC: ademar, ap, eric.carlson, jer.noble, silviapfeiffer1
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Macintosh Intel   
OS: OS X 10.6   
URL: http://www.karelia.com/scripts/claire2.html
Bug Depends on:    
Bug Blocks: 51249    
Attachments:
Description Flags
proposed patch.
none
revised patch. simon.fraser: review+

Description Dan Wood 2010-04-14 11:31:50 PDT
Safari: HTML5 "video" tag won't show movie when poster attribute is defined

Steps to Reproduce:
1. Create a web page with a <video> tag with the "poster" attribute.  For instance, see http://www.karelia.com/scripts/claire2.html
2. Load the page

Expected Results:
The movie should instantly replace the poster image

Actual Results:
The poster image disappears for a long enough time to notice, before it is replaced by the movie.

Notes:

This is using TOT Webkit.
Comment 1 Silvia Pfeiffer 2010-05-09 20:25:38 PDT
The effect you are describing happens for me in Google Chrome only.

In my Safari (Version 4.0.5 (6531.22.7)) the behaviour is even more broken for this page, since the first video doesn't play at all, even though it is on autoplay.

I have actually noticed generally that if I set a poster attribute in Google Chrome or Safari and don't set autoplay, that poster frame flashes briefly, then disappears and is replaced with the first frame of the video. While that is acceptable according to the HTML5 specification, I don't think it is what a Web developer or user would expect. In fact, this is also inconsistent with the behaviour of Opera and Firefox, which keep displaying the poster frame until the user hits the play button (or the JS play function is called).
Comment 2 Eric Carlson 2010-07-22 15:26:12 PDT
Created attachment 62348 [details]
proposed patch.
Comment 3 Eric Carlson 2010-08-06 15:56:49 PDT
Created attachment 63775 [details]
revised patch.
Comment 4 Eric Carlson 2010-08-06 16:37:23 PDT
http://trac.webkit.org/changeset/64884
Comment 5 Ademar Reis 2011-01-24 12:19:05 PST
Revision r64884 cherry-picked into qtwebkit-2.2 with commit 787fad8 <http://gitorious.org/webkit/qtwebkit/commit/787fad8>