Add camera ping command and release message.
The problem is both face unlock and camera application try to open the hardware camera at the same time. A new camera open API is added to let face unlock take the camera away from the existing client. The release message is used to notify the existing client, so it has time to release the hardware camera and clean up. If existing client tries to use the camera after it is released, the method will return error. It is still possible that the camera has been taken and the existing client has not got the notification. When any method returns error, the existing client can use ping command to check whether the camera has been released. If yes, the client can silently finish the app itself or show a toast if it wants. bug:5584464 Change-Id: I87f9f7db2f7b2b70ab2405f9b3da0d8946d6a01b
Loading
Please register or sign in to comment