You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
381 B
21 lines
381 B
#pragma once
|
|
#include "tser.hpp"
|
|
|
|
struct Point {
|
|
size_t x = 0;
|
|
size_t y = 0;
|
|
|
|
bool operator==(const Point& other) const {
|
|
return other.x == x && other.y == y;
|
|
}
|
|
|
|
DEFINE_SERIALIZABLE(Point, x, y);
|
|
};
|
|
|
|
typedef std::vector<Point> PointList;
|
|
|
|
struct PointHash {
|
|
size_t operator()(const Point& p) const {
|
|
return std::hash<int>()(p.x) ^ std::hash<int>()(p.y);
|
|
}
|
|
};
|
|
|