您的位置:首页 > 移动开发 > Android开发

Android Dev Intro - ANativeWindow

2016-05-31 18:01 501 查看


ANativeWindow

The public Surface class is implemented in the Java programming language. The equivalent in C/C++ is the ANativeWindow class, semi-exposed by the Android
NDK. You can get the ANativeWindow from a Surface with the 
ANativeWindow_fromSurface()
 call. Just like its Java-language cousin, you can lock it, render in software, and unlock-and-post.

To create an EGL window surface from native code, you pass an instance of EGLNativeWindowType to
eglCreateWindowSurface()
. EGLNativeWindowType is just a synonym for ANativeWindow, so you
can freely cast one to the other.

The fact that the basic "native window" type just wraps the producer side of a BufferQueue should not come as a surprise.
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: