Ideally, I would like several workflows to be able to display objects off-screen, and then โtransferโ the displayed content to the on-screen target. With hwnd rendering objects this doesn't seem to be a problem (msdn has an example).
I'm not quite sure how to do this when the purpose of rendering on the screen is based on the DXGI swap chain. As far as I know, I can only have one swap chain per window. Therefore, I can have only one rendering target based on the swap chain. This means that on-screen rendering can only be done through this single rendering goal.
If my assumptions above are true, what is the best way to handle multi-threaded rendering? Do I need to serialize access to a screen target? Should worker threads share a single multi-threaded d2d factory? Can the BeginDraw / EndDraw / Present desktop be executed on the screen on workflows (i.e. Streams that do not create a landing page on the screen) if there is an appropriate locking mechanism?
I would be grateful for any suggestions. Thanks.
source share