Rename FOCUS_MODE_CONTINUOUS to FOCUS_MODE_CONTINUOUS_VIDEO.
This constant is not public yet. Continuous autofocus should behave differently in still camera and camcorder. In camcorder, lens movement may be more smooth. And the triggers to start a new focus search may be different. If there is a need, FOCUS_MODE_CONTINUOUS_PHOTO can be added in the future. Change-Id: I05df9e491aca37829be3df92a73b952f26c86a4a
This commit is contained in:
@@ -76944,11 +76944,11 @@
|
|||||||
visibility="public"
|
visibility="public"
|
||||||
>
|
>
|
||||||
</field>
|
</field>
|
||||||
<field name="FOCUS_MODE_CONTINUOUS"
|
<field name="FOCUS_MODE_CONTINUOUS_VIDEO"
|
||||||
type="java.lang.String"
|
type="java.lang.String"
|
||||||
transient="false"
|
transient="false"
|
||||||
volatile="false"
|
volatile="false"
|
||||||
value=""continuous""
|
value=""continuous-video""
|
||||||
static="true"
|
static="true"
|
||||||
final="true"
|
final="true"
|
||||||
deprecated="not deprecated"
|
deprecated="not deprecated"
|
||||||
|
|||||||
@@ -1182,14 +1182,17 @@ public class Camera {
|
|||||||
public static final String FOCUS_MODE_EDOF = "edof";
|
public static final String FOCUS_MODE_EDOF = "edof";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Continuous auto focus mode. The camera continuously tries to focus.
|
* Continuous auto focus mode intended for video recording. The camera
|
||||||
* This is ideal for shooting video or shooting photo of moving object.
|
* continuously tries to focus. This is ideal for shooting video.
|
||||||
* Auto focus starts when the parameter is set. Applications should not
|
* Applications still can call {@link
|
||||||
* call {@link #autoFocus(AutoFocusCallback)} in this mode. To stop
|
* #takePicture(Camera.ShutterCallback, Camera.PictureCallback,
|
||||||
* continuous focus, applications should change the focus mode to other
|
* Camera.PictureCallback)} in this mode but the subject may not be in
|
||||||
* modes.
|
* focus. Auto focus starts when the parameter is set. Applications
|
||||||
|
* should not call {@link #autoFocus(AutoFocusCallback)} in this mode.
|
||||||
|
* To stop continuous focus, applications should change the focus mode
|
||||||
|
* to other modes.
|
||||||
*/
|
*/
|
||||||
public static final String FOCUS_MODE_CONTINUOUS = "continuous";
|
public static final String FOCUS_MODE_CONTINUOUS_VIDEO = "continuous-video";
|
||||||
|
|
||||||
// Indices for focus distance array.
|
// Indices for focus distance array.
|
||||||
/**
|
/**
|
||||||
@@ -2023,7 +2026,7 @@ public class Camera {
|
|||||||
* @see #FOCUS_MODE_MACRO
|
* @see #FOCUS_MODE_MACRO
|
||||||
* @see #FOCUS_MODE_FIXED
|
* @see #FOCUS_MODE_FIXED
|
||||||
* @see #FOCUS_MODE_EDOF
|
* @see #FOCUS_MODE_EDOF
|
||||||
* @see #FOCUS_MODE_CONTINUOUS
|
* @see #FOCUS_MODE_CONTINUOUS_VIDEO
|
||||||
*/
|
*/
|
||||||
public String getFocusMode() {
|
public String getFocusMode() {
|
||||||
return get(KEY_FOCUS_MODE);
|
return get(KEY_FOCUS_MODE);
|
||||||
@@ -2225,8 +2228,8 @@ public class Camera {
|
|||||||
* #autoFocus(AutoFocusCallback)}, {@link #cancelAutoFocus}, or {@link
|
* #autoFocus(AutoFocusCallback)}, {@link #cancelAutoFocus}, or {@link
|
||||||
* #startPreview()}. Applications can call {@link #getParameters()}
|
* #startPreview()}. Applications can call {@link #getParameters()}
|
||||||
* and this method anytime to get the latest focus distances. If the
|
* and this method anytime to get the latest focus distances. If the
|
||||||
* focus mode is FOCUS_MODE_CONTINUOUS, focus distances may change from
|
* focus mode is FOCUS_MODE_CONTINUOUS_VIDEO, focus distances may change
|
||||||
* time to time.
|
* from time to time.
|
||||||
*
|
*
|
||||||
* This method is intended to estimate the distance between the camera
|
* This method is intended to estimate the distance between the camera
|
||||||
* and the subject. After autofocus, the subject distance may be within
|
* and the subject. After autofocus, the subject distance may be within
|
||||||
|
|||||||
@@ -380,12 +380,14 @@ public:
|
|||||||
// continuously. Applications should not call
|
// continuously. Applications should not call
|
||||||
// CameraHardwareInterface.autoFocus in this mode.
|
// CameraHardwareInterface.autoFocus in this mode.
|
||||||
static const char FOCUS_MODE_EDOF[];
|
static const char FOCUS_MODE_EDOF[];
|
||||||
// Continuous auto focus mode. The camera continuously tries to focus. This
|
// Continuous auto focus mode intended for video recording. The camera
|
||||||
// is ideal for shooting video or shooting photo of moving object. Auto
|
// continuously tries to focus. This is ideal for shooting video.
|
||||||
// focus starts when the parameter is set. Applications should not call
|
// Applications still can call CameraHardwareInterface.takePicture in this
|
||||||
// CameraHardwareInterface.autoFocus in this mode. To stop continuous
|
// mode but the subject may not be in focus. Auto focus starts when the
|
||||||
// focus, applications should change the focus mode to other modes.
|
// parameter is set. Applications should not call
|
||||||
static const char FOCUS_MODE_CONTINUOUS[];
|
// CameraHardwareInterface.autoFocus in this mode. To stop continuous focus,
|
||||||
|
// applications should change the focus mode to other modes.
|
||||||
|
static const char FOCUS_MODE_CONTINUOUS_VIDEO[];
|
||||||
|
|
||||||
private:
|
private:
|
||||||
DefaultKeyedVector<String8,String8> mMap;
|
DefaultKeyedVector<String8,String8> mMap;
|
||||||
|
|||||||
@@ -142,7 +142,7 @@ const char CameraParameters::FOCUS_MODE_INFINITY[] = "infinity";
|
|||||||
const char CameraParameters::FOCUS_MODE_MACRO[] = "macro";
|
const char CameraParameters::FOCUS_MODE_MACRO[] = "macro";
|
||||||
const char CameraParameters::FOCUS_MODE_FIXED[] = "fixed";
|
const char CameraParameters::FOCUS_MODE_FIXED[] = "fixed";
|
||||||
const char CameraParameters::FOCUS_MODE_EDOF[] = "edof";
|
const char CameraParameters::FOCUS_MODE_EDOF[] = "edof";
|
||||||
const char CameraParameters::FOCUS_MODE_CONTINUOUS[] = "continuous";
|
const char CameraParameters::FOCUS_MODE_CONTINUOUS_VIDEO[] = "continuous-video";
|
||||||
|
|
||||||
CameraParameters::CameraParameters()
|
CameraParameters::CameraParameters()
|
||||||
: mMap()
|
: mMap()
|
||||||
|
|||||||
Reference in New Issue
Block a user