0

I want to take a screenshot of the rectangle where the window is located, but without the window itself, then process that screenshot through filters/shaders and then apply it as a background, making it seem like some sort of glass. (Not aero!)

enter image description here

I've been trying to find a way for days. Things I have tried:

  • Hiding the window, taking the screenshot, showing it again. (flickering window, cant really move it as this happens all the time)
  • DX shaders
  • Hooking, all kinds of screenshot approaches

I thought that if I used a shader along with a transparent or semi-transparent background, I could use those pixels, but despite being transparent I won't get them available.

Lately I've been wondering if there is any way I can get a hold of the video backbuffer before the window is rendered into the scene. There has to be a way?

I am using WPF for this solution, and I wanted to ask if anyone has any ideas as how to solve this?

Finally, if WPF is unfit for this task, what kind of programming environment would be?

Alx
  • 651
  • 1
  • 9
  • 26
  • One idea I could think of is not creating window with background (which region will prevent underground window repainting). Instead [draw on desktop](http://stackoverflow.com/q/14385838/1997232). I guess it will be less flickering. To be able to drag window around you only need window tittle bar. It's not clear what you are trying to achieve, perhaps you change your mind and do something like what [ScreenToGif](https://screentogif.codeplex.com/) does during screen capturing? – Sinatr Feb 09 '17 at 10:41
  • @Sinatr Thank you for the suggestion. I suppose if I use drawing on desktop, then I can't rely on WPFs effects and shaders anymore for processing the image. I'll do some experiments and see if this can be viable :) – Alx Feb 09 '17 at 11:56

0 Answers0