converting a byte array to a 1bpp bitmap

  • Thread starter Thread starter James Dean
  • Start date Start date
J

James Dean

Could somebody tell me a quick way to write a whole byte array to a 1
bit per pixel bitmap if its possibleinstead of locking the bits and
doing it like that.....
 
James,

I would create a new MemoryStream instance, passing the byte array to
the stream. Once you do this, you can pass the MemoryStream instance to the
constructor of the Bitmap class, and it should read the contents from the
array to construct your bitmap.

Hope this helps.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top