LevelThumbTool.hpp 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. //
  2. // LevelThumbTool.hpp
  3. // auto_fill_jewel_v3
  4. //
  5. // Created by Red on 2024/12/4.
  6. // 生成关卡盘子摆放的缩略图
  7. #ifndef LevelThumbTool_hpp
  8. #define LevelThumbTool_hpp
  9. #include <stdio.h>
  10. #include <vector>
  11. using std::vector;
  12. #include "contourdata.h"
  13. #include "FillGlobalConfig.hpp"
  14. #include <opencv2/core.hpp>
  15. #include <opencv2/imgproc.hpp>
  16. #include <opencv2/highgui.hpp>
  17. #include "FillResult.hpp"
  18. #include <tuple>
  19. using std::tuple;
  20. struct LevelThumbTool {
  21. void drawthumb(
  22. string outname , // 输出png文件名
  23. vector<tuple<int,vector<vector<FillResult>>>>& fillResultsArr, // tuple<盘子类型ID, <层数组<一层填充结果>>>
  24. vector<ContourData::Point>& posiArr //盘子中心坐标位置数组,坐标系原点在游戏区域左下角
  25. ) ;
  26. //deprecated, use makeThumb2
  27. void makeThumb(string outpngname, vector<int>& plateIdArr,vector<ContourData::Point>& platePosiArr ) ;
  28. void makeThumb2(string outpngname, vector<tuple<int,vector<vector<FillResult>>>>& fillResultsArr,vector<ContourData::Point>& platePosiArr ) ;
  29. } ;
  30. #endif /* LevelThumbTool_hpp */