<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[198612] trunk/PerformanceTests</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/198612">198612</a></dd>
<dt>Author</dt> <dd>jonlee@apple.com</dd>
<dt>Date</dt> <dd>2016-03-23 19:40:36 -0700 (Wed, 23 Mar 2016)</dd>
</dl>
<h3>Log Message</h3>
<pre>Update focus and leaves tests
https://bugs.webkit.org/show_bug.cgi?id=155825
Reviewed by Simon Fraser.
Particles would improperly disappear, before they were fully off stage. Update the calculation.
* Animometer/tests/dom/resources/leaves.js:
* Animometer/tests/master/resources/leaves.js:
* Animometer/tests/master/focus.html: Update the center element styling.
* Animometer/tests/master/resources/focus.js:
(FocusElement.Utilities.createClass): Give enough space in the container for each particle for the blur
to spread. It should be about 3x more space than the blur radius on each side.
(Stage.call.initialize): Ditto for the center element.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkPerformanceTestsAnimometertestsdomresourcesleavesjs">trunk/PerformanceTests/Animometer/tests/dom/resources/leaves.js</a></li>
<li><a href="#trunkPerformanceTestsAnimometertestsmasterfocushtml">trunk/PerformanceTests/Animometer/tests/master/focus.html</a></li>
<li><a href="#trunkPerformanceTestsAnimometertestsmasterresourcesfocusjs">trunk/PerformanceTests/Animometer/tests/master/resources/focus.js</a></li>
<li><a href="#trunkPerformanceTestsAnimometertestsmasterresourcesleavesjs">trunk/PerformanceTests/Animometer/tests/master/resources/leaves.js</a></li>
<li><a href="#trunkPerformanceTestsChangeLog">trunk/PerformanceTests/ChangeLog</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkPerformanceTestsAnimometertestsdomresourcesleavesjs"></a>
<div class="modfile"><h4>Modified: trunk/PerformanceTests/Animometer/tests/dom/resources/leaves.js (198611 => 198612)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/PerformanceTests/Animometer/tests/dom/resources/leaves.js        2016-03-24 02:40:03 UTC (rev 198611)
+++ trunk/PerformanceTests/Animometer/tests/dom/resources/leaves.js        2016-03-24 02:40:36 UTC (rev 198612)
</span><span class="lines">@@ -32,11 +32,11 @@
</span><span class="cx"> if (this._opacity > 1) {
</span><span class="cx"> this._opacity = 1;
</span><span class="cx"> this._opacityRate *= -1;
</span><del>- } else if (this._opacity < 0 || this._position.y > this.stage.size.y)
</del><ins>+ } else if (this._opacity < 0 || this._position.y > this.stage.size.height)
</ins><span class="cx"> this.reset();
</span><span class="cx">
</span><del>- if (this._position.x < -this.size.width || this._position.x > this.maxPosition.x)
- this._position.x = (this._position.x + this.maxPosition.x) % this.maxPosition.x;
</del><ins>+ if (this._position.x < -this.size.width || this._position.x > this.stage.size.width)
+ this._position.x = this._position.x - Math.sign(this._position.x) * (this.size.width + this.stage.size.width);
</ins><span class="cx"> this.move();
</span><span class="cx"> },
</span><span class="cx">
</span></span></pre></div>
<a id="trunkPerformanceTestsAnimometertestsmasterfocushtml"></a>
<div class="modfile"><h4>Modified: trunk/PerformanceTests/Animometer/tests/master/focus.html (198611 => 198612)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/PerformanceTests/Animometer/tests/master/focus.html        2016-03-24 02:40:03 UTC (rev 198611)
+++ trunk/PerformanceTests/Animometer/tests/master/focus.html        2016-03-24 02:40:36 UTC (rev 198612)
</span><span class="lines">@@ -20,14 +20,18 @@
</span><span class="cx"> border-radius: 50%;
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+ #center-text {
+ transform: translate3d(-50%, -50%, 0);
+ }
+
</ins><span class="cx"> #center-text span {
</span><ins>+ position: absolute;
</ins><span class="cx"> color: #201A1F;
</span><span class="cx"> font-weight: 400;
</span><span class="cx"> font-size: 2em;
</span><del>- position: absolute;
</del><span class="cx"> top: 50%;
</span><span class="cx"> left: 50%;
</span><del>- transform: translate3d(-50%, -50%, 0);
</del><ins>+ transform: translate(-50%, -50%);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> </style>
</span></span></pre></div>
<a id="trunkPerformanceTestsAnimometertestsmasterresourcesfocusjs"></a>
<div class="modfile"><h4>Modified: trunk/PerformanceTests/Animometer/tests/master/resources/focus.js (198611 => 198612)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/PerformanceTests/Animometer/tests/master/resources/focus.js        2016-03-24 02:40:03 UTC (rev 198611)
+++ trunk/PerformanceTests/Animometer/tests/master/resources/focus.js        2016-03-24 02:40:36 UTC (rev 198612)
</span><span class="lines">@@ -24,8 +24,8 @@
</span><span class="cx"> var size = 2 * radius + sizeVariance - distance;
</span><span class="cx">
</span><span class="cx"> this.container = document.createElement('div');
</span><del>- this.container.style.width = (size + stage.maxBlurValue * 2) + "px";
- this.container.style.height = (size + stage.maxBlurValue * 2) + "px";
</del><ins>+ this.container.style.width = (size + stage.maxBlurValue * 6) + "px";
+ this.container.style.height = (size + stage.maxBlurValue * 6) + "px";
</ins><span class="cx"> this.container.style.top = top + "px";
</span><span class="cx"> this.container.style.left = left + "px";
</span><span class="cx"> this.container.style.zIndex = Math.round((1 - this._depth) * 10);
</span><span class="lines">@@ -33,8 +33,9 @@
</span><span class="cx"> var particle = Utilities.createElement("div", {}, this.container);
</span><span class="cx"> particle.style.width = size + "px";
</span><span class="cx"> particle.style.height = size + "px";
</span><del>- particle.style.top = stage.maxBlurValue + "px";
- particle.style.left = stage.maxBlurValue + "px";
</del><ins>+ particle.style.top = (stage.maxBlurValue * 3) + "px";
+ particle.style.left = (stage.maxBlurValue * 3) + "px";
+ this.particle = particle;
</ins><span class="cx">
</span><span class="cx"> var depthMultiplier = Utilities.lerp(1 - this._depth, 0.8, 1);
</span><span class="cx"> this._sinMultiplier = Pseudo.random() * Stage.randomSign() * depthMultiplier;
</span><span class="lines">@@ -85,15 +86,15 @@
</span><span class="cx"> this._offsetIndex = 0;
</span><span class="cx">
</span><span class="cx"> this._centerElement = document.getElementById("center-text");
</span><del>- this._centerElement.style.width = (centerDiameter + this.maxCenterObjectBlurValue * 2) + "px";
- this._centerElement.style.height = (centerDiameter + this.maxCenterObjectBlurValue * 2) + "px";
</del><ins>+ this._centerElement.style.width = (centerDiameter + this.maxCenterObjectBlurValue * 6) + "px";
+ this._centerElement.style.height = (centerDiameter + this.maxCenterObjectBlurValue * 6) + "px";
</ins><span class="cx"> this._centerElement.style.zIndex = Math.round(10 * this.centerObjectDepth);
</span><span class="cx">
</span><span class="cx"> var particle = document.querySelector("#center-text div");
</span><span class="cx"> particle.style.width = centerDiameter + "px";
</span><span class="cx"> particle.style.height = centerDiameter + "px";
</span><del>- particle.style.top = this.maxCenterObjectBlurValue + "px";
- particle.style.left = this.maxCenterObjectBlurValue + "px";
</del><ins>+ particle.style.top = (this.maxCenterObjectBlurValue * 3) + "px";
+ particle.style.left = (this.maxCenterObjectBlurValue * 3) + "px";
</ins><span class="cx">
</span><span class="cx"> var blur = this.getBlurValue(this.centerObjectDepth, true);
</span><span class="cx"> Utilities.setElementPrefixedProperty(this._centerElement, "filter", "blur(" + blur + "px)");
</span></span></pre></div>
<a id="trunkPerformanceTestsAnimometertestsmasterresourcesleavesjs"></a>
<div class="modfile"><h4>Modified: trunk/PerformanceTests/Animometer/tests/master/resources/leaves.js (198611 => 198612)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/PerformanceTests/Animometer/tests/master/resources/leaves.js        2016-03-24 02:40:03 UTC (rev 198611)
+++ trunk/PerformanceTests/Animometer/tests/master/resources/leaves.js        2016-03-24 02:40:36 UTC (rev 198612)
</span><span class="lines">@@ -30,11 +30,11 @@
</span><span class="cx"> this._position.y += this._velocity.y;
</span><span class="cx">
</span><span class="cx"> this._life--;
</span><del>- if (!this._life || this._position.y > this.stage.size.y)
</del><ins>+ if (!this._life || this._position.y > this.stage.size.height)
</ins><span class="cx"> this.reset();
</span><span class="cx">
</span><del>- if (this._position.x < -this.size.width || this._position.x > this.maxPosition.x)
- this._position.x = (this._position.x + this.maxPosition.x) % this.maxPosition.x;
</del><ins>+ if (this._position.x < -this.size.width || this._position.x > this.stage.size.width)
+ this._position.x = this._position.x - Math.sign(this._position.x) * (this.size.width + this.stage.size.width);
</ins><span class="cx"> this.move();
</span><span class="cx"> },
</span><span class="cx">
</span></span></pre></div>
<a id="trunkPerformanceTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/PerformanceTests/ChangeLog (198611 => 198612)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/PerformanceTests/ChangeLog        2016-03-24 02:40:03 UTC (rev 198611)
+++ trunk/PerformanceTests/ChangeLog        2016-03-24 02:40:36 UTC (rev 198612)
</span><span class="lines">@@ -1,5 +1,22 @@
</span><span class="cx"> 2016-03-23 Jon Lee <jonlee@apple.com>
</span><span class="cx">
</span><ins>+ Update focus and leaves tests
+ https://bugs.webkit.org/show_bug.cgi?id=155825
+
+ Reviewed by Simon Fraser.
+
+ Particles would improperly disappear, before they were fully off stage. Update the calculation.
+ * Animometer/tests/dom/resources/leaves.js:
+ * Animometer/tests/master/resources/leaves.js:
+
+ * Animometer/tests/master/focus.html: Update the center element styling.
+ * Animometer/tests/master/resources/focus.js:
+ (FocusElement.Utilities.createClass): Give enough space in the container for each particle for the blur
+ to spread. It should be about 3x more space than the blur radius on each side.
+ (Stage.call.initialize): Ditto for the center element.
+
+2016-03-23 Jon Lee <jonlee@apple.com>
+
</ins><span class="cx"> Update support for other platforms
</span><span class="cx"> https://bugs.webkit.org/show_bug.cgi?id=155824
</span><span class="cx">
</span></span></pre>
</div>
</div>
</body>
</html>