diff options
-rw-r--r-- | src/wall-atlas.hpp | 1 | ||||
-rw-r--r-- | wall-tileset-tool/main.cpp | 7 |
2 files changed, 7 insertions, 1 deletions
diff --git a/src/wall-atlas.hpp b/src/wall-atlas.hpp index 4832047e..a0103b2d 100644 --- a/src/wall-atlas.hpp +++ b/src/wall-atlas.hpp @@ -88,6 +88,7 @@ struct DirArrayIndex { namespace floormat { constexpr inline auto Direction_COUNT = (size_t)Wall::Direction_::COUNT; +constexpr inline auto Group_COUNT = (size_t)Wall::Group_::COUNT; struct wall_atlas_def final { diff --git a/wall-tileset-tool/main.cpp b/wall-tileset-tool/main.cpp index 9b07db75..6602fa33 100644 --- a/wall-tileset-tool/main.cpp +++ b/wall-tileset-tool/main.cpp @@ -72,7 +72,6 @@ constexpr inline int max_image_dimension = 4096; bool convert_to_bgra32(const cv::Mat& src, cv::Mat4b& dest) { fm_assert(dest.empty() || dest.size == src.size); - auto ch = src.channels(), tp = src.type(); switch (auto type = src.type()) { @@ -165,6 +164,12 @@ bool do_group(state st, size_t i, size_t j, Group& new_group) return false; } + DBG << " " << Debug::nospace << count << (count == 1 ? "frame" : "frames"); + + for (auto i = 0uz; i < count; i++) + for (auto j = i+1; j < count; j++) + fm_assert(st.frames[i].size.y() == st.frames[j].size.y()); + fm_assert(start + count == st.frames.size()); new_group.count = count; new_group.index = start; |