ScoreRect.cs 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. using Newtonsoft.Json;
  2. using System.Collections.Generic;
  3. namespace DaJiaoYan.Models
  4. {
  5. /// <summary>
  6. /// 先阅后扫打分模版
  7. /// </summary>
  8. public class ScoreRect
  9. {
  10. public class PaintScorePartRect
  11. {
  12. public int X { get; set; }
  13. public int Y { get; set; }
  14. public int Width { get; set; }
  15. public int Height { get; set; }
  16. //public OpenCvSharp.CPlusPlus.Rect Rect { get; set; }
  17. /// <summary>
  18. /// 该空分值
  19. /// </summary>
  20. public double Score { get; set; }
  21. //public PaintScorePartRect(OpenCvSharp.CPlusPlus.Rect Rect)
  22. //{
  23. // X = Rect.X;
  24. // Y = Rect.Y;
  25. // Width = Rect.Width;
  26. // Height = Rect.Height;
  27. // Score = 0;
  28. //}
  29. /// <summary>
  30. /// 该空填涂的百分比
  31. /// </summary>
  32. public int PaintPointCount { get; set; }
  33. }
  34. public class ScorePartRect
  35. {
  36. [JsonProperty(PropertyName = "id")]
  37. public string Id { get; set; }
  38. [JsonProperty(PropertyName = "isEdit")]
  39. public bool IsEdit { get; set; }
  40. [JsonProperty(PropertyName = "key")]
  41. public string Key { get; set; }
  42. [JsonProperty(PropertyName = "max_score")]
  43. public double MaxScore { get; set; }
  44. [JsonProperty(PropertyName = "min_score")]
  45. public double MinScore { get; set; }
  46. [JsonProperty(PropertyName = "score_type")]
  47. public int ScoreType { get; set; }
  48. [JsonProperty(PropertyName = "step")]
  49. public double Step { get; set; }
  50. [JsonProperty(PropertyName = "width")]
  51. public int Width { get; set; }
  52. [JsonProperty(PropertyName = "height")]
  53. public int Height { get; set; }
  54. [JsonProperty(PropertyName = "x")]
  55. public int X { get; set; }
  56. [JsonProperty(PropertyName = "y")]
  57. public int Y { get; set; }
  58. [JsonProperty(PropertyName = "PaintScorePartRects")]
  59. public List<PaintScorePartRect> PaintScorePartRects { get; set; }
  60. }
  61. public class EmptyScoreRect
  62. {
  63. [JsonProperty(PropertyName = "key")]
  64. public string Key { get; set; }
  65. [JsonProperty(PropertyName = "name")]
  66. public string Name { get; set; }
  67. [JsonProperty(PropertyName = "value")]
  68. public string Value { get; set; }
  69. [JsonProperty(PropertyName = "score_part_rects")]
  70. public List<ScorePartRect> ScorePartRects = new List<ScorePartRect>();
  71. }
  72. [JsonProperty(PropertyName = "name")]
  73. public string Name { get; set; }
  74. [JsonProperty(PropertyName = "empty_score_rects")]
  75. public List<EmptyScoreRect> EmptyScoreRects { get; set; }
  76. }
  77. }