36 Vec2ui(value_type
x, value_type
y) { _v[0] =
x; _v[1] =
y; }
42 if (_v[0]<v.
_v[0])
return true;
43 else if (_v[0]>v.
_v[0])
return false;
44 else return (_v[1]<v.
_v[1]);
47 inline value_type*
ptr() {
return _v; }
48 inline const value_type*
ptr()
const {
return _v; }
50 inline void set( value_type
x, value_type
y)
57 _v[0]=rhs.
_v[0]; _v[1]=rhs.
_v[1];
63 inline value_type&
x() {
return _v[0]; }
64 inline value_type&
y() {
return _v[1]; }
66 inline value_type
x()
const {
return _v[0]; }
67 inline value_type
y()
const {
return _v[1]; }
69 inline value_type&
r() {
return _v[0]; }
70 inline value_type&
g() {
return _v[1]; }
72 inline value_type
r()
const {
return _v[0]; }
73 inline value_type
g()
const {
return _v[1]; }
77 return Vec2ui(_v[0]*rhs, _v[1]*rhs);
82 return Vec2ui(_v[0]/rhs, _v[1]/rhs);
87 return Vec2ui(_v[0]+rhs, _v[1]+rhs);
92 return Vec2ui(_v[0]-rhs, _v[1]-rhs);
97 return Vec2ui(_v[0]+rhs.
_v[0], _v[1]+rhs.
_v[1]);
102 return Vec2ui(_v[0]-rhs.
_v[0], _v[1]-rhs.
_v[1]);
107 return Vec2ui(_v[0]*rhs.
_v[0], _v[1]*rhs.
_v[1]);
void set(const Vec2ui &rhs)
void set(value_type x, value_type y)
Vec2ui(value_type x, value_type y)
bool operator!=(const Vec2ui &v) const
bool operator==(const Vec2ui &v) const
value_type & operator[](int i)
Vec2ui operator/(value_type rhs) const
Vec2ui operator*(value_type rhs) const
bool operator<(const Vec2ui &v) const
Vec2ui operator+(value_type rhs) const
Vec2ui operator-(value_type rhs) const
const value_type * ptr() const