17 #ifndef _GAZEBO_VECTOR2D_HH_ 18 #define _GAZEBO_VECTOR2D_HH_ 20 #include <ignition/math/Vector2.hh> 44 public:
Vector2d(
const double &_x,
const double &_y);
52 public:
Vector2d(
const ignition::math::Vector2d &_v);
60 public:
double Distance(
const Vector2d &_pt)
const;
63 public:
void Normalize();
68 public:
void Set(
double _x,
double _y);
73 public:
double Dot(
const Vector2d &_v)
const;
83 public:
Vector2d &operator=(
const ignition::math::Vector2d &_v);
88 public:
const Vector2d &operator =(
double _v);
125 public:
const Vector2d operator/(
double _v)
const;
130 public:
const Vector2d &operator/=(
double _v);
146 public:
const Vector2d operator*(
double _v)
const;
151 public:
const Vector2d &operator*=(
double _v);
157 public:
bool operator ==(
const Vector2d &_v)
const;
161 public:
bool operator!=(
const Vector2d &_v)
const;
165 public:
bool IsFinite()
const;
170 public:
double operator[](
unsigned int _index)
const;
174 public: ignition::math::Vector2d Ign()
const;
189 _out << _pt.
x <<
" " << _pt.
y;
201 _in.setf(std::ios_base::skipws);
202 _in >> _pt.
x >> _pt.
y;
friend std::ostream & operator<<(std::ostream &_out, const gazebo::math::Vector2d &_pt)
Stream extraction operator.
Definition: Vector2d.hh:186
Forward declarations for the common classes.
Definition: Animation.hh:33
Generic double x, y vector.
Definition: Vector2d.hh:36
double y
y data
Definition: Vector2d.hh:180
double x
x data
Definition: Vector2d.hh:177
GAZEBO_VISIBLE void Set(common::Image &_img, const msgs::Image &_msg)
Convert a msgs::Image to a common::Image.
friend std::istream & operator>>(std::istream &_in, gazebo::math::Vector2d &_pt)
Stream extraction operator.
Definition: Vector2d.hh:197