【发布时间】:2015-05-14 05:36:59
【问题描述】:
我正在尝试在目标为 GL_TEXTURE_2D 的 OpenGL 纹理上渲染相机预览。我非常了解 SurfaceTexture,但我无法使用它,因为它仅适用于 GL_TEXTURE_EXTERNAL_OES。在 SurfaceTexture 的文档中,它是这样写的:
Each time the texture is bound it must be bound to the GL_TEXTURE_EXTERNAL_OES target rather than the GL_TEXTURE_2D target
我不能使用GL_TEXTURE_EXTERNAL_OES,因为我必须对现有代码进行大量更改。
有没有一种方法也可以快速实现?
【问题讨论】:
标签: android opengl-es android-camera shader render-to-texture