chore.代码格式化、更新版本号、更新了一些脚本

This commit is contained in:
MistEO
2022-01-18 21:50:18 +08:00
parent 8622f312a6
commit db7983e6f2
12 changed files with 32 additions and 24 deletions

View File

@@ -9,8 +9,7 @@ asst::AbstractImageAnalyzer::AbstractImageAnalyzer(const cv::Mat image)
,
m_image_draw(image.clone())
#endif
{
}
{}
asst::AbstractImageAnalyzer::AbstractImageAnalyzer(const cv::Mat image, const Rect& roi)
: m_image(image),

View File

@@ -463,17 +463,17 @@ void asst::Assistant::set_penguin_id(const std::string& id)
else {
opt.penguin_report.extra_param = "-H \"authorization: PenguinID " + id + "\"";
}
}
std::vector<uchar> asst::Assistant::get_image() const
}
std::vector<uchar> asst::Assistant::get_image() const
{
return Ctrler.get_image_encode();
}
bool asst::Assistant::ctrler_click(int x, int y, bool block)
return Ctrler.get_image_encode();
}
bool asst::Assistant::ctrler_click(int x, int y, bool block)
{
Ctrler.click(Point(x, y), block);
return true;
return true;
}
bool asst::Assistant::start(bool block)

View File

@@ -262,10 +262,10 @@ namespace asst
close(pipe_in[PIPE_WRITE]);
close(pipe_out[PIPE_READ]);
close(pipe_out[PIPE_WRITE]);
}
}
#endif
return pipe_str;
}
}
//template<typename T,
// typename = typename std::enable_if<std::is_constructible<T, std::string>::value>::type>
@@ -307,5 +307,5 @@ namespace asst
// }
// return str;
//}
}
}
}

View File

@@ -101,7 +101,7 @@ asst::Controller::~Controller()
close(m_pipe_out[PIPE_READ]);
close(m_pipe_out[PIPE_WRITE]);
#endif
}
}
bool asst::Controller::connect_adb(const std::string & address)
{
@@ -594,9 +594,9 @@ bool asst::Controller::screencap()
size_t header_size = unzip_data.size() - std_size;
Log.trace("header size:", header_size);
bool is_all_zero = std::all_of(unzip_data.data() + header_size, unzip_data.data() + std_size,
bool is_all_zero = std::all_of(unzip_data.data() + header_size, unzip_data.data() + std_size,
[](uchar uch) -> bool {
return uch == 0;
return uch == 0;
});
if (is_all_zero) {
return false;

View File

@@ -15,7 +15,6 @@ namespace asst
InfrastProductionTask& set_uses_of_drone(std::string uses_of_drones) noexcept;
protected:
bool shift_facility_list();
bool facility_list_detect();

View File

@@ -1 +1 @@
#include "RuntimeStatus.h"
#include "RuntimeStatus.h"

View File

@@ -2,5 +2,5 @@
namespace asst
{
constexpr static const char* Version = "v2.7.7";
constexpr static const char* Version = "v2.7.8";
}

View File

@@ -1 +1,3 @@
MSBuild.exe ..\MeoAssistantArknights.sln /p:Configuration=Release /p:Platform=x64 /t:Rebuild
MSBuild.exe ..\MeoAssistantArknights.sln /p:Configuration=Release /p:Platform=x64 /t:Rebuild
pause

View File

@@ -2,4 +2,6 @@ set port=5555
adb connect 127.0.0.1:%port%
adb -s 127.0.0.1:%port% shell screencap /sdcard/screen.png
adb -s 127.0.0.1:%port% pull /sdcard/screen.png .
adb -s 127.0.0.1:%port% pull /sdcard/screen.png .
pause

View File

@@ -1 +1,3 @@
sh ./update_resource.sh ../x64/RelWithDebInfo
sh ./update_resource.sh ../x64/RelWithDebInfo
pause

View File

@@ -1 +1,3 @@
sh ./update_resource.sh ../x64/Release
sh ./update_resource.sh ../x64/Release
pause

View File

@@ -1 +1,3 @@
sh ./zip_release.sh
sh ./zip_release.sh
pause