From f8571b36bd58de4d949c24126c82312d4a0aef43 Mon Sep 17 00:00:00 2001 From: Tiberiu Chibici Date: Wed, 14 Dec 2016 00:35:40 +0200 Subject: [PATCH] Undone changes to main --- src/Main.cpp | 35 ----------------------------------- 1 file changed, 35 deletions(-) diff --git a/src/Main.cpp b/src/Main.cpp index fd2de2d..cbe664e 100644 --- a/src/Main.cpp +++ b/src/Main.cpp @@ -4,39 +4,6 @@ using namespace farmlands; -#include - -void qtreeTest() -{ - utils::RectF bounds(0, 0, 100, 100); - utils::QTree tree(bounds); - - Assert(tree.empty(), "Tree should be empty."); - Assert(tree.size() == 0, "Tree should be empty."); - srand(10); - for (int i = 0; i < 100; i++) - { - tree.insert("Random", rand() % 100, rand() % 100); - } - - Assert(!tree.empty(), "Tree should be empty."); - Assert(tree.size() == 100, "Tree should be empty."); - - while (tree.size() > 2) - tree.erase(tree.begin()); - - utils::RectF search(-10, -10, 120, 120); - for (auto it = tree.lower_bound(search); it != tree.upper_bound(search); it++) - std::cout << it->data << ": " << it->x << ", " << it->y << "\n"; -} - -int main() -{ - qtreeTest(); -} - -#if 0 - int main() { int ret = 0; @@ -64,5 +31,3 @@ int main() return ret; } - -#endif