Page 1 of 1

Build QLC+ with Qt 6.7.0

Posted: Mon Apr 08, 2024 6:48 pm
by sbenejam
I'm trying to build QLC+ 4 latest sources with Qt 6.7.0 on Ubuntu 22.04 and I get the following error:

Code: Select all

[ 52%] Building CXX object engine/test/grandmaster/CMakeFiles/grandmaster_test.dir/grandmaster_test.cpp.o
In file included from /home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/qabstractitemmodel.h:8,
                 from /home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/QtCore:19,
                 from /home/sbenejam/Qt/6.7.0/gcc_64/include/QtTest/QtTestDepends:3,
                 from /home/sbenejam/Qt/6.7.0/gcc_64/include/QtTest/QtTest:3,
                 from /home/sbenejam/qlctest/engine/test/efxfixture/efxfixture_test.cpp:21:
/home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/qhash.h: In instantiation of ‘struct QHashPrivate::Node<unsigned int, FadeChannel>’:
/home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/qhash.h:449:11:   required from ‘struct QHashPrivate::Data<QHashPrivate::Node<unsigned int, FadeChannel> >’
/home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/qhash.h:1257:71:   required from ‘qsizetype QHash<Key, T>::count() const [with Key = unsigned int; T = FadeChannel; qsizetype = long long int]’
/home/sbenejam/qlctest/engine/test/efxfixture/efxfixture_test.cpp:458:5:   required from here
/home/sbenejam/Qt/6.7.0/gcc_64/include/QtCore/qhash.h:76:7: error: ‘QHashPrivate::Node<Key, T>::value’ has incomplete type
   76 |     T value;
      |       ^~~~~
In file included from /home/sbenejam/qlctest/engine/test/efxfixture/../mastertimer/mastertimer_stub.h:25,
                 from /home/sbenejam/qlctest/engine/test/efxfixture/efxfixture_test.cpp:28:
/home/sbenejam/qlctest/engine/test/efxfixture/../../src/mastertimer.h:32:7: note: forward declaration of ‘class FadeChannel’
   32 | class FadeChannel;
      |       ^~~~~~~~~~~
[ 52%] Linking CXX executable fadechannel_test
[ 52%] Linking CXX executable fixturegroup_test
make[2]: *** [engine/test/efxfixture/CMakeFiles/efxfixture_test.dir/build.make:104: engine/test/efxfixture/CMakeFiles/efxfixture_test.dir/efxfixture_test.cpp.o] Error 1
make[1]: *** [CMakeFiles/Makefile2:3416: engine/test/efxfixture/CMakeFiles/efxfixture_test.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 52%] Building CXX object engine/test/function/CMakeFiles/function_test.dir/function_test.cpp.o
[ 52%] Built target fadechannel_test
[ 52%] Linking CXX executable efx_test
[ 52%] Built target fixturegroup_test
[ 53%] Linking CXX executable fixture_test
[ 53%] Built target efx_test
[ 53%] Built target fixture_test
[ 53%] Linking CXX executable grandmaster_test
[ 54%] Linking CXX executable genericfader_test
[ 54%] Built target grandmaster_test
[ 54%] Built target genericfader_test
[ 55%] Linking CXX executable function_test
[ 55%] Built target function_test
make: *** [Makefile:156: all] Error 2
sbenejam@migjorn:~/qlctest/build$ 

Re: Build QLC+ with Qt 6.7.0

Posted: Tue Apr 09, 2024 6:17 am
by hansjuergen
QLCplus is currently built based on QT 5.14.2: https://github.com/mcallegari/qlcplus/b ... ld.yml#L72

If you are knowledgeable about QT upgrades, feel free to adapt the code to support the needs of QT 6.x, I'd say.
I am not and briefly tried after we ran into a QT 5.14.2 bug, but it requires more knowledge about the meaning of the error messages than I have today.
There are certainly some people who have done such upgrades before, are you one of them?

Re: Build QLC+ with Qt 6.7.0

Posted: Tue Apr 09, 2024 7:27 am
by janosvitok
The attached patch allows compilation with Qt6.7, but most probably breaks QT5 compilation - must be #Ifdef'ed

Re: Build QLC+ with Qt 6.7.0

Posted: Tue Apr 09, 2024 9:14 am
by mcallegari
Proper fix upstream

Re: Build QLC+ with Qt 6.7.0

Posted: Tue Apr 09, 2024 5:03 pm
by sbenejam
I just build QLC+ 4 with Qt 6.7.0 without errors. Video playback starts without delay. The audio from the video is not played.
Compiled with Qt5 video and audio from the video works. For the video to be played without delay it must be played a couple of times first.
Environment:
Ubuntu 22.04
Qt5 from Ubuntu
Qt 6.7.0 with QT Online Installer
Pipewire 1.0.3 from a Ubuntu PPA

Re: Build QLC+ with Qt 6.7.0

Posted: Thu Apr 11, 2024 9:09 am
by mcallegari
Audio issue should be fixed now upstream

Re: Build QLC+ with Qt 6.7.0

Posted: Thu Apr 11, 2024 9:12 am
by sbenejam
I'll test it later.

Re: Build QLC+ with Qt 6.7.0

Posted: Thu Apr 11, 2024 2:41 pm
by sbenejam
Works as expected now. Tested with *.mp4 and *.ogg video test files. One more thing *.ogg files don't appear in Files of type dropdown when you add a video file. You need to show all file types to add it.

Re: Build QLC+ with Qt 6.7.0

Posted: Sat Apr 13, 2024 10:48 am
by sbenejam
After some tests with QLC+ build with Qt6.7.0 on Ubuntu 22.04 it seems to work without delays (tested with 2 laptops).
Maybe now is a good time to add the option to choose the output audio device to play audio from videos, as you can already do with audio functions.

Re: Build QLC+ with Qt 6.7.0

Posted: Sat Apr 13, 2024 12:50 pm
by mcallegari
Yes, I think with the switch to Qt6 it could be a nice feature to add

Re: Build QLC+ with Qt 6.7.0

Posted: Sat Apr 20, 2024 5:30 pm
by sbenejam
Hi Massimo, I'm testing QLC+ 4.13.1 GIT build with Qt 6.7.0 running on Ubuntu 22.04 with Pipewire 1.0.3. In the I/O Audio tab some inputs and outputs are missing (monitors, mics, etc.). It seems that QAudioInput and QAudioOutput in Qt5 are now called QAudioSource and QAudioSink. Attached you can see QLC+ Audio tab and qpwgraph showing audio devices and inputs/outputs on my system. FOH, Stage and FX are virtual devices that I have configured to route audio to the desired audio output if I need.

QLCAudioTabQt6.png
AudioDevices.png

Re: Build QLC+ with Qt 6.7.0

Posted: Sun Apr 21, 2024 6:39 am
by sbenejam
I found that QaudioSource and QaudioSink are used in audiorenderer_qt6 files in QLC+ code. Sorry.

Re: Build QLC+ with Qt 6.7.0

Posted: Sun Apr 21, 2024 6:56 pm
by sbenejam
It seems that alsa audio devices are not detected or missing. Some non alsa input and monitor are not detected too.