ImageResult.cs 834 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Drawing;
  4. using System.IO;
  5. using System.Linq;
  6. using System.Text;
  7. using System.Threading.Tasks;
  8. namespace XdCxRhDW.Core.Api
  9. {
  10. public class ImageResult
  11. {
  12. private static float MaxColorValue = 40;//最大信噪比
  13. public int FsHz { get; set; }
  14. public int XFlag { get; set; }
  15. public int XMax { get; set; }
  16. public float YMax { get; set; }
  17. public int XValue { get; set; }
  18. public float YValue { get; set; }
  19. public float Snr { get; set; }
  20. public Color GetColor()
  21. {
  22. double flag;
  23. if (Snr >= MaxColorValue)
  24. flag = 1;
  25. else
  26. flag = Snr / MaxColorValue;
  27. return ColorRGB.GetSpecColor(flag);
  28. }
  29. }
  30. }