namespace CCDCount.MODEL.ConfigModel
{
   /// <summary>
   /// 数粒工具的基础参数设置
   /// </summary>
    public class ShuLiConfigClass
    {
        /// <summary>
        /// 绑定相机的SN序列号
        /// </summary>
        public string CameraSN { get; set; } = string.Empty;
        /// <summary>
        /// 图像宽度
        /// </summary>
        public int ImageWidth { get; set; }
        /// <summary>
        /// 二值化阈值
        /// </summary>
        public int RegionThreshold { get; set; } = 30;
        /// <summary>
        /// 允许物体中断的最大连续行数
        /// </summary>
        public int MAX_GAP { get; set; } = 2;
        /// <summary>
        /// 单个物体允许的最大高度
        /// </summary>
        public int MAX_Idetify_Height { get; set; } = 2000;
        /// <summary>
        /// 合格物体的最小横向像素数
        /// </summary>
        public int MIN_OBJECT_WIDTH { get; set; } = 15;
        /// <summary>
        /// 合格物体的最大横向像素数
        /// </summary>
        public int MAX_OBJECT_WIDTH { get; set; } = 4000;
        /// <summary>
        /// 合格物体的最小竖向像素
        /// </summary>
        public int MIN_OBJECT_HEIGHT { get; set; } = 15;
        /// <summary>
        /// 合格物体的最大竖向像素
        /// </summary>
        public int MAX_OBJECT_HEIGHT { get; set; } = 200;
        /// <summary>
        /// 合格物体的最长长度
        /// </summary>
        public int MAX_Object_LENGTH { get; set; } = 1000;
        /// <summary>
        /// 合格物体的最短长度
        /// </summary>
        public int MIN_Object_LENGTH { get; set; } = 5;
        /// <summary>
        /// 判定标准识别码
        /// -1  为无效不进行颗粒合格判定
        /// 0 为使用宽高进行合格判定
        /// 1 为使用面积进行合格判定
        /// 2 为使用宽高和面积进行合格判定
        /// </summary>
        public int PandingCode { get; set; } = 0;
        /// <summary>
        /// 合格物体的最大面积
        /// </summary>
        public int MaxArea { get; set; } = 1000000;
        /// <summary>
        /// 合格物体的最小面积
        /// </summary>
        public int MinArea { get; set; } = 0;
        /// <summary>
        /// 噪声过滤阈值(面积过滤)
        /// </summary>
        public int NoiseFilter_Threshold { get; set; } = 5;
        /// <summary>
        /// 识别区域起始X坐标
        /// </summary>
        public int IdentifyStartX { get; set; } = 0;
        /// <summary>
        /// 识别区域结束X坐标
        /// </summary>
        public int IdentifyStopX { get; set; } = 0;
        /// <summary>
        /// 是否开启识别区域
        /// </summary>
        public bool IsIdentifyRoiOpen { get; set; } = false;
        /// <summary>
        /// 通道数量
        /// </summary>
        public int Channel { get; set; } = 1;
        /// <summary>
        /// 是否为配置文件读取
        /// </summary>
        public bool IsLoadCanfig { get; set; } = false;
        /// <summary>
        /// X计算系数
        /// </summary>
        public double ScaleX { get; set; } = 1;
        /// <summary>
        /// Y计算系数
        /// </summary>
        public double ScaleY { get; set; } = 1;
    }
}
