RtCW: GLW_StartOpenGL() issue

Questions about Wine on macOS.
Locked
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

RtCW: GLW_StartOpenGL() issue

Post by SiRGadaBout »

Hi,

WINE 1.2.2, Return to Castle Wolfenstein retail patched to 1.4.1, OS X 10.6.6, Mac Pro 2010 with ATI 5770.

The error message is as stated in the title. According to a post here:
Newer AMD and NVIDIA drivers have so many OpenGL Extensions that Quake 3 engine based games crash when probing the extensions at game launch.

2 solutions:

Download these fixed binaries (are also nocd patched)

OR

If using the NVIDIA proprietary driver you can start the game prefixed with: __GL_ExtensionStringVersion=17700
Unfortunately the fixed binaries are for Star Wars: Jedi Knight - Jedi Academy, and the GL switch doesn't improve things in my case, probably because I don't have the nVidia proprietary driver. The FAQ says it's not possible to install drivers in WINE, so... I'm stuck.

Any help available?

Here's the full log from the Wolf Console:

Code: Select all

Wolf 1.32 win-x86 May  1 2002
----- FS_Startup -----
Current search path:
C:\Program Files\Return to Castle Wolfenstein\main\sp_pak3.pk3 (14 files)
C:\Program Files\Return to Castle Wolfenstein\main\sp_pak2.pk3 (232 files)
C:\Program Files\Return to Castle Wolfenstein\main\sp_pak1.pk3 (1342 files)
C:\Program Files\Return to Castle Wolfenstein\main\pak0.pk3 (4775 files)
C:\Program Files\Return to Castle Wolfenstein/main

----------------------
6363 files in pk3 files
execing default.cfg
couldn't exec language.cfg
couldn't exec wolfconfig.cfg
execing autoexec.cfg
Hunk_Clear: reset the hunk ok
...detecting CPU, found Intel Pentium III
Bypassing CD checks
----- Client Initialization -----
Cmd_AddCommand: map_restart already defined
----- Initializing Renderer ----
-------------------------------
----- Client Initialization Complete -----
----- R_Init -----
Initializing OpenGL subsystem
...initializing QGL
...calling LoadLibrary( 'C:\windows\system32\opengl32.dll' ): succeeded
...setting mode 3: 640 480 FS
...using desktop display depth of 32
...calling CDS: failed, bad mode
...trying next higher resolution: failed, DISP_CHANGE_FAILED
...restoring display settings
...registered window class
...created window@0,0 (646x505)
Initializing OpenGL driver
...getting DC: succeeded
...GLW_ChoosePFD( 32, 24, 8 )
...numPFDs > MAX_PFDS (544 > 256)
...255 PFDs found
...hardware acceleration found
...PIXELFORMAT 149 selected
...creating GL context: succeeded
...making context current: succeeded
...WARNING: fullscreen unavailable in this mode
...setting mode 3: 640 480 FS
...using colorsbits of 16
...calling CDS: failed, bad mode
...trying next higher resolution: failed, DISP_CHANGE_FAILED
...restoring display settings
...window already present, CreateWindowEx skipped
Initializing OpenGL driver
...WARNING: fullscreen unavailable in this mode
...shutting down QGL
...unloading OpenGL DLL
...assuming '3dfxvgl' is a standalone driver
...initializing QGL
...WARNING: missing Glide installation, assuming no 3Dfx available
...shutting down QGL
----- CL_Shutdown -----
RE_Shutdown( 1 )
-----------------------
GLW_StartOpenGL() - could not load OpenGL subsystem
S.
James McKenzie

RtCW: GLW_StartOpenGL() issue

Post by James McKenzie »

On 1/19/11 1:59 PM, SiRGadaBout wrote:
Hi,

WINE 1.2.2, Return to Castle Wolfenstein retail patched to 1.4.1, OS X 10.6.6, Mac Pro 2010 with ATI 5770.

The error message is as stated in the title. According to a post here:
Newer AMD and NVIDIA drivers have so many OpenGL Extensions that Quake 3 engine based games crash when probing the extensions at game launch.
This warning is for Linux. MacOSX drivers are created by Apple and the
Vendor.

2 solutions:

