http://bugs.winehq.org/show_bug.cgi?id=7696
------- Additional Comments From stefandoesinger@gmx.at 2007-19-03 07:36 ------- Ok, no multithreaded Direct3D. Good.
It seems that there are 2 different wined3d devices used in the same thread. This is not handled yet. The problem that arises is that each device uses its own opengl context, and only one context can be active at a time.
We have to keep track of the last active device in a thread local storage and check it before activating the context. For context creation we should leave the newly created context active unless a different context is used instead of blindly activating the old context.
It is also strange that activating the old context fails, and not using it. Maybe it is a reference counting problem, and the old device should be destroyed. Can you attach a +d3d9 trace?