diff options
author | Dave Sparks <davidsparks@android.com> | 2009-05-07 12:25:25 -0700 |
---|---|---|
committer | Dave Sparks <davidsparks@android.com> | 2009-05-07 12:25:25 -0700 |
commit | 2a04aefdf03abbdabb035f89c8a1df636c168de0 (patch) | |
tree | af1373ffe5244655f868c9145fdf3813fe82e66a /include/ui | |
parent | 50396063c2fbb1f427cf31e0b8a56567fb5a069c (diff) | |
download | frameworks_base-2a04aefdf03abbdabb035f89c8a1df636c168de0.zip frameworks_base-2a04aefdf03abbdabb035f89c8a1df636c168de0.tar.gz frameworks_base-2a04aefdf03abbdabb035f89c8a1df636c168de0.tar.bz2 |
Add new binder methods to camera client to support generic callbacks
This is the first step in a multi-step change to move from the old
specific callbacks to a generic callback. This will allow future
flexibility in the interface without requiring binder rewrites.
Bug 1837832
Diffstat (limited to 'include/ui')
-rw-r--r-- | include/ui/Camera.h | 2 | ||||
-rw-r--r-- | include/ui/ICameraClient.h | 19 |
2 files changed, 21 insertions, 0 deletions
diff --git a/include/ui/Camera.h b/include/ui/Camera.h index fd851d9..901c7a9 100644 --- a/include/ui/Camera.h +++ b/include/ui/Camera.h @@ -143,6 +143,8 @@ public: virtual void errorCallback(status_t error); virtual void autoFocusCallback(bool focused); virtual void recordingCallback(const sp<IMemory>& frame); + virtual void notifyCallback(int32_t msgType, int32_t ext, int32_t ext2); + virtual void dataCallback(int32_t msgType, const sp<IMemory>& frame); sp<ICamera> remote(); diff --git a/include/ui/ICameraClient.h b/include/ui/ICameraClient.h index 73b951c..1645ef8 100644 --- a/include/ui/ICameraClient.h +++ b/include/ui/ICameraClient.h @@ -29,6 +29,23 @@ class ICameraClient: public IInterface public: DECLARE_META_INTERFACE(CameraClient); + // msgType in notifyCallback function + enum { + ERROR, + SHUTTER, + FOCUSED, + ZOOM + } notify_callback_message_type; + + // msgType in dataCallback function + enum { + PREVIEW, + RECORD, + POSTVIEW, + RAW, + COMPRESSED + } data_callback_message_type; + virtual void shutterCallback() = 0; virtual void rawCallback(const sp<IMemory>& picture) = 0; virtual void jpegCallback(const sp<IMemory>& picture) = 0; @@ -36,6 +53,8 @@ public: virtual void errorCallback(status_t error) = 0; virtual void autoFocusCallback(bool focused) = 0; virtual void recordingCallback(const sp<IMemory>& frame) = 0; + virtual void notifyCallback(int32_t msgType, int32_t ext1, int32_t ext2) = 0; + virtual void dataCallback(int32_t msgType, const sp<IMemory>& data) = 0; }; |