I need a reference to a ANativeWindow structure to be fed to an image processing library based on OpenGL. I don't want to make a native activity or an additional application.
What I've tried until now was using android_createDisplaySurface but that required me to stop the Android run time engine during my test, so that's not a permanent solution.
My target functionality involves using the OpenGL based library to process the frames from the camera before being displayed by changing the camera HAL to call functions of the the image processing library. So creating some additional application would not help.
Asked
Active
Viewed 894 times
0

genpfault
- 51,148
- 11
- 85
- 139

ionela.voinescu
- 384
- 1
- 7
1 Answers
0
You can use
ANativeWindow* ANativeWindow_fromSurface(JNIEnv* env, jobject surface);
for your task, surface can be passed through jni usual way, but you can do this only for your own app.

Vasaka
- 1,953
- 1
- 19
- 30