问题
Apple say that Apps built using OpenGL ES will continue to run in iOS 12, but Open GL ES is deprecated in iOS 12. Games and graphics-intensive apps that previously used OpenGL ES should now adopt Metal. But I don't want to migrate my app from OpenGL to Metal because it's the same code for Android and I don't want to create 2 branch, so how can I do to continue to use OpenGL in futur iOS release ?
回答1:
You more or less do not.
Apple has made it abundantly clear that they are not interested in supporting OpenGL ES further on any platform they control. In the future, you will use Metal or you will not have accelerated 3D graphics. Those will be your options.
There are projects that expose OpenGL ES on such platforms by implementing an ES layer on top of Metal. MoltenGL, for example, but that one isn't free apparently.
回答2:
I recommend that OpenGL and Metal are developed together on iOS, and new features are used with Metal.
来源:https://stackoverflow.com/questions/52405665/opengl-deprecated-in-ios-12-how-to-safely-continue-to-use-opengl-on-ios-12-dev