chromium/ui/gfx/animation/tween.cc

// Copyright 2012 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "ui/gfx/animation/tween.h"

#include <math.h>
#include <stdint.h>

#include <algorithm>

#include "base/check_op.h"
#include "base/notreached.h"
#include "base/numerics/safe_conversions.h"
#include "base/time/time.h"
#include "build/build_config.h"
#include "ui/gfx/geometry/cubic_bezier.h"
#include "ui/gfx/geometry/rect.h"
#include "ui/gfx/geometry/rect_f.h"
#include "ui/gfx/geometry/size_f.h"
#include "ui/gfx/geometry/three_point_cubic_bezier.h"
#include "ui/gfx/geometry/transform.h"
#include "ui/gfx/geometry/transform_operations.h"

#if BUILDFLAG(IS_WIN)
#include <float.h>
#endif

namespace gfx {

// static
double Tween::CalculateValue(Tween::Type type, double state) {}

namespace {

uint8_t FloatToColorByte(float f) {}

uint8_t BlendColorComponents(uint8_t start,
                             uint8_t target,
                             float start_alpha,
                             float target_alpha,
                             float blended_alpha,
                             double progress) {}

float BlendColorComponentsFloat(float start,
                                float target,
                                float start_alpha,
                                float target_alpha,
                                float blended_alpha,
                                double progress) {}

}  // namespace

// static
SkColor4f Tween::ColorValueBetween(double value,
                                   SkColor4f start,
                                   SkColor4f target) {}
SkColor Tween::ColorValueBetween(double value, SkColor start, SkColor target) {}

// static
double Tween::DoubleValueBetween(double value, double start, double target) {}

// static
float Tween::FloatValueBetween(double value, float start, float target) {}

// static
float Tween::ClampedFloatValueBetween(const base::TimeTicks& time,
                                      const base::TimeTicks& start_time,
                                      float start,
                                      const base::TimeTicks& target_time,
                                      float target) {}

// static
int Tween::IntValueBetween(double value, int start, int target) {}

// static
int Tween::LinearIntValueBetween(double value, int start, int target) {}

// static
gfx::Rect Tween::RectValueBetween(double value,
                                  const gfx::Rect& start,
                                  const gfx::Rect& target) {}

// static
gfx::RectF Tween::RectFValueBetween(double value,
                                    const gfx::RectF& start,
                                    const gfx::RectF& target) {}

// static
gfx::Transform Tween::TransformValueBetween(double value,
                                            const gfx::Transform& start,
                                            const gfx::Transform& target) {}

// static
gfx::TransformOperations Tween::TransformOperationsValueBetween(
    double value,
    const gfx::TransformOperations& start,
    const gfx::TransformOperations& target) {}

gfx::Size Tween::SizeValueBetween(double value,
                                  const gfx::Size& start,
                                  const gfx::Size& target) {}

gfx::SizeF Tween::SizeFValueBetween(double value,
                                    const gfx::SizeF& start,
                                    const gfx::SizeF& target) {}

}  // namespace gfx