OSDN Git Service

Unhide new preview callback methods.
authorWu-cheng Li <wuchengli@google.com>
Sun, 7 Mar 2010 22:59:28 +0000 (14:59 -0800)
committerWu-cheng Li <wuchengli@google.com>
Tue, 9 Mar 2010 19:11:47 +0000 (11:11 -0800)
bug:2358064
Change-Id: If9655ae8b7622ea6fc51e0054cfac7451962be66

api/current.xml
core/java/android/hardware/Camera.java

index e273cd2..21c1c18 100644 (file)
  visibility="public"
 >
 </field>
-<field name="FEATURE_CAMERA"
+<field name="FEATURE_BLUETOOTH"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.camera&quot;"
+ value="&quot;android.hardware.bluetooth&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_CAMERA_AUTOFOCUS"
+<field name="FEATURE_CAMERA"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.camera.autofocus&quot;"
+ value="&quot;android.hardware.camera&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_CAMERA_FLASH"
+<field name="FEATURE_CAMERA_AUTOFOCUS"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.camera.flash&quot;"
+ value="&quot;android.hardware.camera.autofocus&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_LIVE_WALLPAPER"
+<field name="FEATURE_CAMERA_FLASH"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.software.live_wallpaper&quot;"
+ value="&quot;android.hardware.camera.flash&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_SENSOR_LIGHT"
+<field name="FEATURE_LIVE_WALLPAPER"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.sensor.light&quot;"
+ value="&quot;android.software.live_wallpaper&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_SENSOR_PROXIMITY"
+<field name="FEATURE_LOCATION"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.sensor.proximity&quot;"
+ value="&quot;android.hardware.location&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_TELEPHONY"
+<field name="FEATURE_LOCATION_GPS"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.telephony&quot;"
+ value="&quot;android.hardware.location.gps&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_TELEPHONY_CDMA"
+<field name="FEATURE_LOCATION_NETWORK"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.telephony.cdma&quot;"
+ value="&quot;android.hardware.location.network&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_TELEPHONY_GSM"
+<field name="FEATURE_MICROPHONE"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.telephony.gsm&quot;"
+ value="&quot;android.hardware.microphone&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_TOUCHSCREEN_MULTITOUCH"
+<field name="FEATURE_SENSOR_ACCELEROMETER"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.touchscreen.multitouch&quot;"
+ value="&quot;android.hardware.sensor.accelerometer&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_TOUCHSCREEN_MULTITOUCH_DISTINCT"
+<field name="FEATURE_SENSOR_COMPASS"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.touchscreen.multitouch.distinct&quot;"
+ value="&quot;android.hardware.sensor.compass&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_BLUETOOTH"
+<field name="FEATURE_SENSOR_LIGHT"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.bluetooth&quot;"
+ value="&quot;android.hardware.sensor.light&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_LOCATION"
+<field name="FEATURE_SENSOR_PROXIMITY"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.location&quot;"
+ value="&quot;android.hardware.sensor.proximity&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_LOCATION_GPS"
+<field name="FEATURE_TELEPHONY"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.location.gps&quot;"
+ value="&quot;android.hardware.telephony&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_LOCATION_NETWORK"
+<field name="FEATURE_TELEPHONY_CDMA"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.location.network&quot;"
+ value="&quot;android.hardware.telephony.cdma&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_MICROPHONE"
+<field name="FEATURE_TELEPHONY_GSM"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.microphone&quot;"
+ value="&quot;android.hardware.telephony.gsm&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_WIFI"
+<field name="FEATURE_TOUCHSCREEN_MULTITOUCH"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.wifi&quot;"
+ value="&quot;android.hardware.touchscreen.multitouch&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_SENSOR_ACCELEROMETER"
+<field name="FEATURE_TOUCHSCREEN_MULTITOUCH_DISTINCT"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.sensor.accelerometer&quot;"
+ value="&quot;android.hardware.touchscreen.multitouch.distinct&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  visibility="public"
 >
 </field>
-<field name="FEATURE_SENSOR_COMPASS"
+<field name="FEATURE_WIFI"
  type="java.lang.String"
  transient="false"
  volatile="false"
- value="&quot;android.hardware.sensor.compass&quot;"
+ value="&quot;android.hardware.wifi&quot;"
  static="true"
  final="true"
  deprecated="not deprecated"
  deprecated="not deprecated"
  visibility="public"
 >
+<method name="addCallbackBuffer"
+ return="void"
+ abstract="false"
+ native="true"
+ synchronized="false"
+ static="false"
+ final="true"
+ deprecated="not deprecated"
+ visibility="public"
+>
+<parameter name="callbackBuffer" type="byte[]">
+</parameter>
+</method>
 <method name="autoFocus"
  return="void"
  abstract="false"
 <parameter name="cb" type="android.hardware.Camera.PreviewCallback">
 </parameter>
 </method>
+<method name="setPreviewCallbackWithBuffer"
+ return="void"
+ abstract="false"
+ native="false"
+ synchronized="false"
+ static="false"
+ final="true"
+ deprecated="not deprecated"
+ visibility="public"
+>
+<parameter name="cb" type="android.hardware.Camera.PreviewCallback">
+</parameter>
+</method>
 <method name="setPreviewDisplay"
  return="void"
  abstract="false"
index 85d52ec..5a63ae1 100644 (file)
@@ -261,7 +261,6 @@ public class Camera {
      * setPreviewCallback, or to this method with a null callback parameter.
      *
      * @param cb A callback object that receives a copy of the preview frame.  A null value will clear the queue.
-     * @hide
      */
     public final void setPreviewCallbackWithBuffer(PreviewCallback cb) {
         mPreviewCallback = cb;
@@ -273,14 +272,14 @@ public class Camera {
     /**
      * Adds a pre-allocated buffer to the callback buffer queue.
      * Preview width and height can be determined from getPreviewSize, and bitsPerPixel can be
-     * found from from  {@link android.hardware.Camera.Parameters#getPreviewFormat()} and
-     * {@link android.graphics.ImageFormat#getBitsPerPixel(int)}
+     * found from {@link android.hardware.Camera.Parameters#getPreviewFormat()}
+     * and {@link android.graphics.ImageFormat#getBitsPerPixel(int)}.
      *
      * Alternatively, a buffer from a previous callback may be passed in or used
      * to determine the size of new preview frame buffers.
      *
      * @param callbackBuffer The buffer to register. Size should be width * height * bitsPerPixel / 8.
-     * @hide
+     * @see #setPreviewCallbackWithBuffer(PreviewCallback)
      */
     public native final void addCallbackBuffer(byte[] callbackBuffer);