summaryrefslogtreecommitdiffstats
path: root/cc/animation/animation_curve.h
diff options
context:
space:
mode:
authorajuma@chromium.org <ajuma@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-03 23:56:02 +0000
committerajuma@chromium.org <ajuma@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-04-03 23:56:02 +0000
commit6248bcc8d0717d4af4836299f54f51d0939042a8 (patch)
treef15c96ee198d1a424a46847227fd2a1ae7e0ca78 /cc/animation/animation_curve.h
parent22646b0458de4b49e9f84d051d5fb24316ad0271 (diff)
downloadchromium_src-6248bcc8d0717d4af4836299f54f51d0939042a8.zip
chromium_src-6248bcc8d0717d4af4836299f54f51d0939042a8.tar.gz
chromium_src-6248bcc8d0717d4af4836299f54f51d0939042a8.tar.bz2
cc: Compute the maximum scale of animations
This adds MaximumScale and HasOnlyTranslationTransforms methods to LayerAnimationController. BUG=224913 Review URL: https://codereview.chromium.org/214003004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@261583 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'cc/animation/animation_curve.h')
-rw-r--r--cc/animation/animation_curve.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/cc/animation/animation_curve.h b/cc/animation/animation_curve.h
index 4c15225..72aadef 100644
--- a/cc/animation/animation_curve.h
+++ b/cc/animation/animation_curve.h
@@ -78,6 +78,13 @@ class CC_EXPORT TransformAnimationCurve : public AnimationCurve {
// Returns true if this animation affects scale.
virtual bool AffectsScale() const = 0;
+ // Returns true if this animation is a translation.
+ virtual bool IsTranslation() const = 0;
+
+ // Set |max_scale| to the maximum scale along any dimension during this
+ // animation. Returns false if the maximum scale cannot be computed.
+ virtual bool MaximumScale(float* max_scale) const = 0;
+
// Partial Animation implementation.
virtual CurveType Type() const OVERRIDE;
};