Converting an array of Pixels to an image in C#

前端 未结 6 1537
孤城傲影
孤城傲影 2020-12-28 11:20

I have an array of int pixels in my C# program and I want to convert it into an image. The problem is I am converting Java source code for a program into equiva

6条回答
  •  臣服心动
    2020-12-28 11:40

    Well, I'm assuming each int is the composite ARGB value? If there isn't an easy option, then LockBits might be worth looking at - it'll be a lot quicker than SetPixel, but is more complex. You'll also have to make sure you know how the int is composed (ARGB? RGBA?). I'll try to see if there is a more obvious option...

提交回复
热议问题