diff options
author | Wu-cheng Li <wuchengli@google.com> | 2011-08-10 14:43:40 +0800 |
---|---|---|
committer | Wu-cheng Li <wuchengli@google.com> | 2011-08-10 17:48:58 +0800 |
commit | 89155720bce8b530659bcdd48bcb3802bc80a6ba (patch) | |
tree | 12af9b8e8aa037323a77a4f1f2e37159a6c06cce | |
parent | 7629155333c8db423ec28f2d368f0938ea7ddf23 (diff) | |
download | LegacyCamera-89155720bce8b530659bcdd48bcb3802bc80a6ba.zip LegacyCamera-89155720bce8b530659bcdd48bcb3802bc80a6ba.tar.gz LegacyCamera-89155720bce8b530659bcdd48bcb3802bc80a6ba.tar.bz2 |
Update face detection API.
bug:4460717
Change-Id: Ia748a3b9c5664058c63edce2335836f3817c909d
-rw-r--r-- | Android.mk | 2 | ||||
-rw-r--r-- | src/com/android/camera/Camera.java | 8 |
2 files changed, 4 insertions, 6 deletions
@@ -6,7 +6,7 @@ LOCAL_MODULE_TAGS := optional LOCAL_SRC_FILES := $(call all-java-files-under, src) LOCAL_PACKAGE_NAME := Camera -#LOCAL_SDK_VERSION := current +LOCAL_SDK_VERSION := current LOCAL_JNI_SHARED_LIBRARIES := libjni_mosaic diff --git a/src/com/android/camera/Camera.java b/src/com/android/camera/Camera.java index ee496ca..7ac3023 100644 --- a/src/com/android/camera/Camera.java +++ b/src/com/android/camera/Camera.java @@ -517,20 +517,18 @@ public class Camera extends ActivityBase implements View.OnClickListener, } private void startFaceDetection() { - if (mParameters.getMaxNumDetectedFaces( - android.hardware.Camera.CAMERA_FACE_DETECTION_HW) > 0) { + if (mParameters.getMaxNumDetectedFaces() > 0) { if (mFaceListener == null) { mFaceListener = new FaceListener(this, (ViewGroup) findViewById(R.id.frame), mDisplayOrientation); } mCameraDevice.setFaceDetectionListener(mFaceListener); - mCameraDevice.startFaceDetection(android.hardware.Camera.CAMERA_FACE_DETECTION_HW); + mCameraDevice.startFaceDetection(); } } private void stopFaceDetection() { - if (mParameters.getMaxNumDetectedFaces( - android.hardware.Camera.CAMERA_FACE_DETECTION_HW) > 0) { + if (mParameters.getMaxNumDetectedFaces() > 0) { mCameraDevice.setFaceDetectionListener(null); mCameraDevice.stopFaceDetection(); } |