Hello,

I have created an application that passes a Handle of a panel to a DLL which is then used for creating a DirectX or OpenGL render window, all of which works fine.

I wish to duplicate what is rendered in the panel elsewhere (basically multiple render windows all rendering the same thing).

My approach was to do something along the lines of this:

1. Create a panel (offscreen).
2. Take 'screen shots' of the panel and render them to my render windows (sizing as appropriate).

My problem lies with the second step in that I cannot get it to render the contents of the panel that have been created via the OpenGL / DirectX rendering.

Does anyone know of a way I can render the contents of a panel (which may not be on screen) and save it to another panel or image?

Hi Nick,

Thanks for the help, unfortunately the draw to bitmap code didn't do the trick - it did render the panel but not the OpenGL contents (I think this is possibly down to the panel not actually containing what the OpenGL code renders - or at least it doesn't know about it at the C# application phase).

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.