/// <summary> /// creates a new FilterImage form a Hawkynt cImage /// </summary> /// <param name="image"></param> public FilterImage(cImage image) { this.width = image.Width; this.height = image.Height; this.r = new byte[width * height]; this.g = new byte[width * height]; this.b = new byte[width * height]; this.a = new byte[width * height]; int x; int y; sPixel pixel; for (x = 0; x < this.width; x++) { for (y = 0; y < this.height; y++) { pixel = image.GetPixel(x, y); this.r[x * height + y] = pixel.Red; this.g[x * height + y] = pixel.Green; this.b[x * height + y] = pixel.Blue; this.a[x * height + y] = pixel.Alpha; } } }