https://bugs.winehq.org/show_bug.cgi?id=42324
--- Comment #15 from Rastafabi f.platte@platte-web.de --- (In reply to Ken Thomases from comment #14)
Created attachment 57235 [details] Patch to restrict pixel formats for multi-renderer systems
(In reply to Rastafabi from comment #13)
[…]
I'm not sure why the old patch wouldn't apply. I've replaced it with one that's been rebased on the tip (wine-2.1-126-g06c5a9a). If it doesn't apply, please explain what you're doing and how it's failing.
In any case, a broken or misapplied patch to the opengl.c file within the Mac driver code should not break general window drawing. Programs which don't use OpenGL would not be affected by that code at all.
I'll test when I can (getting ready for vacation).
[…]
It doesn't make things immediately clearer to me, no. Are you using the same winver regardless of the build? (For example, you might be using Win7 for 64-bit but WinXP for 32-bit.)
All test were made using winver = Win7.
When you say the "issue persists with 64bit builds of the very same engines", I'm not sure which thing you kept the same and which you changed?
Difference are the prefixes: One is Wine 2.0 WINEARCH=32, one is Wine 2.0 WINEARCH=64 - both with a clean install of the 32-bit-only DirectX 9 program.
Do you mean the issue (only) affects 32-bit Windows apps running in a WoW64 Wine build?
Partly Yes. At least 32-bit Windows apps in 32-bit prefixes aren't affected. However I couldn't try 64bit (DirectX 9) apps in 64-bit prefixes as I don't know an appropriate program for this.
The problem is that it's not clear how to do things differently so that it won't be affected by the issue. The OpenGL context may be created before the window is shown on the screen or positioned on the screen where you will use it. It's actually possible to create it using an HDC from one window and then use it with a different window. It's not clear to me if, on Windows, screens connected to different GPUs count as a different "devices" in the sense of the HDC. In any case, Wine doesn't currently have the infrastructure to treat things that way.
Got it.
The Mac driver can't destroy and recreate the OpenGL context when it detects which screen the window has been shown on or moved to. The app may have done one-time configuration of the context after it was first created and the Mac driver can't make it repeat the configuration for the new context.
I think I kind of understand. But when it can't repeat configuration why not disable the need for it? -> Disable redetection of screen where it currently runs after initial window creation on whatever screen. - Just keep it running in the original context.