Hello! I’m having an issue running AudioRecordingDemo on a Emulated Device on Android Studio.
All the RuntimePermissions are granted including “Virtual microphone uses host audio input” on the emulated device Extended Controls, and I can see the recordingThumbnail being updated in real time but whenever I click the Record button, the recordButton.setButtonText (“Stop”) is not called and I hit the following Assertion Failure:
I/JUCE: JUCE Assertion failure in juce_android_RuntimePermissions.cpp:209
In physical devices the demo does run.
I’m building an app that hits the same Assertion Failure and I’m clueless on how to solve it.
Sounds like you forgot to set “Audio Input Required” to enabled in the Projucer, can that be? Also, if you have built the project without the setting enabled, then make sure you clean your build folder.
The AudioRecordingDemo works just fine on Android, both on the emulator and on actual devices. I suggest you compile the Demorunner, since it is configured properly for all platforms (unlike the individual demos which usually require some tweaking) and it contains all the demos. See if that works and look under the hood. Good luck.
Thanks for trying to help. But why does the AudioRecordingDemo runs fine on your android and your actual devices but in any other that I’ve tested it doesnt? What android phone model are you using on the emulator of Android Studio?
I don’t understand why a Demo which actually have specifications inside the code for Android doesn’t even run on Android… Why no one is able to help me ? I’ve posted this on Discord many times and asked a lot of different people, what is wrong ?
Now, if you can’t get the Demorunner to compile then you have something misconfigured and it will be easier to find out what it is if you try getting the Demorunner to compile.
Thanks for bringing this to our attention. The demo needed updating for compatibility with newer Android versions, where the WRITE_EXTERNAL_STORAGE permission should no longer be used.