Opened 12 years ago

Last modified 3 years ago

#1419 new defect

[PATCH] Report nice error messages to Windows users with missing hardware-accelerated OpenGL drivers

Reported by: Philip Taylor Owned by:
Priority: Should Have Milestone: Backlog
Component: Core engine Keywords: patch, simple
Cc: historic_bruno Patch:

Description

About 4% of our Windows users (of those who enable feedback) don't have working hardware-accelerated OpenGL drivers installed, which means they get the GDI Generic driver, which is terrible and slow and will cause ugly error messages (about missing multitexture extensions etc) and incorrect rendering. (At least the main menu should start and render mostly correctly without crashing, though.)

I'd guess (based on no evidence) that most people do have adequate graphics hardware, and there's just a problem with their drivers. (You can test this by e.g. renaming nvoglv32.dll (on NVIDIA) - Windows should automatically fall back to the software renderer.)

Since it's so common, we probably ought to detect that case and report a nice error message (perhaps via a dialog box in the in-game GUI, if that's fast enough, and get rid of the ugly assertion failures before that), telling people there's a problem and telling them to install the latest graphics drivers for their machine.

Attachments (1)

GameSetup.cpp.patch (3.6 KB ) - added by Michael Laporte 11 years ago.

Download all attachments as: .zip

Change History (20)

comment:1 by Mark Summers, 12 years ago

Owner: set to Mark Summers
Status: newassigned

Started work on this - ETA 7 days (conservative estimate, it shouldn't take long at all once I get my head around the source)

in reply to:  1 comment:2 by leper, 11 years ago

Owner: Mark Summers removed
Status: assignednew

Replying to tehmark:

Started work on this - ETA 7 days [...]

I guess you're not working on this anymore, so I'll unassign you.

comment:3 by Michael Laporte, 11 years ago

Looking at this, I commented out the calls to DEBUG_DISPLAY_ERROR() in GameSetup.cpp that were just after the olg_HaveExtensions() calls, and it now seems to go straight to the in-game dialog box warning about using non-shader (fixed function) graphics. Does this accomplish what is wanted? Or do we want to be more specific about not having OpenGL at all? The problem with that is we then will most likely have 2 "nag" warnings tied to not having OpenGL.

comment:4 by Michael Laporte, 11 years ago

Sorry, olg_HaveExtensions() = ogl_HaveExtensions().

by Michael Laporte, 11 years ago

Attachment: GameSetup.cpp.patch added

comment:5 by Michael Laporte, 11 years ago

Keywords: review patch added
Milestone: BacklogAlpha 15
Owner: set to Michael Laporte
Status: newassigned
Summary: Report nice error messages to Windows users with missing hardware-accelerated OpenGL drivers[PATCH]Report nice error messages to Windows users with missing hardware-accelerated OpenGL drivers

comment:6 by Michael Laporte, 11 years ago

Patch submitted. Tested by renaming file c:\windows\system32\nvoglnt.dll file which results in 3 Windows style message boxes being displayed due to various missing OpenGL extensions. Renaming file back to normal results in no message boxes being displayed.

comment:7 by Michael Laporte, 11 years ago

Keywords: simple, review patch → simple review patch

comment:8 by sanderd17, 10 years ago

Cc: historicBruno added

Someone with some Windows knowledge should take a look at this.

comment:9 by sanderd17, 10 years ago

Cc: historicbruno added; historicBruno removed

comment:10 by leper, 10 years ago

Cc: historic_bruno added; historicbruno removed

comment:11 by historic_bruno, 10 years ago

Keywords: review removed
Summary: [PATCH]Report nice error messages to Windows users with missing hardware-accelerated OpenGL drivers[PATCH] Report nice error messages to Windows users with missing hardware-accelerated OpenGL drivers

The native dialog is certainly an improvement on Windows, but does this ever happen on *nix? sys_display_msg is implemented as printf on those platforms, which is definitely a regression. It won't even be seen unless run from the terminal, and even then it's much easier to miss compared to the ugly old error dialog.

comment:12 by wraitii, 10 years ago

Milestone: Alpha 15Alpha 16

comment:13 by Stan, 10 years ago

There is an implemented function in the SDL to this crossplatforms I think can someone have a look at this http://stackoverflow.com/questions/17319180/sdl-cross-platform-message-box-for-linux

comment:14 by Stan, 10 years ago

Milestone: Alpha 16Alpha 17

SDL 1.2 is not fully supported yet so pushing it to A17

in reply to:  14 comment:15 by historic_bruno, 10 years ago

Milestone: Alpha 17Backlog
Owner: Michael Laporte removed
Status: assignednew

Replying to stanislas69:

SDL 1.2 is not fully supported yet so pushing it to A17

You mean SDL 2.0?

I'm going to backlog this since there hasn't been progress, it's not a serious issue, and the current patch doesn't adequately solve the ticket.

comment:16 by fabio, 8 years ago

This is somewhat addressed in r17339: a warning is now printed when GDI Generic or other software renderers are detected. mackeul patch should improve the dialog when using very old OpenGL version, no idea if it is still needed.

comment:17 by Andy Alt, 8 years ago

Niemetal on IRC has expressed an interest on working on this. Is it still needed?

comment:18 by Silier, 3 years ago

Keywords: simple removed
severity: simple

comment:19 by Silier, 3 years ago

Keywords: simple added
Note: See TracTickets for help on using tickets.