diff options
author | Wu-cheng Li <wuchengli@google.com> | 2010-09-15 19:03:01 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2010-09-15 19:03:01 -0700 |
commit | 16d508acb318f391f22572a1e1c7ea4ba806cb6e (patch) | |
tree | d2cb3f8f6608a96009860e2078c682c19e99f5c3 | |
parent | 3dee32bfcd42214744a400341a16c9488f313862 (diff) | |
parent | 4db458b4f71cd9ccbb98f5bf2c08e1f0eb750548 (diff) | |
download | frameworks_base-16d508acb318f391f22572a1e1c7ea4ba806cb6e.zip frameworks_base-16d508acb318f391f22572a1e1c7ea4ba806cb6e.tar.gz frameworks_base-16d508acb318f391f22572a1e1c7ea4ba806cb6e.tar.bz2 |
am 4db458b4: am a6f41495: Merge "Update camera API and javadoc for API review comments." into gingerbread
Merge commit '4db458b4f71cd9ccbb98f5bf2c08e1f0eb750548'
* commit '4db458b4f71cd9ccbb98f5bf2c08e1f0eb750548':
Update camera API and javadoc for API review comments.
-rw-r--r-- | api/current.xml | 4 | ||||
-rw-r--r-- | core/java/android/hardware/Camera.java | 15 |
2 files changed, 14 insertions, 5 deletions
diff --git a/api/current.xml b/api/current.xml index 857fc55..c0caf7e 100644 --- a/api/current.xml +++ b/api/current.xml @@ -85535,7 +85535,7 @@ visibility="public" > </field> -<field name="mFacing" +<field name="facing" type="int" transient="false" volatile="false" @@ -85545,7 +85545,7 @@ visibility="public" > </field> -<field name="mOrientation" +<field name="orientation" type="int" transient="false" volatile="false" diff --git a/core/java/android/hardware/Camera.java b/core/java/android/hardware/Camera.java index 3cc89e5..26600f3 100644 --- a/core/java/android/hardware/Camera.java +++ b/core/java/android/hardware/Camera.java @@ -154,14 +154,21 @@ public class Camera { * Information about a camera */ public static class CameraInfo { + /** + * The facing of the camera is opposite to that of the screen. + */ public static final int CAMERA_FACING_BACK = 0; + + /** + * The facing of the camera is the same as that of the screen. + */ public static final int CAMERA_FACING_FRONT = 1; /** * The direction that the camera faces to. It should be * CAMERA_FACING_BACK or CAMERA_FACING_FRONT. */ - public int mFacing; + public int facing; /** * The orientation of the camera image. The value is the angle that the @@ -175,7 +182,7 @@ public class Camera { * * @see #setDisplayOrientation(int) */ - public int mOrientation; + public int orientation; }; /** @@ -210,12 +217,14 @@ public class Camera { /** * The id for the default camera. + * @see #open(int) */ public static int CAMERA_ID_DEFAULT = 0; /** * Equivalent to Camera.open(Camera.CAMERA_ID_DEFAULT). * Creates a new Camera object to access the default camera. + * @see #open(int) */ public static Camera open() { return new Camera(CAMERA_ID_DEFAULT); @@ -787,7 +796,7 @@ public class Camera { * case Surface.ROTATION_270: degrees = 270; break; * } * - * int result = (info.mOrientation - degrees + 360) % 360; + * int result = (info.orientation - degrees + 360) % 360; * camera.setDisplayOrientation(result); * } * </pre> |