I'm trying to get a texture id from metal surface.
I have two problems 1. That function is not defined
GLint glTextureID = CGLTexImageIOSurface2D(self.mEAGLContext, GL_TEXTURE_2D, GL_RGBA , textureWidth, textureHeight, GL_RGBA , GL_UNSIGNED_BYTE, ioSurface, 0);
I tried to include it #import OpenGL/CGLIOSurface.h but xcode doesn't recognize it, it's not there.
Are there any other methods to obtain a texture id from an iosurface in ios, metal ?