/// <summary> /// Analyzes image by resizing it and storing pixels in list /// </summary> /// <param name="forceReanalyze">If true, the image is analyzed even if it's already been</param> public void AnalyzeImage(bool forceReanalyze = false) { if (Pixels.Count != 0 && !forceReanalyze) { return; } if (forceReanalyze && Pixels.Count > 0) { Pixels.Clear(); } var image = GetImage(); if (image == null) { // Image is invalid _isImage = false; return; } Pixels.AddRange(GetPixels(image)); }
public void Clear(Color color) { Pixels.Clear(color); }