2

我一直在寻找一个跨平台的 GUI 应用程序开发框架(用于构建 Linux、Android、Windows 应用程序和 OS X 的相同代码),我发现 Qt 最适合这个框架(受到启发,因为 VLC 媒体播放器是用 Qt 构建的)。

首先在 Ubuntu 中安装它,我在构建示例时遇到了一些问题,但我设法解决了它,并且 Qt 中给出的每个示例都运行良好。

但是在 Windows 中,除了“Boxes”示例之外,每个示例都可以正常工作。 在此处输入图像描述

问题:

warning: Qt was built with ANGLE, which provides only OpenGL ES 2.0 on top of DirectX 9.0c
error: This example requires Qt to be configured with -opengl desktop

安装 Qt 5.0.2 for Windows 32-bit (VS 2010, OpenGL, 476 MB)

error: Qt Creator needs a compiler set up to build. Configure a compiler in the kit options.

所以,我检查了构建和运行选项,它显示 在此处输入图像描述

4

2 回答 2

2

您需要使用 opengl 桌面选项构建 qt。

http://qt-project.org/downloads

寻找Qt 5.0.2 for Windows 32-bit (VS 2010, OpenGL, 476 MB)

http://download.qt-project.org/official_releases/qt/5.0/5.0.2/qt-windows-opensource-5.0.2-msvc2010_32_opengl-x86-offline.exe.mirrorlist

安装此 qt 版本后,您的示例应该可以工作

于 2013-05-07T09:20:00.047 回答
1

安装后问题解决

  1. 微软视觉工作室 2010
  2. 适用于 Windows 32 位的 Qt 5.0.2(VS 2010,OpenGL,476 MB)

Qt5***.dll但是,当我打开它显示丢失的已编译 exe 文件时,单独运行 Qt 形式的程序可以工作。

解决缺少的 dll :

exeDependency Walker中打开编译,它将显示所有丢失的 dll。现在去 \Qt\Qt5.0.2\5.0.2\msvc2010_opengl\bin 那里我们可以找到所有 Qt5***.dll 将其复制并粘贴到该exe位置。

于 2013-05-08T21:29:23.403 回答