Where is Qt 5 Qt3D QCircularBuffer?

Viewed 212

I would like to try QCircularBuffer, as per https://doc.qt.io/archives/qt-5.5/qt3d-qcircularbuffer.html, so I created a simple Qt (5.15.1) project on QtCreator on macOS. It looks like the following:

#include <QApplication>
#include <QWidget>

#include <Qt3D>

int main(int argc, char *argv[]) {
    QApplication a(argc, argv);
    QWidget w;
    w.show();
    return a.exec();
}

And in project file I have

QT += core gui widgets 3dcore

But I cannot build this, I got:

18:48:09: Running steps for project project...
18:48:09: Configuration unchanged, skipping qmake step.
18:48:09: Starting: "/usr/bin/make" -j8
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang++ -c -pipe -stdlib=libc++ -g -std=gnu++1z  -arch x86_64 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -mmacosx-version-min=10.13 -Wall -Wextra -fPIC -DQT_QML_DEBUG -DQT_WIDGETS_LIB -DQT_3DCORE_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -I. -I../../Qt5.15.1/5.15.1/clang_64/lib/QtWidgets.framework/Headers -I../../Qt5.15.1/5.15.1/clang_64/lib/Qt3DCore.framework/Headers -I../../Qt5.15.1/5.15.1/clang_64/lib/QtGui.framework/Headers -I../../Qt5.15.1/5.15.1/clang_64/lib/QtNetwork.framework/Headers -I../../Qt5.15.1/5.15.1/clang_64/lib/QtCore.framework/Headers -Idebug -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/OpenGL.framework/Headers -I/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/AGL.framework/Headers -I../../Qt5.15.1/5.15.1/clang_64/mkspecs/macx-clang -F/Users/user/Qt5.15.1/5.15.1/clang_64/lib -o debug/main.o main.cpp
main.cpp:6:10: fatal error: 'Qt3D' file not found
#include <Qt3D>
         ^~~~~~
1 error generated.
make: *** [debug/main.o] Error 1
18:48:10: The process "/usr/bin/make" exited with code 2.
Error while building/deploying project project (kit: Desktop Qt 5.15.1 clang 64bit)
The kit Desktop Qt 5.15.1 clang 64bit has configuration issues which might be the root cause for this problem.
When executing step "Make"

It looks like I'm doing something wrong, right?

1 Answers

please add QT += 3dcore to your .pro file of your project.

if error remains, your module “Qt3D.Core” is not installed. please install it and recompile your project again.

Related