Create CBitmap from another CBitmap
-
Which are the way to copy a CBitmap to another CBitmap, but have both of them ? In fact, I want to create a CBitmap from another CBitmap ... could you help me ? Thank you.
You must do it by creating the new bitmap using the size of the source, select both bitmaps into DCs and call
BitBlt
to copy the image bits. Examples can be found on the web (found this searching for "cbitmap copy": http://www.tech-archive.net/Archive/VC/microsoft.public.vc.mfc/2007-07/msg01320.html[^]) -
You must do it by creating the new bitmap using the size of the source, select both bitmaps into DCs and call
BitBlt
to copy the image bits. Examples can be found on the web (found this searching for "cbitmap copy": http://www.tech-archive.net/Archive/VC/microsoft.public.vc.mfc/2007-07/msg01320.html[^])