Common.cs
1.4 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
using System;
namespace Asa
{
internal class Common
{
public static Camera.VisionLib visionLib;
public static log4net.ILog log;
//public static string path_temp = Environment.CurrentDirectory + "\\aa.temp";
//public static void log_temp(string s)
//{
// System.IO.File.AppendAllText(path_temp, "\r\n" + s);
//}
}
//internal class CameraRegion
//{
// public string CameraName { set; get; } = "";
// public string RegionName { set; get; } = "";
// public int X { set; get; } = 0;
// public int Y { set; get; } = 0;
// public int Width { set; get; } = 0;
// public int Height { set; get; } = 0;
// public float Ratio { set; get; } = 0;
// public override string ToString()
// {
// string s = string.Format("{0} X:{1} Y:{2} W:{3} H:{4} R:{5}", RegionName, X, Y, Width, Height, Ratio);
// return s;
// }
// public CameraRegion Clone()
// {
// CameraRegion node = new();
// System.Reflection.PropertyInfo[] info1 = node.GetType().GetProperties();
// System.Reflection.PropertyInfo[] info2 = GetType().GetProperties();
// for (int i = 0; i < info1.Length; i++)
// info1[i].SetValue(node, info2[i].GetValue(this));
// return node;
// }
//}
}