Download these fixed binaries (are also nocd patched)
You can try this. However, I don't expect this to fix your problem.
Unfortunately the fixed binaries are for Star Wars: Jedi Knight - Jedi Academy, and the GL switch doesn't improve things in my case, probably because I don't have the nVidia proprietary driver. The FAQ says it's not possible to install drivers in WINE, so... I'm stuck.
The nVidia Proprietary drivers are installed on Linux. MacOSX does not
have a proprietary nVidia driver.

The problem may be that you are using MacOSX' broken X11. Please try to
install XQuartz 2.6.0 or later and see if the error 'goes away'.

James McKenzie
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Hi,

Thanks for replying. I complied WINE 1.2.2 myself. Will I have to re-compile and link to XQuartz's own OpenGL libraries instead of X11's?

S.
James McKenzie

RtCW: GLW_StartOpenGL() issue

Post by James McKenzie »

On 1/20/11 3:23 AM, SiRGadaBout wrote:
Hi,

Thanks for replying. I complied WINE 1.2.2 myself. Will I have to re-compile and link to XQuartz's own OpenGL libraries instead of X11's?
I would try that. Also using MacPorts or Fink will bring in the
required dependencies and link to proper OpenGL files and detect
MacOSX's built-in fontconfig for Leopard and SnowLeopard.

James McKenzie
Thunderbird
Level 5
Level 5
Posts: 336
Joined: Mon Nov 24, 2008 8:10 am

Post by Thunderbird »

This environment variable was meant for the Linux Nvidia OpenGL drivers. It also exists in Windows using some registry key, but I have no idea whether it exists on OSX at all. The OpenGL drivers work very differently. I doubt you can get it to work at all. Just rebuilding your stuff won't work.

There is already a mechanism to disable OpenGL extensions in Wine which could be used, but I'm not sure which have to be disabled to make Quake3 games happy. The issue itself is in the game which creates a too small buffer to handle all GL extensions, but I forgot what's happening internally again which made it fail.

I will report back on this.
Thunderbird
Level 5
Level 5
Posts: 336
Joined: Mon Nov 24, 2008 8:10 am

Post by Thunderbird »

The number is 4096, so essentially disable a ton of pre-GL 2.0 extensions using the DisabledExtensions key in the registry.
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

OK, I downloaded OpenGL ExtensionsViewer, and expanded all the "supported" sub-lists. Then I opened regedit in wine, navigated to HKCU/Software/wine and created a new key,"OpenGL." Within this Key I created a new String Value (REG_SZ) called "DisabledExtensions." I right-clicked this new String Value and chose Modify. In the available entry field I then entered every OpenGL extension listed by OpenGL Extensions Viewer as being "Supported," and which was part of OpenGL 1.5 or older. I separated them with a single space. This amounted to 42 separate, space-separated values.

I closed regedit. I ran wine WolfSP.exe. Unfortunately, I still receive the same error :(

Have I made a mistake somewhere?

Regards,

S.
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Post by vitamin »

SiRGadaBout wrote:Have I made a mistake somewhere?
You can check that with:

Code: Select all

WINEDEBUG=+wgl wine game.exe 2>&1 | less
It should say somewhere at the top what it did with extra extensions.
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Hi,

I found this:

Code: Select all

trace:wgl:process_attach found DisabledExtensions="GL_EXT_blend_logic_op GL_EXT_copy_texture GL_EXT_polygon_offset GL_EXT_subtexture GL_EXT_texture GL_EXT_texture_object GL_EXT_vertex_array GL_EXT_bgra GL_EXT_draw_range_elements GL_EXT_packed_pixels GL_EXT_rescale_normal GL_EXT_separate_specualr_color GL_EXT_texture3D GL_SGIS_texture_edge_clamp GL_SG"...
Does this match what would be expected if I had properly created the Registry Key and entry?

By the way, very appreciative of the assistance here. :)

S.
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Post by vitamin »

SiRGadaBout wrote:Does this match what would be expected if I had properly created the Registry Key and entry?
Not quite. You need to look for list that start with "GL_EXTENSIONS reported:" line enumerating all extensions, followed by "active" or "deactived (by config)".
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

It appears, then, that I haven't implemented the Registry change correctly then, as no such code appears in the Terminal :(

