From 4b3a410a5083970bb2e56d2ab459d860c4fa22d0 Mon Sep 17 00:00:00 2001
From: C3204 <zhengyabo@lanpucloud.cn>
Date: 星期二, 30 十二月 2025 15:50:42 +0800
Subject: [PATCH] 添加单流程多相机处理功能。
---
LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs | 24 ++++++------------------
1 files changed, 6 insertions(+), 18 deletions(-)
diff --git a/LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs b/LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs
index ee4545a..b9febc4 100644
--- a/LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs
+++ b/LB_SmartVision/Forms/Pages/ProcessPage/ProcessControl.cs
@@ -72,19 +72,17 @@
}));
}
else
- {
UserHSmartWindowControl.ClearObj();
- }
}
/// <summary>
/// 寮傛鏄剧ず鍥剧墖
/// </summary>
/// <param name="ho_image"></param>
- public void ShowHoImage(HImage ho_image)
+ public void ShowHoImage(HObject ho_image)
{
- string str = this.lblTitle.Text;
UserHSmartWindowControl.hImage = ho_image;
+
if (this.InvokeRequired)
{
this.BeginInvoke(new Action(() =>
@@ -93,9 +91,7 @@
}));
}
else
- {
this.label1.Text = $"鎬绘暟锛歿ProcessRunBll.total}";
- }
}
public bool Run(out string msg)
@@ -107,9 +103,7 @@
}
if (isCircleRuning || ProcessRunBll.bRuning)
- {
ProcessRunBll.LogInfo($"{ProcessRunBll.Name}姝e湪杩愯", LogInfoType.ERROR);
- }
ProcessRunBll.Run();
@@ -126,19 +120,15 @@
try
{
if (ProcessRunBll == null)
- {
return;
- }
ProcessRunBll.LogInfo(string.Format("娴佺▼[{0}]寮�濮嬭繍琛�", this.ProcessRunBll.Name), LogInfoType.INFO);
ClearObj();
result = Run(out msg);
- if (ProcessRunBll.GetImage(_Layout, out _, out HImage RecordImage))
- {
+ if (ProcessRunBll.GetImage(_Layout, out _, out HObject RecordImage))
ShowHoImage(RecordImage);
- }
}
catch { msg = "杩愯鍑虹幇浜嗗紓甯�"; }
@@ -166,7 +156,7 @@
else
{
isCircleRuning = false;
- //threadCircleRun.Abort();
+ threadCircleRun.Abort();
}
}
catch { }
@@ -198,15 +188,13 @@
ProcessRunBll.LogInfo($"{ProcessRunBll.Name}杩愯缁撴潫,缁撴灉涓�:{msg}"
, result ? LogInfoType.PASS : LogInfoType.ERROR);
- if (ProcessRunBll.GetImage(_Layout, out _, out HImage RecordImage))
- {
+ if (ProcessRunBll.GetImage(_Layout, out _, out HObject RecordImage))
ShowHoImage(RecordImage);
- }
}
catch { }
//}));
- Thread.Sleep(33);
+ Thread.Sleep(100);
}
}
--
Gitblit v1.9.3