VideoComponent audio device


VideoComponent always uses the system default audio device during playback. It would make the class much more useful to be able to set the audio playback device!

AFAIK the VideoComponent is just a wrapper around the operating system multimedia playback facilities. The audio does not even go through JUCE in any form.

Correct. Not suggesting giving access to the audio. Just to be able to change the audio device.

On Apple platforms, the audio output device can be set using the audioOutputDeviceUniqueID function in the AVPlayer class. No idea yet how it can be done on Windows.

Looks like there is a solution for DirectShow on Windows here:

Have you managed to implement this? I’m struggling to figure out how to get the audioOutputDeviceUniqueID of each available device

No. I think that was the same issue I faced. In the end I gave up and used this instead:

It’s a pity - VideoComponent is very nice otherwise!

1 Like

Thanks for linking and using the project. I am evaluating, if it is worthwhile expanding the project to a more comprehensive image/video processing engine. If you are interested, I would love to hear feedback and suggestions in this thread: Poll: video engine for JUCE?


Thanks for the tip on filmstro. Looks cool.

I finally figured out how to get the UID for the audio output device and made some changes in JUCE that allow you get it from the AudioDeviceSetup, as well as set the VideoComponent’s audio output using that ID:

Tested with three different devices and it works! To get the uid and set the video’s output:

AudioDeviceManager::AudioDeviceSetup setup;
1 Like