1. To be able to share the surface between D3D and D2D one need to create
D2D1CreateDevice(d3dDeviceIn, property, *d2dDeviceOut);
This will create a new ID2D1Factory for the D2D code.
In effect the D2D factory is becoming device dependent (on the D3D device)
2. now there is a problem with "device independent" 2D resources such as ID2D1PathGeometry. I can't use a global factory object to create them, I should use the one of the device.
Is there a work around?
i.e. is it possible to share the D3D device and D2D device and still have a singleton ID2D1Factory object?
That will simplify my code greatly!