I’m trying to attach OpenGLContext to a Component on iOS. The same code works on Desktop (macOS, Win, I didn’t test it on Android yet).
I can’t post the whole code because it’s a big application, it looks like the FrameBuffers are not properly initialized, an error is displayed on line 279 of juce_OpenGL_ios.h
jassert (glCheckFramebufferStatus (GL_FRAMEBUFFER) == GL_FRAMEBUFFER_COMPLETE);
***** GL_INVALID_VALUE at /JUCE/modules/juce_opengl/native/juce_OpenGL_ios.h : 279
JUCE Assertion failure in juce_opengl.cpp:221
At this point the OpenGLContext should be active, I printed it out :
**Version:OpenGL ES 3.0 APPLE-18.0.31, Vendor:Apple Inc., Renderer:Apple Software Renderer**
The OpenGL Context is initialized as follow:
addToDesktop(0); //This is not necessary on Desktop openGLContext.setOpenGLVersionRequired(juce::OpenGLContext::openGL3_2);
It is also not possible to use a juce::OpenGLImageType() in an Image, the following code:
img = juce::Image(juce::Image::ARGB, width, height, true, juce::OpenGLImageType());
crashes in the same place (on iOS, on Desktop works). The OpenGLContext was initialized in the same way.
@ed95 is this a bug or I forgot something?