diff --git a/Rs.Framework/ImageProcess.cs b/Rs.Framework/ImageProcess.cs index 5ef72f7..1883e71 100644 --- a/Rs.Framework/ImageProcess.cs +++ b/Rs.Framework/ImageProcess.cs @@ -10,7 +10,7 @@ namespace Rs.Framework { public static class ImageProcess { - static UInt64 imageNum = 0; + //static UInt64 imageNum = 0; public static ManualResetEvent manualTriggerEvent = new ManualResetEvent(false); public static ManualResetEvent autoTriggerEvent = new ManualResetEvent(false); @@ -19,12 +19,12 @@ namespace Rs.Framework public static void AddManualTrigger(HObject obj) { - imageNum++; - if (imageNum>20) - { - GC.Collect(); - imageNum = 0; - } + //imageNum++; + //if (imageNum>20) + //{ + // GC.Collect(); + // imageNum = 0; + //} manualTriggerList.Add(obj); manualTriggerEvent.Set(); } @@ -33,6 +33,7 @@ namespace Rs.Framework { manualTriggerList.Clear(); manualTriggerEvent.Reset(); + GC.Collect(); } public static HObject GetManualImage() @@ -51,21 +52,23 @@ namespace Rs.Framework public static void AddAutoTrigger(HObject obj) { - imageNum++; - if (imageNum > 20) - { - LogHelper.Debug($"imagenum={imageNum},释放内存"); - GC.Collect(); - imageNum = 0; - } + //imageNum++; + //if (imageNum > 20) + //{ + // LogHelper.Debug($"imagenum={imageNum},释放内存"); + // GC.Collect(); + // imageNum = 0; + //} autoTriggerList.Add(obj); autoTriggerEvent.Set(); + } public static void ClearAutoTrigger() { autoTriggerList.Clear(); autoTriggerEvent.Reset(); + GC.Collect(); } } } diff --git a/Rs.Framework/Properties/AssemblyInfo.cs b/Rs.Framework/Properties/AssemblyInfo.cs index 19b8c63..e7cc859 100644 --- a/Rs.Framework/Properties/AssemblyInfo.cs +++ b/Rs.Framework/Properties/AssemblyInfo.cs @@ -33,5 +33,5 @@ using System.Runtime.InteropServices; //可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 //通过使用 "*",如下所示: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.*")] +[assembly: AssemblyVersion("2.20.24.1")] //[assembly: AssemblyFileVersion("1.0.0.0")]