Results 1 to 5 of 5

Thread: Qt 5.13.0 Basic Shapes C++ example fails with MSVC 2017 (x86)

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Qt 5.13.0 Basic Shapes C++ example fails with MSVC 2017 (x86)

    Having had to replace a failing hard disk, I reinstalled Qt 5.13.0 on Windows 7 (from qt-opensource-windows-x86-5.13.0.exe), and installed VS 2017 Community. I am using a 32-bit kit: compiler MSVC 15.0 (x86), Qt version Qt 5.13.0 MSVC2017 32bit.
    The basicshapes-cpp example fails with a great number of errors, starting like this:

    QWindowsEGLStaticContext::create: Could not initialize EGL display: error 0x3001
    QWindowsEGLStaticContext::create: When using ANGLE, check if d3dcompiler_4x.dll is available
    Attempted to use GDI functions with a non-opengl32.dll library
    QWindowsGLContext::QWindowsGLContext: Unable find a suitable pixel format.
    Qt3D.Renderer.Backend: void __thiscall Qt3DRender::Render::Renderer::initialize(void) OpenGL context creation failed
    Attempted to use GDI functions with a non-opengl32.dll library
    QWindowsGLContext::QWindowsGLContext: Unable find a suitable pixel format.
    Attempted to use GDI functions with a non-opengl32.dll library
    QWindowsGLContext::QWindowsGLContext: Unable find a suitable pixel format.
    CommandThread: Failed to create local context
    Qt3D.Renderer.Backend: bool __thiscall Qt3DRender::Render::GraphicsContext::makeCurrent(c lass QSurface *) makeCurrent failed
    Qt3D.Renderer.Backend: bool __thiscall Qt3DRender::Render::GraphicsContext::makeCurrent(c lass QSurface *) makeCurrent failed
    Qt3D.Renderer.Backend: bool __thiscall Qt3DRender::Render::GraphicsContext::makeCurrent(c lass QSurface *) makeCurrent failed
    ...

    I'm guessing that the errors are a consequence of the subject of a popup when Qt Creator starts up, with the title "Plugin Loader Messages".
    "The following plugins have errors and cannot be loaded:
    QmlDesigner
    QmlProfiler

    Details:
    Plugin initialization failed: Cannot create OpenGL context."

    This seems to imply that the Qt installation from qt-opensource-windows-x86-5.13.0.exe is faulty. I chose the 32bit version because some other parts of my project are built 32bit, and to get 64bit capability will cost $. Does Qml require the 64bit Qt version? If not, what else could be the cause of this problem?

    (I tried to force use of desktop OpenGL with this:
    QCoreApplication::setAttribute(Qt::AA_UseDesktopOp enGL);
    but that generated a different set of errors.)

  2. #2
    Join Date
    Mar 2010
    Location
    Auckland, NZ
    Posts
    121
    Thanks
    9
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Qt 5.13.0 Basic Shapes C++ example fails with MSVC 2017 (x86)

    I've now confirmed that all three MSVC compiler options available with this installation fail to build a working executable for this example:
    MSVC2015 64bit
    MSVC2017 32bit
    MSVC2017 64bit

    This indicates that the problem is not related to the bitness, but rather that the installation provided by
    qt-opensource-windows-x86-5.13.0.exe is deficient where qt3d is concerned.

  3. #3
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: Qt 5.13.0 Basic Shapes C++ example fails with MSVC 2017 (x86)

    Quote Originally Posted by gib View Post
    The basicshapes-cpp example fails with a great number of errors, starting like this:

    QWindowsEGLStaticContext::create: Could not initialize EGL display: error 0x3001
    QWindowsEGLStaticContext::create: When using ANGLE, check if d3dcompiler_4x.dll is available
    Attempted to use GDI functions with a non-opengl32.dll library
    QWindowsGLContext::QWindowsGLContext: Unable find a suitable pixel format.
    Qt3D.Renderer.Backend: void __thiscall Qt3DRender::Render::Renderer::initialize(void) OpenGL context creation failed
    Attempted to use GDI functions with a non-opengl32.dll library
    ANGLE provides an OpenGL interface to Qt and uses the DirectX interface on the machine to do the rendering.
    What video card is in your machine, what card drivers, and what version of the DirectX libraries have you installed?
    Does DxDiag report any issues?
    This may be useful: https://support.microsoft.com/en-us/...ion-of-directx

    Does d3dcompiler_4x.dll exist on the PATH anywhere?

Similar Threads

  1. Migration from Qt 4.8 to Qt 5.12 Msvc 2017
    By aymenbest2 in forum Newbie
    Replies: 4
    Last Post: 18th June 2019, 09:04
  2. Problems after building Qt 5.11.2 open source 32 bit with MSVC 2017
    By ForestDweller2 in forum Installation and Deployment
    Replies: 3
    Last Post: 19th March 2019, 17:22
  3. Qt 5.9.2 WebEngine build fails with Visual Studio 2017
    By gvanvoor in forum Installation and Deployment
    Replies: 0
    Last Post: 9th November 2017, 12:12
  4. Replies: 1
    Last Post: 29th September 2011, 11:14
  5. Problem with compiling Qt 4.6 via MSVC 2010 Beta2 (win32-msvc specs)
    By Erik-Moscow in forum Installation and Deployment
    Replies: 2
    Last Post: 17th December 2009, 18:44

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.