Note that there are some explanatory texts on larger screens.

plurals
  1. POWindows 7 64bit, Qt 4: glGetVersion returns "1.1.0", nvogl32v.dll gets unloaded
    primarykey
    data
    text
    <p><strong>situation</strong></p> <p>I'm developing 32bit application that uses Qt 4, and I"m working on Windows 7 64bit.</p> <p>My program has main non-OpenGL widget, and QGLWidget which is optionally opened by the user.</p> <p><strong>problem:</strong></p> <p>When I create that <code>QGLWidget</code>, <code>glGetVersion</code> reports "1.1.0" (my hardware supports OpenGL 4.3.0). As a result many functions I need do not work at all (obviosuly, because they are not available in OpenGL 1). This problem happens "sometimes". </p> <p><strong>additional info</strong></p> <p>IF I launch program using gDebugger everything works fine, and glGetVersion returns "4.3.0", as expected. Adding this line:</p> <pre><code>QGLFormat::OpenGLVersionFlags flags = QGLFormat::openGLVersionFlags(); </code></pre> <p>at the beginning of main() function also fixes the problem.</p> <p>The application works fine on WinXP 32bit. </p> <p>I wrote OpenGL subsystem for this app 2..3 years ago and the guys who used it said they had similar problem on virtual machines (Win7 or vista guest), but I don't remember how I dealt with this problem at that time.</p> <p><strong>OpenGL initialization</strong></p> <p><em>OpenGL initialization is performed by Qt 4</em>, without glew or extra libraries, using QGLWidget.</p> <p>There's only one QGLWidget in the program. To be precise, there's a class derived from QGLWidget, its initalization looks like this:</p> <pre><code>DisplayWidget::DisplayWidget(QWidget* parent) : QGLWidget(QGLFormat(QGL::DoubleBuffer | QGL::DepthBuffer), parent) </code></pre> <p><strong>System configuration</strong>:<br> OS: Windows 7 64bit.<br> Compiler: MSVC2008 express SP1.<br> Qt: Qt 4.8.1 (compiled from source with OpenSSL support using MSVC2008). Windows SDK: Windows Server 2008 and .NET 3.5. GPU: GeForce 460 GTX</p> <p><strong>question</strong>:</p> <p>What could be causing this problem?</p> <p>--update--</p> <p>"magical fix" (OpenGLVersionFlags) has stopped working after full rebuild, and now application constantly initializes software renderer, even when launched using gDebugger. </p> <p>All other OpenGL applications on my machine work fine and can use shaders.</p> <p>I use latest drivers.</p> <p>Any ideas?</p> <p>--update--</p> <p>After some testing I found that somehow google chrome and steam client affect all Qt application that use OpenGL.</p> <p>If I have Google Chrome and Steam open, eventually all programs will stop working properly and will no longer be able to get hardware accelerated OpenGL.</p> <p>If I close google chrome and keep steam open, every 2nd attempt to launch hardware accelerated program will fail. </p> <p>If I close both steam and chrome, then every program launch will be successful. </p> <p>Why could this be happening? </p> <p>--update--</p> <p>I've read through debugger output, and found a very interesting thing:</p> <pre><code>'vdclient.exe': Loaded 'C:\Windows\SysWOW64\nvoglv32.dll' First-chance exception at 0x777f47a5 (ntdll.dll) in vdclient.exe: 0xC0000005: Access violation reading location 0x05aa9000. 'vdclient.exe': Unloaded 'C:\Windows\SysWOW64\nvoglv32.dll' </code></pre> <p>Basically, when loading nvoglv32.dll, "something" crahses somewhere (debugger doesn't react to this event, byt the way), and system decides to unload nvoglv32.dll. Judging by its name it is nvidia system/driver component, and without this component there can be no hardware acceleration. </p> <p>When opengl works properly, this part of log looks like this:</p> <pre><code>'vdclient.exe': Loaded 'C:\Windows\SysWOW64\nvoglv32.dll' 'vdclient.exe': Loaded 'C:\Windows\SysWOW64\ntmarta.dll', Symbols loaded (source information stripped). 'vdclient.exe': Loaded 'C:\Windows\SysWOW64\Wldap32.dll', Symbols loaded (source information stripped). 'vdclient.exe': Loaded 'C:\Windows\SysWOW64\powrprof.dll', Symbols loaded (source information stripped). The thread 'Win32 Thread' (0x1744) has exited with code 0 (0x0). The thread 'Win32 Thread' (0x1740) has exited with code 0 (0x0). 'vdclient.exe': Unloaded 'C:\Windows\SysWOW64\powrprof.dll' The thread 'Win32 Thread' (0x1748) has exited with code 0 (0x0). The thread 'Win32 Thread' (0x174c) has exited with code 0 (0x0). 'vdclient.exe': Loaded 'C:\Windows\SysWOW64\uxtheme.dll', Symbols loaded (source information stripped). </code></pre> <p>Ideas?</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload