Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(290)

Unified Diff: ManualTests/animation/compositor-change-playback-rate.html

Issue 667633003: Web Animations: Compositor timeOffset should not be scaled (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: isinf -> std::isinf Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | Source/core/animation/AnimationPlayer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ManualTests/animation/compositor-change-playback-rate.html
diff --git a/ManualTests/animation/compositor-change-playback-rate.html b/ManualTests/animation/compositor-change-playback-rate.html
new file mode 100644
index 0000000000000000000000000000000000000000..712c452a0e991893b28bb1f4b8268b9993ecc7c2
--- /dev/null
+++ b/ManualTests/animation/compositor-change-playback-rate.html
@@ -0,0 +1,42 @@
+<style>
+div {
+ height: 100px;
+ width: 100px;
+ background: blue;
+}
+</style>
+<p>
+The four squares should make identical rotations at different rates without jumping.
+<div id="target1"></div>
+<div id="target2"></div>
+<div id="target3"></div>
+<div id="target4"></div>
+<script>
+var player1 = target1.animate([
+ {transform: 'none'},
+ {transform: 'rotate(90deg)'}
+], {duration: 1000, iterations: 200000});
+
+var player2 = target2.animate([
+ {transform: 'none', background: 'blue'},
+ {transform: 'rotate(90deg)', background: 'blue'}
+], {duration: 1000, iterations: 200000});
+
+var player3 = target3.animate([
+ {transform: 'none'},
+ {transform: 'rotate(90deg)'}
+], {duration: 1000, iterations: Infinity});
+
+var player4 = target4.animate([
+ {transform: 'none', background: 'blue'},
+ {transform: 'rotate(90deg)', background: 'blue'}
+], {duration: 1000, iterations: Infinity});
+
+setInterval(function() {
+ var playbackRate = (Math.random() - 0.5) * 5;
+ player1.playbackRate = playbackRate;
+ player2.playbackRate = playbackRate;
+ player3.playbackRate = playbackRate;
+ player4.playbackRate = playbackRate;
+}, 100);
+</script>
« no previous file with comments | « no previous file | Source/core/animation/AnimationPlayer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698