| OLD | NEW |
| 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 #include "cc/math_util.h" | 5 #include "cc/base/math_util.h" |
| 6 | 6 |
| 7 #include <cmath> | 7 #include <cmath> |
| 8 #include <limits> | 8 #include <limits> |
| 9 | 9 |
| 10 #include "base/values.h" | 10 #include "base/values.h" |
| 11 #include "ui/gfx/quad_f.h" | 11 #include "ui/gfx/quad_f.h" |
| 12 #include "ui/gfx/rect.h" | 12 #include "ui/gfx/rect.h" |
| 13 #include "ui/gfx/rect_conversions.h" | 13 #include "ui/gfx/rect_conversions.h" |
| 14 #include "ui/gfx/rect_f.h" | 14 #include "ui/gfx/rect_f.h" |
| 15 #include "ui/gfx/transform.h" | 15 #include "ui/gfx/transform.h" |
| (...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 413 return scoped_ptr<base::Value>(base::Value::CreateDoubleValue( | 413 return scoped_ptr<base::Value>(base::Value::CreateDoubleValue( |
| 414 std::min(value, std::numeric_limits<double>::max()))); | 414 std::min(value, std::numeric_limits<double>::max()))); |
| 415 } | 415 } |
| 416 | 416 |
| 417 scoped_ptr<base::Value> MathUtil::asValueSafely(float value) { | 417 scoped_ptr<base::Value> MathUtil::asValueSafely(float value) { |
| 418 return scoped_ptr<base::Value>(base::Value::CreateDoubleValue( | 418 return scoped_ptr<base::Value>(base::Value::CreateDoubleValue( |
| 419 std::min(value, std::numeric_limits<float>::max()))); | 419 std::min(value, std::numeric_limits<float>::max()))); |
| 420 } | 420 } |
| 421 | 421 |
| 422 } // namespace cc | 422 } // namespace cc |
| OLD | NEW |