| Index: ui/gfx/vector2d_f.cc
|
| diff --git a/ui/gfx/vector2d_f.cc b/ui/gfx/vector2d_f.cc
|
| index f628421269ca2c1b668c8c720f72ff7a8dc0c728..3671c62869c6a7fc3e4c39471b1c71294c5dcf70 100644
|
| --- a/ui/gfx/vector2d_f.cc
|
| +++ b/ui/gfx/vector2d_f.cc
|
| @@ -51,4 +51,14 @@ void Vector2dF::Scale(float x_scale, float y_scale) {
|
| y_ *= y_scale;
|
| }
|
|
|
| +double CrossProduct(const Vector2dF& lhs, const Vector2dF& rhs) {
|
| + return static_cast<double>(lhs.x()) * rhs.y() -
|
| + static_cast<double>(lhs.y()) * rhs.x();
|
| +}
|
| +
|
| +double DotProduct(const Vector2dF& lhs, const Vector2dF& rhs) {
|
| + return static_cast<double>(lhs.x()) * rhs.x() +
|
| + static_cast<double>(lhs.y()) * rhs.y();
|
| +}
|
| +
|
| } // namespace gfx
|
|
|