mirror of http://192.168.1.51:8099/lmh188/twain3.0
2021.5.19 屏蔽8开16开尺寸检测
在接收到stopscan之后增加延时,防止读取滚轴数干扰dsp读写flash 2021.5.20 对接河南天一阅卷系统,修改DeviceOnline协议,由enum修改为onevalue,类型修改为bool
This commit is contained in:
parent
475ded4b3e
commit
4dbfade00e
|
@ -713,7 +713,7 @@ std::shared_ptr<std::vector<char>> GScanO200::Get_Img_Data(int bufferSize)
|
|||
int startindex = 0;
|
||||
while (totalength > 0)
|
||||
{
|
||||
int dstlength = 1024 * 1024;
|
||||
int dstlength = 512 * 1024;
|
||||
if (totalength <= dstlength)
|
||||
{
|
||||
dstlength = totalength;
|
||||
|
|
|
@ -54,10 +54,6 @@ void CImageApplyAutoCrop::apply(cv::Mat& pDib, int side)
|
|||
|
||||
if (m_maxContour.size() == 0)
|
||||
{
|
||||
thre.release();
|
||||
#ifdef LOG
|
||||
FileTools::write_log("imgprc.txt", "exit CImageApplyAutoCrop apply");
|
||||
#endif // LOG
|
||||
return;
|
||||
}
|
||||
thre.release();
|
||||
|
|
|
@ -91,12 +91,12 @@ void CImageApplyRotation::apply(cv::Mat & pDib, int side)
|
|||
if (m_rotation == RotationType::Rotate_90_clockwise || m_rotation == RotationType::Rotate_90_anti_clockwise) //90<39><30> -90<39><30>
|
||||
{
|
||||
transpose(pDib, pDib);
|
||||
flip(pDib, pDib, m_rotation == RotationType::Rotate_90_clockwise ? 1 : 0);
|
||||
flip(pDib, pDib, m_rotation == RotationType::Rotate_90_clockwise ? 0 : 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
flip(pDib, pDib, 0);
|
||||
flip(pDib, pDib, 1);
|
||||
flip(pDib, pDib, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -105,7 +105,7 @@ void CImageApplyRotation::apply(cv::Mat & pDib, int side)
|
|||
if (m_rotation == RotationType::Rotate_90_clockwise || m_rotation == RotationType::Rotate_90_anti_clockwise) //90<39><30> -90<39><30>
|
||||
{
|
||||
transpose(pDib, pDib);
|
||||
flip(pDib, pDib, m_rotation == RotationType::Rotate_90_clockwise ? 0 : 1);
|
||||
flip(pDib, pDib, m_rotation == RotationType::Rotate_90_clockwise ? 1 : 0);
|
||||
}
|
||||
else if (m_rotation == RotationType::Rotate_180)
|
||||
{
|
||||
|
|
|
@ -850,9 +850,19 @@ Result HuagaoDs::identityOpenDs(const Identity&) {
|
|||
m_caps[CapType::UiControllable] = std::bind(oneValGet<Bool>, _1, _2, Bool(true));
|
||||
|
||||
m_query[CapType::DeviceOnline] = msgSupportGetAll;
|
||||
m_caps[CapType::DeviceOnline] = std::bind(enmGet<Bool>, _1, _2, Bool(scanner->IsConnected()));
|
||||
|
||||
//m_caps[CapType::DeviceOnline] = std::bind(enmGet<Bool>, _1, _2, Bool(scanner->IsConnected()));
|
||||
m_caps[CapType::DeviceOnline] = [this](Msg msg, Capability& data) -> Result {
|
||||
switch (msg) {
|
||||
case Msg::Get:
|
||||
case Msg::GetCurrent:
|
||||
case Msg::GetDefault:
|
||||
data = Capability::createOneValue<CapType::DeviceOnline>((Twpp::Bool)scanner->IsConnected());
|
||||
return {};
|
||||
|
||||
default:
|
||||
return { ReturnCode::Failure, ConditionCode::CapBadOperation };
|
||||
}
|
||||
};
|
||||
|
||||
m_query[CapType::XferCount] = msgSupportGetAllSetReset;
|
||||
m_caps[CapType::XferCount] = [this](Msg msg, Capability& data) -> Result {
|
||||
|
|
BIN
huagao/stdafx.h
BIN
huagao/stdafx.h
Binary file not shown.
Loading…
Reference in New Issue