#include "ui/gfx/interpolated_transform.h"
#include <cmath>
#include "base/check.h"
#include "base/numerics/safe_conversions.h"
#include "ui/gfx/animation/tween.h"
#include "ui/gfx/geometry/transform_util.h"
namespace {
static const double EPSILON = …;
bool IsMultipleOfNinetyDegrees(double degrees) { … }
bool MassageRotationIfMultipleOfNinetyDegrees(gfx::Transform* rotation,
float degrees) { … }
}
namespace ui {
InterpolatedTransform::InterpolatedTransform()
: … { … }
InterpolatedTransform::InterpolatedTransform(float start_time,
float end_time)
: … { … }
InterpolatedTransform::~InterpolatedTransform() { … }
gfx::Transform InterpolatedTransform::Interpolate(float t) const { … }
void InterpolatedTransform::SetChild(
std::unique_ptr<InterpolatedTransform> child) { … }
inline float InterpolatedTransform::ValueBetween(float time,
float start_value,
float end_value) const { … }
InterpolatedRotation::InterpolatedRotation(float start_degrees,
float end_degrees)
: … { … }
InterpolatedRotation::InterpolatedRotation(float start_degrees,
float end_degrees,
float start_time,
float end_time)
: … { … }
InterpolatedRotation::~InterpolatedRotation() { … }
gfx::Transform InterpolatedRotation::InterpolateButDoNotCompose(float t) const { … }
InterpolatedAxisAngleRotation::InterpolatedAxisAngleRotation(
const gfx::Vector3dF& axis,
float start_degrees,
float end_degrees)
: … { … }
InterpolatedAxisAngleRotation::InterpolatedAxisAngleRotation(
const gfx::Vector3dF& axis,
float start_degrees,
float end_degrees,
float start_time,
float end_time)
: … { … }
InterpolatedAxisAngleRotation::~InterpolatedAxisAngleRotation() { … }
gfx::Transform
InterpolatedAxisAngleRotation::InterpolateButDoNotCompose(float t) const { … }
InterpolatedScale::InterpolatedScale(float start_scale, float end_scale)
: … { … }
InterpolatedScale::InterpolatedScale(float start_scale, float end_scale,
float start_time, float end_time)
: … { … }
InterpolatedScale::InterpolatedScale(const gfx::Point3F& start_scale,
const gfx::Point3F& end_scale)
: … { … }
InterpolatedScale::InterpolatedScale(const gfx::Point3F& start_scale,
const gfx::Point3F& end_scale,
float start_time,
float end_time)
: … { … }
InterpolatedScale::~InterpolatedScale() { … }
gfx::Transform InterpolatedScale::InterpolateButDoNotCompose(float t) const { … }
InterpolatedTranslation::InterpolatedTranslation(const gfx::PointF& start_pos,
const gfx::PointF& end_pos)
: … { … }
InterpolatedTranslation::InterpolatedTranslation(const gfx::PointF& start_pos,
const gfx::PointF& end_pos,
float start_time,
float end_time)
: … { … }
InterpolatedTranslation::InterpolatedTranslation(const gfx::Point3F& start_pos,
const gfx::Point3F& end_pos)
: … { … }
InterpolatedTranslation::InterpolatedTranslation(const gfx::Point3F& start_pos,
const gfx::Point3F& end_pos,
float start_time,
float end_time)
: … { … }
InterpolatedTranslation::~InterpolatedTranslation() { … }
gfx::Transform
InterpolatedTranslation::InterpolateButDoNotCompose(float t) const { … }
InterpolatedConstantTransform::InterpolatedConstantTransform(
const gfx::Transform& transform)
: … { … }
gfx::Transform
InterpolatedConstantTransform::InterpolateButDoNotCompose(float t) const { … }
InterpolatedConstantTransform::~InterpolatedConstantTransform() { … }
InterpolatedTransformAboutPivot::InterpolatedTransformAboutPivot(
const gfx::Point& pivot,
std::unique_ptr<InterpolatedTransform> transform)
: … { … }
InterpolatedTransformAboutPivot::InterpolatedTransformAboutPivot(
const gfx::Point& pivot,
std::unique_ptr<InterpolatedTransform> transform,
float start_time,
float end_time)
: … { … }
InterpolatedTransformAboutPivot::~InterpolatedTransformAboutPivot() { … }
gfx::Transform
InterpolatedTransformAboutPivot::InterpolateButDoNotCompose(float t) const { … }
void InterpolatedTransformAboutPivot::Init(
const gfx::Point& pivot,
std::unique_ptr<InterpolatedTransform> xform) { … }
InterpolatedMatrixTransform::InterpolatedMatrixTransform(
const gfx::Transform& start_transform,
const gfx::Transform& end_transform)
: … { … }
InterpolatedMatrixTransform::InterpolatedMatrixTransform(
const gfx::Transform& start_transform,
const gfx::Transform& end_transform,
float start_time,
float end_time)
: … { … }
InterpolatedMatrixTransform::~InterpolatedMatrixTransform() { … }
gfx::Transform
InterpolatedMatrixTransform::InterpolateButDoNotCompose(float t) const { … }
void InterpolatedMatrixTransform::Init(const gfx::Transform& start_transform,
const gfx::Transform& end_transform) { … }
}