OLD | NEW |
1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
2 <html> | 2 <html> |
3 <style> | 3 <style> |
4 img { | 4 img { |
5 transform: translateZ(0); /* Enable direct compositing. */ | 5 transform: translateZ(0); /* Enable direct compositing. */ |
6 width: 250px; | 6 width: 250px; |
7 } | 7 } |
8 .filter { | 8 .filter { |
9 -webkit-filter: blur(3px); | 9 -webkit-filter: blur(3px); |
10 } | 10 } |
11 </style> | 11 </style> |
12 | 12 |
13 <body> | 13 <body> |
14 <!-- The blue sector of the images should be at 12 o'clock. --> | 14 <!-- The blue sector of the images should be at 12 o'clock. --> |
15 <img onload="load(this)" title="png image" src="resources/red-at-12-oclock-wi
th-color-profile.png"> | 15 <img onload="load(this)" title="png image" src="resources/red-at-12-oclock-wi
th-color-profile.png"> |
16 <img onload="load(this)" title="jpeg image" src="resources/red-at-12-oclock-wi
th-color-profile.jpg"> | 16 <img onload="load(this)" title="jpeg image" src="resources/red-at-12-oclock-wi
th-color-profile.jpg"> |
17 <img onload="load(this)" title="webp image" src="resources/webp-color-profile-
lossy.webp"> | 17 <img onload="load(this)" title="webp image" src="resources/webp-color-profile-
lossy.webp"> |
18 </body> | 18 </body> |
19 | 19 |
20 <script> | 20 <script> |
21 var images = 0; | 21 var images = 0; |
22 | 22 |
23 function load(element) { | 23 function load(element) { |
24 setTimeout(function() { element.classList.add('filter') || next() }, 100); | 24 setTimeout(function() { element.classList.add('filter') || next() }, 100); |
25 } | 25 } |
26 | 26 |
27 function next() { | 27 function next() { |
28 if (++images == 3 && window.testRunner) | 28 if (++images == 3 && window.testRunner) |
29 setTimeout(function() { testRunner.setColorProfile('whacked', profileChanged
) }, 100); | 29 setTimeout(function() { testRunner.setColorProfile('colorSpin', profileChang
ed) }, 100); |
30 } | 30 } |
31 | 31 |
32 function profileChanged() { | 32 function profileChanged() { |
33 setTimeout(function() { testRunner.notifyDone() }, 0); | 33 setTimeout(function() { testRunner.notifyDone() }, 0); |
34 } | 34 } |
35 | 35 |
36 if (window.internals) | |
37 internals.settings.setImageColorProfilesEnabled(true); | |
38 | |
39 if (window.testRunner) { | 36 if (window.testRunner) { |
40 window.testRunner.dumpAsTextWithPixelResults(); | 37 window.testRunner.dumpAsTextWithPixelResults(); |
41 window.testRunner.waitUntilDone(); | 38 window.testRunner.waitUntilDone(); |
42 } | 39 } |
43 </script> | 40 </script> |
44 </html> | 41 </html> |
OLD | NEW |