| | | 1 | | using ReFlex.Core.Common.Util; |
| | | 2 | | using ReFlex.Core.Interactivity.Components; |
| | | 3 | | |
| | | 4 | | namespace ReFlex.Server.Data.Config |
| | | 5 | | { |
| | | 6 | | public struct ExtremumDescriptionSettings |
| | | 7 | | { |
| | 28 | 8 | | public int NumSamples { get; set; } |
| | | 9 | | |
| | 30 | 10 | | public int CheckRadius { get; set; } |
| | | 11 | | |
| | | 12 | | private float? _mergeRadius; |
| | | 13 | | /// <summary>Euclidean sensor-pixel radius; missing legacy values default to three, zero disables consolidation. |
| | | 14 | | public float MergeRadius |
| | | 15 | | { |
| | 20 | 16 | | get => _mergeRadius ?? ExtremumConsolidator.DefaultRadius; |
| | 24 | 17 | | set => _mergeRadius = ExtremumConsolidator.ValidateRadius(value); |
| | | 18 | | } |
| | | 19 | | |
| | 28 | 20 | | public float FitPercentage { get; set; } |
| | | 21 | | |
| | 28 | 22 | | public ExtremumTypeCheckMethod CheckMethod { get; set; } |
| | | 23 | | |
| | | 24 | | public override string ToString() |
| | 0 | 25 | | { |
| | 0 | 26 | | var result = $"===== {nameof(ExtremumDescriptionSettings)} ====={Environment.NewLine}"; |
| | 0 | 27 | | result += $" {nameof(CheckMethod)} : {CheckMethod}{Environment.NewLine}"; |
| | 0 | 28 | | result += $" {nameof(NumSamples)} : {NumSamples}{Environment.NewLine}"; |
| | 0 | 29 | | result += $" {nameof(CheckRadius)} : {CheckRadius}{Environment.NewLine}"; |
| | 0 | 30 | | result += $" {nameof(MergeRadius)} : {MergeRadius}{Environment.NewLine}"; |
| | 0 | 31 | | result += $" {nameof(FitPercentage)} : {FitPercentage}{Environment.NewLine}"; |
| | | 32 | | |
| | 0 | 33 | | return result; |
| | 0 | 34 | | } |
| | | 35 | | } |
| | | 36 | | } |