diff --git a/toonz/sources/include/tgeometry.h b/toonz/sources/include/tgeometry.h index 1224a63..8abcd2d 100644 --- a/toonz/sources/include/tgeometry.h +++ b/toonz/sources/include/tgeometry.h @@ -67,8 +67,6 @@ public: return TPointT(x - a.x, y - a.y); }; inline TPointT operator-() const { return TPointT(-x, -y); }; - - bool operator!=(const TPointT &p) const { return x != p.x || y != p.y; } }; template @@ -143,6 +141,10 @@ template inline bool operator==(const TPointT &p0, const TPointT &p1) { return p0.x == p1.x && p0.y == p1.y; } +template +inline bool operator!=(const TPointT &p0, const TPointT &p1) { + return p0.x != p1.x && p0.y != p1.y; +} //----------------------------------------------------------------------------- @@ -223,6 +225,9 @@ inline double tdistance2(const TPointD &p1, const TPointD &p2) { inline bool operator==(const TPointD &p0, const TPointD &p1) { return tdistance2(p0, p1) < TConsts::epsilon * TConsts::epsilon; } +inline bool operator!=(const TPointD &p0, const TPointD &p1) { + return !(p0 == p1); +} /*! \relates TPointT