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

Side by Side Diff: cc/animation/layer_animation_controller.h

Issue 642983003: cc: Make PictureLayerImpl use a better choice for animated raster scale. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: animationscale: fixtest 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 unified diff | Download patch
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ 5 #ifndef CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_
6 #define CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ 6 #define CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 127
128 bool FilterAnimationBoundsForBox(const gfx::BoxF& box, 128 bool FilterAnimationBoundsForBox(const gfx::BoxF& box,
129 gfx::BoxF* bounds) const; 129 gfx::BoxF* bounds) const;
130 bool TransformAnimationBoundsForBox(const gfx::BoxF& box, 130 bool TransformAnimationBoundsForBox(const gfx::BoxF& box,
131 gfx::BoxF* bounds) const; 131 gfx::BoxF* bounds) const;
132 132
133 bool HasAnimationThatAffectsScale() const; 133 bool HasAnimationThatAffectsScale() const;
134 134
135 bool HasOnlyTranslationTransforms() const; 135 bool HasOnlyTranslationTransforms() const;
136 136
137 // Sets |max_scale| to the maximum scale along any dimension during active 137 // Sets |max_scale| to the maximum scale along any dimension at any
138 // animations. Returns false if the maximum scale cannot be computed. 138 // destination in active animations. Returns false if the maximum scale cannot
139 bool MaximumScale(float* max_scale) const; 139 // be computed.
140 bool MaximumTargetScale(float* max_scale) const;
140 141
141 bool needs_to_start_animations_for_testing() { 142 bool needs_to_start_animations_for_testing() {
142 return needs_to_start_animations_; 143 return needs_to_start_animations_;
143 } 144 }
144 145
145 protected: 146 protected:
146 friend class base::RefCounted<LayerAnimationController>; 147 friend class base::RefCounted<LayerAnimationController>;
147 148
148 explicit LayerAnimationController(int id); 149 explicit LayerAnimationController(int id);
149 virtual ~LayerAnimationController(); 150 virtual ~LayerAnimationController();
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 // Only try to start animations when new animations are added or when the 213 // Only try to start animations when new animations are added or when the
213 // previous attempt at starting animations failed to start all animations. 214 // previous attempt at starting animations failed to start all animations.
214 bool needs_to_start_animations_; 215 bool needs_to_start_animations_;
215 216
216 DISALLOW_COPY_AND_ASSIGN(LayerAnimationController); 217 DISALLOW_COPY_AND_ASSIGN(LayerAnimationController);
217 }; 218 };
218 219
219 } // namespace cc 220 } // namespace cc
220 221
221 #endif // CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_ 222 #endif // CC_ANIMATION_LAYER_ANIMATION_CONTROLLER_H_
OLDNEW
« no previous file with comments | « cc/animation/keyframed_animation_curve_unittest.cc ('k') | cc/animation/layer_animation_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698