The problem is, I've no information as to how to create this particular registry entry. My options, after right-clicking in the OpenGL Key window, are to create a new String value, Binary value, DWORD value or Multi String value---which is it? It doesn't appear to be Binary or DWORD as they appear to only accept numerals as input. If it's Multi String Value, do I hit enter after creating each GL_ value or simply leave a space as advised in the wiki?
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Aww, no more help forthcoming on this issue? From what I've read elsewhere, this could be a popular tip if it was figured out and I entered it in the wiki... :wink:
User avatar
dimesio
Moderator
Moderator
Posts: 13208
Joined: Tue Mar 25, 2008 10:30 pm

Post by dimesio »

SiRGadaBout wrote:Aww, no more help forthcoming on this issue? From what I've read elsewhere, this could be a popular tip if it was figured out and I entered it in the wiki... :wink:
Reading what's already in the wiki might prove helpful. http://wiki.winehq.org/UsefulRegistryKeys
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Hmm, I'm calling troll on you dimesio. Find something more constructive to do with your time :)
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Hmm, OK dimesio, after reading through other threads that it turned out you'd responded to I surmise you're not a troll, so apologies. However, your response was both terse and lacking evidence of awareness of my prior posts, so I think it was a fair initial assumption.

I detailed in my 3rd response the steps I took to implement the registry entry required to disable certain OpenGL extensions. So far as I am aware I followed all the instructions available on the page you link to. The instructions are somewhat lacking in specifics, hence my subsequent response that I was unsure exactly how to implement this modification and my request for further info.

Is there something on the page you link to that I'm overlooking? I have had a further look and don't believe there's anything relevant I've missed.
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Ok, it does appear that I missed some pertinent information at the top of the page, where it does state clearly:
All values are strings (REG_SZ) unless stated otherwise.
For that I apologise. :)

However, if I might quote my earlier post:
I opened regedit in wine, navigated to HKCU/Software/wine and created a new key,"OpenGL." Within this Key I created a new String Value (REG_SZ) called "DisabledExtensions." I right-clicked this new String Value and chose Modify. In the available entry field I then entered every OpenGL extension listed by OpenGL Extensions Viewer as being "Supported," and which was part of OpenGL 1.5 or older. I separated them with a single space.
It transpires that I intuitively followed the correct course of action anyway. as demonstrated by the text in bold in my quote above (the text in italics demonstrates that I was implementing the fix suggested by Thunderbird). Nevertheless, I still don't receive the output that vitamin claims I should if this entry has been properly created.

I ran vitamin's debug command again, and I'm listing here only the initial portion up until the last mention of "extensions":

Code: Select all

trace:wgl:wglGetProcAddress func: 'wglGetIntegerv'
trace:wgl:X11DRV_WineGL_InitOpenglInfo GL version             : 2.1 ATI-1.6.26.
trace:wgl:X11DRV_WineGL_InitOpenglInfo GL renderer            : ATI Radeon HD 5770 OpenGL Engine.
trace:wgl:X11DRV_WineGL_InitOpenglInfo GLX version            : 1.2.
trace:wgl:X11DRV_WineGL_InitOpenglInfo Server GLX version     : 1.2.
trace:wgl:X11DRV_WineGL_InitOpenglInfo Server GLX vendor:     : SGI.
trace:wgl:X11DRV_WineGL_InitOpenglInfo Client GLX version     : 1.4.
trace:wgl:X11DRV_WineGL_InitOpenglInfo Client GLX vendor:     : Mesa Project and SGI.
trace:wgl:X11DRV_WineGL_InitOpenglInfo Direct rendering enabled: True
trace:wgl:has_opengl GLX is up and running error_base = 147
trace:wgl:register_extension_string ''
trace:wgl:register_extension     - 'wglGetIntegerv'
trace:wgl:register_extension     - 'wglFinish'
trace:wgl:register_extension     - 'wglFlush'
trace:wgl:register_extension_string 'WGL_ARB_extensions_string'
trace:wgl:register_extension     - 'wglGetExtensionsStringARB'
trace:wgl:register_extension_string 'WGL_ARB_multisample'
trace:wgl:register_extension_string 'WGL_ARB_pixel_format'
trace:wgl:register_extension     - 'wglChoosePixelFormatARB'
trace:wgl:register_extension     - 'wglGetPixelFormatAttribfvARB'
trace:wgl:register_extension     - 'wglGetPixelFormatAttribivARB'
trace:wgl:register_extension_string 'WGL_EXT_extensions_string'
trace:wgl:register_extension     - 'wglGetExtensionsStringEXT'
trace:wgl:register_extension_string 'WGL_EXT_swap_control'
trace:wgl:register_extension     - 'wglSwapIntervalEXT'
trace:wgl:register_extension     - 'wglGetSwapIntervalEXT'
trace:wgl:register_extension_string 'WGL_WINE_pixel_format_passthrough'
trace:wgl:register_extension     - 'wglSetPixelFormatWINE'
trace:wgl:X11DRV_wglGetProcAddress ('wglGetIntegerv'):                  (0x449677f0) - WineGL
trace:wgl:wglGetProcAddress func: 'wglFinish'
trace:wgl:X11DRV_wglGetProcAddress ('wglFinish'):                       (0x44967920) - WineGL
trace:wgl:wglGetProcAddress func: 'wglFlush'
trace:wgl:X11DRV_wglGetProcAddress ('wglFlush'):                        (0x4496a250) - WineGL
trace:wgl:process_attach found DisabledExtensions="GL_EXT_blend_logic_op"
I'm doing my best here, and trying to be as precise and forthcoming as possible. Is there any chance of getting some further help?

