From 0c391fdbce5a079cf03e483eb6174dd47806163d Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 7 Aug 2019 21:08:47 +0800 Subject: *misc --- source/modules/asura-utils/Math/Rect.hpp | 50 -------------------------------- 1 file changed, 50 deletions(-) delete mode 100644 source/modules/asura-utils/Math/Rect.hpp (limited to 'source/modules/asura-utils/Math/Rect.hpp') diff --git a/source/modules/asura-utils/Math/Rect.hpp b/source/modules/asura-utils/Math/Rect.hpp deleted file mode 100644 index 45bf1ba..0000000 --- a/source/modules/asura-utils/Math/Rect.hpp +++ /dev/null @@ -1,50 +0,0 @@ -#ifndef _ASURA_ENGINE_RECT_H_ -#define _ASURA_ENGINE_RECT_H_ - -namespace AsuraEngine -{ - namespace Math - { - - template - struct Rect - { - public: - Rect(); - Rect(T x, T y, T w, T h); - ~Rect() {}; - - /// - /// x,y是否落在rect内。 - /// - bool Contain(T x, T y); - - /// - /// 两个矩形是否相交,并返回相交的矩形 - /// - bool Intersect(const Rect& src, Rect& intersection); - - /// - /// 两个矩形是否相交,并返回相交的矩形 - /// - static bool Intersect(const Rect& src1, const Rect& src2, Rect& intersection); - - void Set(T x, T y, T w, T h); - - T x, y, w, h; - }; - -#include "Rect.inc" - - // Define the most common types - typedef Rect Recti; - typedef Rect Rectu; - typedef Rect Rectf; - typedef Rect Reftl; - - } -} - -namespace AEMath = AsuraEngine::Math; - -#endif \ No newline at end of file -- cgit v1.1-26-g67d0