Android Camera Framework for API2

不问归期 提交于 2019-12-06 10:43:03

问题


Android camera framework has evolved a lot over the years.

During the days of API 1, the camera application framework (Java implementation) used to interact with native camera service (C++ implementation) using a JNI glue layer which also implemented binder. This mechanism was fairly straightforward to understand, on a higher level.

Now, I can see that for API 2, JNI layer is removed and application framework talks directly to the native camera service using aidl interfaces.

Refer architecture diagram: https://source.android.com/devices/camera/index.html

Even though the architecture diagram shows both API 1 and API 2 path, the description is provided only for API 1. I want to know how this works for API 2.

To summarize, can someone help me understand how aidl achieves the same functionality without using JNI? Also, more importantly, what could be the benefits of switching to this new mechanism?

来源:https://stackoverflow.com/questions/33255954/android-camera-framework-for-api2

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!