Hi,
I’ve recently been hunting a strange audio glitch that only affected certain iOS devices, specifically iPhone X running iOS 12.1.
I’d like to share with you how I solved this.
Using JUCE v5.3.2. In my standalone audio plugin, I have the following:
MyAudioProcessorEditor::MyAudioProcessorEditor(MyAudioProcessor& p)
: AudioProcessorEditor(&p), processor(p) {
MainComponent* mc = new MainComponent(this, &p);
mainComponent.reset(mc);
addAndMakeVisible(mainComponent);
#if JUCE_OPENGL
glContext.setRenderer(this);
glContext.setMultisamplingEnabled(true);
glContext.setContinuousRepainting(true);
glContext.setComponentPaintingEnabled(true);
glContext.setSwapInterval(1);
Component* top = getTopLevelComponent();
glContext.attachTo(*top);
if (ComponentPeer* peer = getPeer())
peer->setCurrentRenderingEngine(0);
#endif
}
This caused iPhone X to glitch. On other hardware, e.g. iPad 6th Gen, this works fine.
However, doing the following and turning multi-sampling OFF fixes it.
glContext.setMultisamplingEnabled(false);
I don’t know why this is is, but if anyone else is having this issue, this setting might help you.