Camera: Fix passing video native handle for 64-bit app
Add new binder calls to pass video native handle so the video native
handle can be passed between 32-bit and 64-bit processes.
Remove problematic code that used IMemory to pass video native
handle because the sizes of VideoNativeMetadata are different in
32-bit and 64-bit processes.
Bug: 28403412
Change-Id: I3341b1812ecc41d61846bb72ca926ecb1674c9ec
diff --git a/include/camera/android/hardware/ICamera.h b/include/camera/android/hardware/ICamera.h
index 322b741..3b12afe 100644
--- a/include/camera/android/hardware/ICamera.h
+++ b/include/camera/android/hardware/ICamera.h
@@ -94,9 +94,13 @@
// get recording state
virtual bool recordingEnabled() = 0;
- // release a recording frame
+ // Release a recording frame that was received via ICameraClient::dataCallbackTimestamp.
virtual void releaseRecordingFrame(const sp<IMemory>& mem) = 0;
+ // Release a recording frame handle that was received via
+ // ICameraClient::recordingFrameHandleCallbackTimestamp.
+ virtual void releaseRecordingFrameHandle(native_handle_t *handle) = 0;
+
// auto focus
virtual status_t autoFocus() = 0;