Lines Matching defs:Vector2
27 struct Vector2 {
31 Vector2() :
35 Vector2(float px, float py) :
43 void operator+=(const Vector2& v) {
48 void operator-=(const Vector2& v) {
73 Vector2 operator+(const Vector2& v) const {
74 return Vector2(x + v.x, y + v.y);
77 Vector2 operator-(const Vector2& v) const {
78 return Vector2(x - v.x, y - v.y);
81 Vector2 operator/(float s) const {
82 return Vector2(x / s, y / s);
85 Vector2 operator*(float s) const {
86 return Vector2(x * s, y * s);
95 Vector2 copyNormalized() const {
96 Vector2 v(x, y);
101 float dot(const Vector2& v) const {
106 ALOGD("Vector2[%.2f, %.2f]", x, y);
108 }; // class Vector2
114 typedef Vector2 vec2;