summaryrefslogtreecommitdiffstats
path: root/include/system
diff options
context:
space:
mode:
authorEino-Ville Talvala <etalvala@google.com>2012-04-19 15:46:26 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2012-04-19 15:46:26 -0700
commit29dbf049bc8c9217237422381a8256705d4ce4d5 (patch)
treec8a0df21e9aae310d64ba870b9ab77f64f73ae4f /include/system
parent0fb8ec8e9a056cd219216b1f5724d289b50dc993 (diff)
parent0a85154c1621b40d384b3fd7d45f3a9c0141e5a6 (diff)
downloadcore-29dbf049bc8c9217237422381a8256705d4ce4d5.tar.gz
core-29dbf049bc8c9217237422381a8256705d4ce4d5.tar.bz2
core-29dbf049bc8c9217237422381a8256705d4ce4d5.zip
Merge "Add new raw image sensor HAL pixel format."
Diffstat (limited to 'include/system')
-rw-r--r--include/system/graphics.h22
1 files changed, 21 insertions, 1 deletions
diff --git a/include/system/graphics.h b/include/system/graphics.h
index 729e92c78..e206e3edd 100644
--- a/include/system/graphics.h
+++ b/include/system/graphics.h
@@ -86,7 +86,27 @@ enum {
*/
HAL_PIXEL_FORMAT_YV12 = 0x32315659, // YCrCb 4:2:0 Planar
-
+ /*
+ * Android RAW sensor format:
+ *
+ * This format is exposed outside of the HAL to applications.
+ *
+ * RAW_SENSOR is a single-channel 16-bit format, typically representing raw
+ * Bayer-pattern images from an image sensor, with minimal processing.
+ *
+ * The exact pixel layout of the data in the buffer is sensor-dependent, and
+ * needs to be queried from the camera device.
+ *
+ * Generally, not all 16 bits are used; more common values are 10 or 12
+ * bits. All parameters to interpret the raw data (black and white points,
+ * color space, etc) must be queried from the camera device.
+ *
+ * This format assumes
+ * - an even width
+ * - an even height
+ * - a horizontal stride multiple of 16 pixels (32 bytes).
+ */
+ HAL_PIXEL_FORMAT_RAW_SENSOR = 0x20,
/* Legacy formats (deprecated), used by ImageFormat.java */
HAL_PIXEL_FORMAT_YCbCr_422_SP = 0x10, // NV16