Regards,

S.
User avatar
DanKegel
Moderator
Moderator
Posts: 1164
Joined: Wed May 14, 2008 11:44 am

Post by DanKegel »

dimesio is very much not a troll :-) but the page she pointed you to,
http://wiki.winehq.org/UsefulRegistryKeys
just describes what you already did.

I think what Vitamin is saying is, you need to look at your log again
for the line
trace:wgl:GL_EXTENSIONS reported
The lines following that will tell you if you managed to disable
each extension.

Or if you're handy with C, write a tiny program that initializes
opengl and calls glGetString, that has the same info.

See http://source.winehq.org/git/wine.git/? ... wgl.c#l628 if you can read C for an idea of the output format.
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

Post by SiRGadaBout »

Hi,

Thanks for responding, Dan! :) Yes, I accept that dimesio isn't a troll, and I do apologise for that.

Um, just to confirm that the log you're referring to is the one printed in Terminal after running the debug command I mentioned above? If that's the only log I'm supposed to be looking at then I can categorically state that the line:

Code: Select all

trace:wgl:GL_EXTENSIONS reported
does not appear anywhere or at anytime. In fact, a text search reveals no lines beginning:

Code: Select all

trace:wgl:GL
exist either.

What do I do next now that you've confirmed that I appear to have followed the instructions correctly?

Regards,

S.

PS: oh, btw I don't have any coding experience with C (or any other language beyond some extremely basic FORTRAN or PASCAL way back when I was at school :) ). Oh well.
SiRGadaBout
Level 2
Level 2
Posts: 17
Joined: Sun Aug 03, 2008 3:24 pm

|SOLVED| RtCW: GLW_StartOpenGL() issue

Post by SiRGadaBout »

Went to the #winehq IRC channel and was told the following:
your issues are 1) running a game with a native version in wine
2) not having working 3d at all
or actually, not having 640x480
The offered solution was to run the game with the following command switch:

Code: Select all

+set r_fullscreen 0
This works fine - RtCW now runs flawlessly. I'll add a note to the AppDB with my experiences.

Credit to Kevlarman for the solution.

S.
chootia
Newbie
Newbie
Posts: 2
Joined: Tue Aug 16, 2011 2:19 am

Post by chootia »

Well I had already cleaned out all old drivers and reinstalled my catalyst drivers and it still would not work. I could only find the Opengl.dll file, couldnt find the .lib file nor the 3dfxgl.dll in my game directory that he told me to delete. So I put the file in there and tried it it worked and let me join servers (From Pathfinder) but menu buttons such as quit etc at main menus did not work. Then I remembered I had not patched to 1.41 since I reinstalled so I patched it and it seems to be working fine.
Anyways, thanks for the help guys, I hope it keeps working lol.
andrea147
Newbie
Newbie
Posts: 2
Joined: Tue Sep 27, 2011 6:25 am

Post by andrea147 »

I'm having the same exact problems with my new Gainward Geforce4 card, but most of the time games just crash and hang without any error message (only with one very old nvidia driver could I get it to give an error message, and that was the same message you got).
Locked