Hi Jules,
I needed to integrate a third-party Android GUI with Juce’s fantastic audio engine. Alas I didn’t control the android startup activity here, so using an introjucer-generated Android build was no option.
After some hacking I got it to work, but alas it can’t be done without modifying juce and it’s a bit ugly. For instance, the JNIClassBase stuff fails when juce can’t use its own startup activity. Also the JNI_OnLoad() implemention needs to be removed. And I need to call the AndroidSystem.initialise() / shutdown() methods somehow from the third-party startup code. And all the stuff dependent on juce_gui_basics needs to be excluded as well, which is a bit painful since the non-gui part of AudioProcessors is still useful, but can’t be used
That being said, all in all, it wasn’t such a big change to implement.
so I was wondering, wouldn’t it be feasible to refactor Juce slightly so that its audio engine can be used as a library out of the box? And not only on Android but on all supported platforms?
If it were, you could probably expand Juce’s market, by positioning it as a rich x-platform audio/midi engine. This would be great for gaming toolkits and other apps that come with their own GUIs. For example, people might be interested in reusing their VST implementations for sound generation in a gaming audio back-end. No other audio engine is capable of this AFAIK, but I imagine a “head-less” Juce could easily do just that.
What do you think?
PS given some other debate that is currently going on, this is not a request about refactoring into a dll or .so or anything. The current practice of dropping module source files into a project works well IMHO and I’ve grown rather fond of the introjucer. I’m just looking for a an option that would let Juce avoid bootstrapping the GUI on each platform, and still being able to use most of the audio functionality.