Frank Schlegel Frank Schlegel - 1 month ago 12x
iOS Question

OpenGL errors on A7-devices in iOS 10

My image processing app behaves really strange on devices with an A7 chip (iPhone 5s and iPad Mini 2 tested) after the update to iOS 10:

Rendering takes extremely long and produces broken results. Instruments reveals that some of the

calls return with
. I couldn't make out the cause for that, though.

The same code runs perfectly fine on newer devices (A8 and better) and on all devices in iOS 9. Did Apple change things I am not aware of?

Some more background info:

  • I'm partially using textures of

  • I make use of the
    extension to render into those textures

  • I use the
    extension to process pixels in some of my filters in-place


As it turns out I was only partially assigning gl_FragColor in some of my shaders (e.g., gl_FragColor.rg = vec2(1.0, 0.0);), which caused the erroneous behavior in iOS 10. Possibly only in combination with a GL_HALF_FLOAT_OES-typed render target, though.

When I always assign the full vector (even though the other parts are unused…), it works like a charm.