Load an image into a byte-array with C#

Load an image into a byte-array with C#

This pretty simply snippet exports your Image into a byte-array.

1public static byte[] ToByteArray(this System.Drawing.Image image)
2{
3    using(MemoryStream memoryStream = new MemoryStream())
4    {
5        image.Save(memoryStream);
6        return memoryStream.ToArray();
7    }
8}

Usage:

1System.Drawing.Image myImage = .....
2
3byte[] imageAsByteArray = myImage.ToByteArray();

Hint: ImageSharp

ImageSharp uses the same signature to export bytes into a MemoryStream

Read Blog Post
Use a GoPro Hero as Webcam

Use a GoPro Hero as Webcam

The GoPro Hero series is the most popular action cam on the market. The current GoPro Hero 7 also offers USB-C, a micro-HDMI port as well WiFi and Bluetooth. However, the GoPro is just too good to have a life in a bag until I’m next on holiday. That’s why I had the idea to replace my Logitech 720p webcam with my the GoPro Hero 7.

Read Blog Post
Review: Corsair H100i v2 auf Intel 7820X mit NOCTUA NF-A12x25

Review: Corsair H100i v2 auf Intel 7820X mit NOCTUA NF-A12x25

Leider hat mich mal wieder ein Hardware-Defekt meines Arbeits-PCs für ein paar Stunden lahmgelegt.

Der Schaden

Gearbeitet bis Nachts um 2 hat am nächsten Morgen um 10 Uhr das System den Start verweigert. Mein 10 Monate alter CPU-Kühler Arctic Liquid Freezer 240 {target=_blank rel=noopener} hat leider von jetzt auf nachher ohne vorherige Ankündigung den Geist aufgegeben: Pumpe defekt. Dies hat sich durch eine entsprechende Fehlermeldung beim Start des Systems bemerkbar gemacht: CPU FAN ERROR.

Read Blog Post