MattClarkson / CMakeCatchTemplate

Template C++ project using CMake, CTest, Catch, and a SuperBuild for dependencies such as Boost, gflags, glog, VTK, OpenCV and PCL.
BSD 3-Clause "New" or "Revised" License
30 stars 13 forks source link

Add VL / QML example #33

Closed MattClarkson closed 6 years ago

MattClarkson commented 6 years ago

Again, testing possibilities. Can VL (visualizationlibrary.org) be used inside QML window? Testing on branch 33-add-VL.

@MicBosi - I might get round to a small demo, like putting a basic triangle / cube, rendered using VL, under a QML scene.

MicBosi commented 6 years ago

Let me know how it goes :) it should be possible though if you can use a QGLWidget in QML.

MattClarkson commented 6 years ago

@MicBosi - hi there. I just pushed 33-add-VL. I dont suppose you could try building it.

If you turn on BUILD_VL and also compile against Qt5, and turn on BUILD_QMLVLDemo then the build will download VL and compile it fine. But then there is a simple app, which as soon as I add any VL commands doesn't link. The paths all look correct to me. So Im doing something silly I presume. ny help would be appreciated. Thanks.

MattClarkson commented 6 years ago

OK - above issue resolved, I wasnt including a dependency on VLMain.

MattClarkson commented 6 years ago

@MicBosi - I'm now seeing errors like:

[ 77%] Building CXX object Code/GuiApps/QMLVLDemo/CMakeFiles/QMLVLDemo.dir/App/mpTriangleModel.cpp.o
In file included from /Users/mattclarkson/build/CMakeCatchTemplate/Code/GuiApps/QMLVLDemo/App/mpTriangleModel.cpp:15:
In file included from /Users/mattclarkson/build/CMakeCatchTemplate/Code/GuiApps/QMLVLDemo/App/mpTriangleModel.h:20:
In file included from /Users/mattclarkson/build/CMakeCatchTemplate/Code/GuiApps/QMLVLDemo/App/mpVLTriangleRenderer.h:21:
In file included from /Users/mattclarkson/build/CMakeCatchTemplate-SuperBuild-Shared-5.10/VL/install/include/vlGraphics/OpenGL.hpp:37:
In file included from /Users/mattclarkson/build/CMakeCatchTemplate-SuperBuild-Shared-5.10/VL/install/include/vlCore/Log.hpp:35:
In file included from /Users/mattclarkson/build/CMakeCatchTemplate-SuperBuild-Shared-5.10/VL/install/include/vlCore/String.hpp:35:
/Users/mattclarkson/build/CMakeCatchTemplate-SuperBuild-Shared-5.10/VL/install/include/vlCore/vlnamespace.hpp:146:36: error: use of undeclared identifier 'GL_COMPRESSED_RGB_FXT1_3DFX'
    TF_COMPRESSED_RGB_FXT1_3DFX  = GL_COMPRESSED_RGB_FXT1_3DFX,
                                   ^
/Users/mattclarkson/build/CMakeCatchTemplate-SuperBuild-Shared-5.10/VL/install/include/vlCore/vlnamespace.hpp:147:36: error: use of undeclared identifier 'GL_COMPRESSED_RGBA_FXT1_3DFX'; did
      you mean 'TF_COMPRESSED_RGB_FXT1_3DFX'?
    TF_COMPRESSED_RGBA_FXT1_3DFX = GL_COMPRESSED_RGBA_FXT1_3DFX,
                                   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
                                   TF_COMPRESSED_RGB_FXT1_3DFX

any idea? I think this is just some GL setup thing, but Im struggling to get started. Any clue?

MattClarkson commented 6 years ago

yeah - still stuck @MicBosi ??? HELP! :-)

MattClarkson commented 6 years ago

@MicBosi - sorted it. Qt 5.6 had conflicting include guards for the glext stuff.

MattClarkson commented 6 years ago

Now getting:

[ 43%] Built target VLCore
[ 55%] Built target FreeType
[ 72%] Built target VLGraphics
[ 72%] Building CXX object src/vlX/CMakeFiles/VLX.dir/Seriailzer.cpp.o
In file included from /scratch0/NOT_BACKED_UP/clarkson/build/CMakeCatchTemplate-shared/VL/src/src/vlX/Seriailzer.cpp:35:0:
/scratch0/NOT_BACKED_UP/clarkson/build/CMakeCatchTemplate-shared/VL/src/src/vlX/ParserVLT.hpp:37:27: fatal error: vlX/defines.hpp: No such file or directory
 #include <vlX/defines.hpp>
MattClarkson commented 6 years ago

Parking this one for now.