Opening the sound output may have failed or the audio is going to some output you don’t have connected to your monitoring. I don’t think the tutorials go into the details of how to change the outputs or even do any error handling. (They just assume opening the default device will work.)
You can try adding something like this for testing purposes in the component constructor (edit :changed the code to instantiate the components on the stack) :
AudioDeviceSelectorComponent devcomp{ deviceManager,
1,4,1,4,true,true,true,false };
devcomp.setSize(500, 500);
AlertWindow alert{ "Audio hardware","",AlertWindow::InfoIcon, this };
alert.addCustomComponent(&devcomp);
alert.addButton("OK", 1);
int r = alert.runModalLoop();
That should show an audio device configuration dialog, where you may be able to test different devices and settings. (The settings won’t be saved and recalled between runs of the application using just that, though.)
Yes, but there probably was some additional complication with stack allocation why I had written the code like that. The code is not that great anyway, as it’s using a modal dialog when the application starts etc. But like I mentioned in my reply, it would just be for testing purposes.
edit : it’s actually a bit odd the AudioAppComponent doesn’t have a (properly implemented) convenience method to show the AudioDeviceSelectorComponent to begin with…