summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorSteve Kondik <shade@chemlab.org>2010-11-12 00:13:18 -0500
committerSteve Kondik <shade@chemlab.org>2010-11-12 00:31:22 -0500
commitaad9f21a435605402b94a52cab555fde0c66c78d (patch)
tree3165a832c3aca5f8d81f19714abb9ecaeaf60f48 /include
parent731adc40c1054583cd0d2cc32c7a905227dc4942 (diff)
downloadframeworks_base-aad9f21a435605402b94a52cab555fde0c66c78d.zip
frameworks_base-aad9f21a435605402b94a52cab555fde0c66c78d.tar.gz
frameworks_base-aad9f21a435605402b94a52cab555fde0c66c78d.tar.bz2
camera: Wrap getBufferInfo code in ifdefs.
Define BOARD_CAMERA_USE_GETBUFFERINFO if required. Change-Id: Ieac0bed92c8a1517a6a7730b9636f3591c55bbcb
Diffstat (limited to 'include')
-rw-r--r--include/camera/Camera.h3
-rw-r--r--include/camera/CameraHardwareInterface.h17
-rw-r--r--include/camera/ICamera.h10
3 files changed, 17 insertions, 13 deletions
diff --git a/include/camera/Camera.h b/include/camera/Camera.h
index f4a80b5..d565315 100644
--- a/include/camera/Camera.h
+++ b/include/camera/Camera.h
@@ -129,9 +129,10 @@ public:
status_t setPreviewDisplay(const sp<Surface>& surface);
status_t setPreviewDisplay(const sp<ISurface>& surface);
+#ifdef USE_GETBUFFERINFO
// query the recording buffer information from HAL layer.
status_t getBufferInfo(sp<IMemory>& Frame, size_t *alignedSize);
-
+#endif
// start preview mode, must call setPreviewDisplay first
status_t startPreview();
diff --git a/include/camera/CameraHardwareInterface.h b/include/camera/CameraHardwareInterface.h
index 54aad5b..7e19976 100644
--- a/include/camera/CameraHardwareInterface.h
+++ b/include/camera/CameraHardwareInterface.h
@@ -127,6 +127,15 @@ public:
*/
virtual status_t startPreview() = 0;
+#ifdef USE_GETBUFFERINFO
+ /**
+ * Query the recording buffer information from HAL.
+ * This is needed because the opencore expects the buffer
+ * information before starting the recording.
+ */
+ virtual status_t getBufferInfo(sp<IMemory>& Frame, size_t *alignedSize) = 0;
+#endif
+
/**
* Only used if overlays are used for camera preview.
*/
@@ -212,14 +221,6 @@ public:
* Dump state of the camera hardware
*/
virtual status_t dump(int fd, const Vector<String16>& args) const = 0;
-
- /**
- * Query the recording buffer information from HAL.
- * This is needed because the opencore expects the buffer
- * information before starting the recording.
- */
- virtual status_t getBufferInfo(sp<IMemory>& Frame, size_t *alignedSize) = 0;
-
};
/** factory function to instantiate a camera hardware object */
diff --git a/include/camera/ICamera.h b/include/camera/ICamera.h
index 7b3b8fb..d9c43bf 100644
--- a/include/camera/ICamera.h
+++ b/include/camera/ICamera.h
@@ -53,6 +53,11 @@ public:
// preview are handled.
virtual void setPreviewCallbackFlag(int flag) = 0;
+#ifdef USE_GETBUFFERINFO
+ // get the recording buffer information from HAL layer.
+ virtual status_t getBufferInfo(sp<IMemory>& Frame, size_t *alignedSize) = 0;
+#endif
+
// start preview mode, must call setPreviewDisplay first
virtual status_t startPreview() = 0;
@@ -66,7 +71,7 @@ public:
virtual status_t startRecording() = 0;
// stop recording mode
- virtual void stopRecording() = 0;
+ virtual void stopRecording() = 0;
// get recording state
virtual bool recordingEnabled() = 0;
@@ -91,9 +96,6 @@ public:
// send command to camera driver
virtual status_t sendCommand(int32_t cmd, int32_t arg1, int32_t arg2) = 0;
-
- // get the recording buffer information from HAL layer.
- virtual status_t getBufferInfo(sp<IMemory>& Frame, size_t *alignedSize) = 0;
};
// ----------------------------------------------------------------------------