Is it possible to run QAudioOutput in a different thread than the main thread?



  • Hi,

    We are using QAudioOutput for playing sound in our application. When doing GUI modifications the sound flickers. So to solve this we want to move QAudioOutput to its own thread.

    But when doing this we get a segmentation fault when instantiating QAudioOutput it seems to occur somewhere inside the ALSA code. If we instantiate the QAudioOutput before moving it to the new thread we get the following assertion “control.c: 234: snd_ctl_card_info: Assertion `ctl && info' failed” form the ALSA library when calling QAudioOutput::Start().

    We are using Qt version 4.7.1 cross-compiled for an ARM cortex A8 platform.

    I have googled on the problem and found examples of moving QAudioOutput to a thread but also found people explaining that QAudioOutput needs to be running in the main application thread to work.

    So my question is, is it possible to run QAudioOutput in a QThread or not, and does anyone have a solution to this problem.

    Thanks,


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.