EDIT: Since my original problem was due to my mistake I will rephrase this question.
Im hosting a Silverlight in a window inside my C++ application based on the code found here.
Now I'd like to copy the content of the control to memory in order to use the content inside my own renderer. The problem I have is that when I set "EnableGPUAcceleration" to true, then BitBlt stops working, all I get is blackness.
I feel that in theory there should be a way to copy the content of a GPU-accelerated Silverlight control with its alpha, e.g. with something like glReadPixels.
Anyone got any idea as how to copy the content with alpha of a non-windowless gpu-accelerated Silverlight control?
Another problem is that the window must be visible and no other window may overlap it, otherwise I do not get the proper content. I would like the hosting window to be invisible.
Working sample code can be found here (although without the actual BitBlt"ting" that I'm trying to get to work).