Internal Audio Source?

Archive of the non-categorized posts related to the QLC+ technical support.
Please do not create new threads here, instead, use the categories above !
Post Reply
Charles

I'm programming a show where I'll be playing back the audio as a track in the show and wanted to animate the rear wall wash cans using the audio spectrum script in the RGB Matrix.

Without thinking about it too deeply I had assumed that QLC would pick up audio that it itself was playing - but this seems not to be the case?

My audio input/output mapping are both currently set to the default device.

I don't think the sound drivers in this machine have an option for recording the wave out which would be one way of solving it.

Would it be worth having an audio source of "internal" to pick up tracks that QLC was playing back itself?
Markus Baertschi

I'm playing with QLC+ to prepare for a party and have a similar problem. It looks like QLC+ does not allow to pick the auudio source, just the device. In my case it uses the microphone input of my Laptop. This is a crappy choice as I play the music from the same laptop and now I'm picking up the environment noise too.

There should be an option to choose between the inputs of the choosen device.
Massimo Callegari

Well, it looks like none of you read the posting guidelines as none of you stated the QLC+ version and the operating system you're using.

So I won't help.

Plus, audio routing is something that can be done at operating system level most of the times.
For example in Windows there is a special mixer line called "What U hear". Muting the microphone line and using "what u hear" should do it.

Before saying "crappy choice" you should learn how to use your computer.
Markus Baertschi

Hi Massimo, I'm sorry, I apologize.

I'm using QLC+ 4.8.2 on Ubuntu 14.04.

Yes, audio routing can be done on Linux in many cases. But I can not route to the microphone in software.

I think QLC+ is a nice piece of software. Thanks !
Massimo Callegari

That changes everything.
QLC+ on Linux still runs on Qt4, unless you built it from sources on Qt5.

It uses ALSA to perform audio IO operations.
In my system (Mint 17) I haven't been able to route the audio with Qt5 because it uses PulseAudio.
On ALSA you should be able to do it with qjackctl http://qjackctl.sourceforge.net/

When I have time I'll try with a Qt4 build and see if I can make it.

QLC+ internal routing would be possible, but with one single source it can be easy to implement, with multiple audio sources at the same time (and I'm sure you guys at some point will ask for it) it means I have to develop and internal mixer in QLC+. No way.
Massimo Callegari

Additional note. I just found a way to do it with the ALSA loopback device.

just do
sudo modprobe snd-aloop

and use the configuration of the attached screenshot.
Basically you route the audio output to a fake audio device and the use it also as audio input.
Note that in this way you won't hear any audio, so you'll need to turn every audio Function in QLC+ into a Collection, with the same audio file played on the loopback as well as on the real output audio card.

Try and let me know if it works for you
Attachments
alsa-loopback.png
alsa-loopback.png (15.61 KiB) Viewed 3428 times
Markus Baertschi

The snd-aloop drive shows up in QLC+ after a restart and I can select it. I also see a 'Loopback Analog Stereo' device in VLC, which I use to play the audio. Choosing that this output device plays the audio, but nothing is heard. So far this is as you predicted.

But in QLC+ my Audio Trigger does not 'hear' the audio, the sound level meter does not move.

Taking a step back, I realize that we run off maybe in the wrong direction: I started out with a Show and an audio file in a track. Then I wanted to create a Chaser for a part of the song who would be triggered by sound. I started playing with chaser and audio trigger on the simple desk as I did not find a way to add the trigger to the chaser in a show.

So in the end I have two questions:
- How do I route the sound of audio in a show to a audio trigger (and the speakers too)
- How do I add an audio trigger to a chaser in a show ? If I add the trigger to the chaser on the simple desk, will it then automatically apply in the show ?
Massimo Callegari

Markus, you're taking it the wrong way.
An audio trigger is a Virtual Console widget. You can't just add it to a Show function.
I've already written the solution for you before:
"Note that in this way you won't hear any audio, so you'll need to turn every audio Function in QLC+ into a Collection, with the same audio file played on the loopback as well as on the real output audio card."
Markus Baertschi

So I created a collection and added the sound file twice to it. I can choose the Audio Device for each audio file.

But what do I do with this collection ?
I can not add it to the Show.
I can not Play it, I can only play the individual Audio files.

The Audio files also seem to have the habit of changing the Audio device themselves. I choose 'Intel' for the 1st instance, then Loopback for the second. When I click back on the 1st, the device has changed to 'default'a nd when I then verify the 2nd the Device is 'Nvidia HDMI'. Frustrating.
Markus Baertschi

The Christmas break has given me the opportunity to revisit this question and I found a solution to it after quite a bit of research. It requires a few steps:

1) Get the 'snd-aloop' device running. This is probaly as simple as 'sudo modprobe snd-aloop' and adding this line to /etc/rc.local so it stays after a reboot. You can check its existence with 'cat /proc/asound/cards', it will show up as 'Loopback'

2) Configure ALSA to set up a new sound device which sends sound to the soundcard and the loopback device. You'll find instructions on stackexchange here: http://unix.stackexchange.com/questions ... nd-speaker

3) Configure your sound application to use the 'CardAndLoop' device defined in 2) and use it to provide sound / play music.

4) Configure qlcplus to use the 'Loopback' device for audio input. You'll see two Loopack devices, use the second one.

Enjoy !
Post Reply