summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorWu-cheng Li <wuchengli@google.com>2009-09-28 16:14:58 -0700
committerWu-cheng Li <wuchengli@google.com>2009-10-06 13:25:10 -0700
commite6a550d02ff02f465d7dbb6e862671462866f024 (patch)
tree005e2a57c55f5c24400f604150727b9b91b61fe9 /include
parent7854a353261dd276a7726d48677c18ef827b26eb (diff)
downloadframeworks_native-e6a550d02ff02f465d7dbb6e862671462866f024.zip
frameworks_native-e6a550d02ff02f465d7dbb6e862671462866f024.tar.gz
frameworks_native-e6a550d02ff02f465d7dbb6e862671462866f024.tar.bz2
Add zoom functions and sendCommand.
b2060030
Diffstat (limited to 'include')
-rw-r--r--include/ui/Camera.h9
-rw-r--r--include/ui/CameraHardwareInterface.h9
-rw-r--r--include/ui/ICamera.h3
3 files changed, 19 insertions, 2 deletions
diff --git a/include/ui/Camera.h b/include/ui/Camera.h
index 9ceb8fd..5219772 100644
--- a/include/ui/Camera.h
+++ b/include/ui/Camera.h
@@ -78,6 +78,12 @@ enum {
CAMERA_MSG_ALL_MSGS = 0x1FF
};
+// cmdType in sendCommand functions
+enum {
+ CAMERA_CMD_START_SMOOTH_ZOOM = 1,
+ CAMERA_CMD_STOP_SMOOTH_ZOOM = 2,
+};
+
// camera fatal errors
enum {
CAMERA_ERROR_UKNOWN = 1,
@@ -155,6 +161,9 @@ public:
// get preview/capture parameters - key/value pairs
String8 getParameters() const;
+ // send command to camera driver
+ status_t sendCommand(int32_t cmd, int32_t arg1, int32_t arg2);
+
void setListener(const sp<CameraListener>& listener);
void setPreviewCallbackFlags(int preview_callback_flag);
diff --git a/include/ui/CameraHardwareInterface.h b/include/ui/CameraHardwareInterface.h
index 5fbb7d8..af40f31 100644
--- a/include/ui/CameraHardwareInterface.h
+++ b/include/ui/CameraHardwareInterface.h
@@ -147,7 +147,7 @@ public:
* Returns true if recording is enabled.
*/
virtual bool recordingEnabled() = 0;
-
+
/**
* Release a record frame previously returned by CAMERA_MSG_VIDEO_FRAME.
*/
@@ -186,11 +186,16 @@ public:
virtual CameraParameters getParameters() const = 0;
/**
+ * Send command to camera driver.
+ */
+ virtual status_t sendCommand(int32_t cmd, int32_t arg1, int32_t arg2) = 0;
+
+ /**
* Release the hardware resources owned by this object. Note that this is
* *not* done in the destructor.
*/
virtual void release() = 0;
-
+
/**
* Dump state of the camera hardware
*/
diff --git a/include/ui/ICamera.h b/include/ui/ICamera.h
index 7595e36..5642691 100644
--- a/include/ui/ICamera.h
+++ b/include/ui/ICamera.h
@@ -87,6 +87,9 @@ public:
// get preview/capture parameters - key/value pairs
virtual String8 getParameters() const = 0;
+
+ // send command to camera driver
+ virtual status_t sendCommand(int32_t cmd, int32_t arg1, int32_t arg2) = 0;
};
// ----------------------------------------------------------------------------