Bug 114771
Summary: | Youtube iframe api causes Safari 5.1.7+ Mac to hang up | ||
---|---|---|---|
Product: | WebKit | Reporter: | Jurek R. <jurekraben> |
Component: | Frames | Assignee: | Nobody <webkit-unassigned> |
Status: | RESOLVED CONFIGURATION CHANGED | ||
Severity: | Blocker | CC: | jer.noble, karlcow |
Priority: | P2 | ||
Version: | 528+ (Nightly build) | ||
Hardware: | Mac (Intel) | ||
OS: | OS X 10.8 | ||
URL: | http://tstlab.virtualcreations.de/youtube-html5-bug.html |
Jurek R.
I add a fullscreen youtube iframe on a webpage using the following options:
ytplayer = new YT.Player('ytplayer', {
height: '390',width: '640',
videoId: $('.parameter[title|="youtube"]', block).text(),
playerVars: {
'hd':1,'autoplay': 0, 'controls': 0,
'modestbranding': 1,'rel':0,'showinfo': 0,'loop': 1, 'iv_load_policy': 3,
'enablejsapi': 0,'html5': 1,'scrolling': 'no'
},
events: {
'onReady': pCmsBackground.ytOnPlayerReady,
'onStateChange': pCmsBackground.ytOnPlayerStateChange
}
I use the following css on iframe div container:
position: fixed;
width: 100%;
height: 100%;
left: 0px;
top: 0px;
-webkit-user-drag: none;
-moz-user-drag: none;
-ms-user-drag: none;
user-drag: none;
pointer-events: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
-o-user-select: none;
user-select: none;
Now if ytOnPlayerReady is fired, I start to play the video, and on ytOnPlayerStateChange and event.data == YT.PlayerState.PLAYING I stop the video, until the moment comes when the video should be faded in and started.
This works fine on all browsers (Safari 5.05, IE9, Chrome, Firefox), but NOT on Safari 5.17 or Safari 5.19!
On Safari 5.17/5.19 as soon as the video is playing in ytOnPlayerReady, the browser starts extremely to lag, taking 100% of cpu. Also the fade in of the video never is visible, but the video starts to play in background, sound is stuttering.
The problem does not appear in the recent 5.17 webkit. So what is the problem here? It seems to be a bug in Safari. But I have to clue what bug it is and if there is a workaround for it.
Safari 5.1.7/5.1.9 is quite important to support, because on OSX 10.6.8 which is still used on 40% of Macs, this version is the newest one.
Please help, thanks!
Attachments | ||
---|---|---|
Add attachment proposed patch, testcase, etc. |
Jurek R.
With "recent 5.17 webkit" I mean the last webkit build for snow leopard, r127852.
Jurek R.
Here is an example that nearly freezes Safari:
http://tstlab.virtualcreations.de/youtube-html5-bug.html
It only happens if Safari version > 5.03 and youtube iframe is html5=1. It works on all other browsers, including chrome, Safari < 5.04.
Please fix it!
Jurek R.
Confirmed by some other Mac users, too. Until now I cannot see a pattern in the occuring of the bug.
Some users do not see the bug, some users see it. Read here for test results (German):
http://www.mactechnews.de/forum/discussion/Schwerer-Video-Bug-in-Safari-5-05-Bitte-um-Bestaetigung-313438.html
Confirmed on:
- Safari 5.1.7 - 5.1.9, OSX 10.6.8, MacPro 3,1, ATI HD 5570
- Safari 6.0.4, OSX 10.8.3, MacBook Pro 3,1 (mid 2007) mit einer nVidia 8600M GT
- Safari 5.0.6, OSX 10.5.8 PPC
Maybe it's related to older Graphics drivers within OSX? But it happens on nVidia and also on ATI.
Please test it and fix it!
Jurek R.
Also happens with youtube html5:
http://www.youtube.com/html5?hl=de&gl=DE
Karl Dubost
Not relevant anymore.
It doesn't reproduce.