Home | History | Annotate | Download | only in cpp

Lines Matching refs:other

93   /// Adds two Points (this and other) together by adding their x values and
96 /// @param[in] other A Point.
99 Point operator+(const Point& other) const {
100 return Point(x() + other.x(), y() + other.y());
106 /// @param[in] other A Point.
109 Point operator-(const Point& other) const {
110 return Point(x() - other.x(), y() - other.y());
113 /// Adds two Points (this and other) together by adding their x and y
116 /// @param[in] other A Point.
119 Point& operator+=(const Point& other) {
120 point_.x += other.x();
121 point_.y += other.y();
128 /// @param[in] other A Point.
131 Point& operator-=(const Point& other) {
132 point_.x -= other.x();
133 point_.y -= other.y();
139 /// @param[in] other A Point.
140 void swap(Point& other) {
143 point_.x = other.point_.x;
144 point_.y = other.point_.y;
145 other.point_.x = x;
146 other.point_.y = y;
232 /// Adds two Points (this and other) together by adding their x values and
235 /// @param[in] other A Point.
238 FloatPoint operator+(const FloatPoint& other) const {
239 return FloatPoint(x() + other.x(), y() + other.y());
245 /// @param[in] other A FloatPoint.
248 FloatPoint operator-(const FloatPoint& other) const {
249 return FloatPoint(x() - other.x(), y() - other.y());
252 /// Adds two Points (this and other) together by adding their x and y
255 /// @param[in] other A Point.
258 FloatPoint& operator+=(const FloatPoint& other) {
259 float_point_.x += other.x();
260 float_point_.y += other.y();
267 /// @param[in] other A Point.
270 FloatPoint& operator-=(const FloatPoint& other) {
271 float_point_.x -= other.x();
272 float_point_.y -= other.y();
278 /// @param[in] other A Point.
279 void swap(FloatPoint& other) {
282 float_point_.x = other.float_point_.x;
283 float_point_.y = other.float_point_.y;
284 other.float_point_.x = x;
285 other.float_point_.y = y;