Add/move code into kutil library

This commit is contained in:
Justin C. Miller
2018-04-17 23:41:28 -07:00
parent 2050b89334
commit a27b8d6a3a
15 changed files with 80 additions and 45 deletions

14
src/modules/kutil/coord.h Normal file
View File

@@ -0,0 +1,14 @@
#pragma once
namespace kutil {
template <typename T>
struct coord
{
T x, y;
coord() : x(T{}), y(T{}) {}
coord(T x, T y) : x(x), y(y) {}
T size() const { return x * y; }
};
} // namespace kutil