Click to See Complete Forum and Search --> : Draw window in Memory Device Context


seedplusplus
March 15th, 2009, 04:12 PM
Hi,
Does someone know about drawing a window in a Memory Device Context, I need this so I can then read pixels from a window that is behind other windows. I need this for windows XP, not Vista.
Thx in advance.

bitshifter420
March 15th, 2009, 06:06 PM
If you want transparent windows you need a memory dc via CreateCompatibleDC
Also you need a bitmap via CreateCompatibleBitmap
You will also be using BitBlt to transfer the memory with a specific raster operation.
The idea is to blit the child rect into your bitmap then transparently blit it onto the top window.
Read about these functions and more at msdn.

But first master the forging skills of win32 you will.
http://www.winprog.org/tutorial/

Marc G
March 18th, 2009, 02:27 PM
Try PrintWindow (http://msdn.microsoft.com/en-us/library/dd162869.aspx).