private AllImageStatistics( ImageProperties imageProperties, Task <IImageStatistics> imageStatistics, IStarDetectionAnalysis starDetectionAnalysis) { this.ImageProperties = imageProperties; this.ImageStatistics = imageStatistics; this.StarDetectionAnalysis = starDetectionAnalysis; this.StarDetectionAnalysis.PropertyChanged += Child_PropertyChanged; }
public void Add(IStarDetectionAnalysis starDetectionAnalysis) { if (starDetectionAnalysis != null) { lock (lockObj) { var point = new ImageHistoryPoint(Interlocked.Increment(ref _nextStatHistoryId), starDetectionAnalysis); ImageHistory.Add(point); LimitedImageHistoryStack.Add(point); //Clear AF point if stack that is limited to 100 does not contain this point anymore var items = AutoFocusPoints.Except(LimitedImageHistoryStack).ToList(); foreach (var item in items) { AutoFocusPoints.Remove(item); } } } }
public ImageHistoryPoint(int id, IStarDetectionAnalysis starDetectionAnalysis) { Id = id; HFR = starDetectionAnalysis.HFR; DetectedStars = starDetectionAnalysis.DetectedStars; }