Index: cc/math_util.h |
diff --git a/cc/math_util.h b/cc/math_util.h |
index 0d9984ef3f1071e0663ae444459c10eb8bfcee0f..de6288a7e1f7dcb1e3318e89e25cb11b40a83be6 100644 |
--- a/cc/math_util.h |
+++ b/cc/math_util.h |
@@ -6,11 +6,17 @@ |
#define CC_MATH_UTIL_H_ |
#include "base/logging.h" |
+#include "base/memory/scoped_ptr.h" |
#include "cc/cc_export.h" |
#include "ui/gfx/point_f.h" |
#include "ui/gfx/point3_f.h" |
+#include "ui/gfx/size.h" |
#include "ui/gfx/transform.h" |
+namespace base { |
+class Value; |
+} |
+ |
namespace gfx { |
class QuadF; |
class Rect; |
@@ -112,6 +118,11 @@ public: |
// Projects the |source| vector onto |destination|. Neither vector is assumed to be normalized. |
static gfx::Vector2dF projectVector(gfx::Vector2dF source, gfx::Vector2dF destination); |
+ |
+ // Conversion to value. |
+ static scoped_ptr<base::Value> asValue(gfx::Size s); |
+ static scoped_ptr<base::Value> asValue(gfx::PointF q); |
+ static scoped_ptr<base::Value> asValue(gfx::QuadF q); |
}; |
} // namespace cc |