D
Dave Harvey
I have an array of Color values, and from them I need to create Bitmap - so
far I have found 2 methods, both with drawbacks:
1) Create a bitmap of the right size, then "poke" the values into it
one-at-a-time using SetPixel - horribly slow and inefficient
2) Go out to unmanaged code and use the Scan0 field of the BitmapData
structure. I wish to avoid this, as I would like to have "clean" managed
code which won't get refused by "managed code only" machines.
So, why can't I find a simple method to pass an array of Color values to a
Bitmap constructor (or equivalent)? - this SHOULD be a fast, safe, managed
operation.
Am I missing something obvious, or is the .NET framework the one missing
something (like an important method or two?)
Dave Harvey
Medical Connections
far I have found 2 methods, both with drawbacks:
1) Create a bitmap of the right size, then "poke" the values into it
one-at-a-time using SetPixel - horribly slow and inefficient
2) Go out to unmanaged code and use the Scan0 field of the BitmapData
structure. I wish to avoid this, as I would like to have "clean" managed
code which won't get refused by "managed code only" machines.
So, why can't I find a simple method to pass an array of Color values to a
Bitmap constructor (or equivalent)? - this SHOULD be a fast, safe, managed
operation.
Am I missing something obvious, or is the .NET framework the one missing
something (like an important method or two?)
Dave Harvey
Medical Connections