summaryrefslogtreecommitdiffstats
path: root/include/hardware/hardware.h
diff options
context:
space:
mode:
authorMathias Agopian <mathias@google.com>2010-07-07 14:54:14 -0700
committerMathias Agopian <mathias@google.com>2010-07-14 15:16:12 -0700
commit80107f8e92e25e62c945600325f3e846477bc855 (patch)
treef5093ba91555e864a71e2152117c5953707c1580 /include/hardware/hardware.h
parent1daacdc8d2d110d3edd077fcd2befa9884924e10 (diff)
downloadreplicant_libhardware-80107f8e92e25e62c945600325f3e846477bc855.zip
replicant_libhardware-80107f8e92e25e62c945600325f3e846477bc855.tar.gz
replicant_libhardware-80107f8e92e25e62c945600325f3e846477bc855.tar.bz2
Remove the YV16 format.
Change-Id: I12f72cf91a66d78499983221925ac68ca646efc8
Diffstat (limited to 'include/hardware/hardware.h')
-rw-r--r--include/hardware/hardware.h26
1 files changed, 14 insertions, 12 deletions
diff --git a/include/hardware/hardware.h b/include/hardware/hardware.h
index 9382fe4..8ba79fa 100644
--- a/include/hardware/hardware.h
+++ b/include/hardware/hardware.h
@@ -143,26 +143,28 @@ enum {
*/
/*
- * Android YUV formats:
+ * Android YUV format:
*
- * These two formats are exposed outside of the HAL to software
+ * This format is exposed outside of the HAL to software
* decoders and applications.
- * EGLImageKHR must support them in conjunction with the
+ * EGLImageKHR must support it in conjunction with the
* OES_EGL_image_external extension.
*
- * YV12 is a planar format comprised of a WxH Y plane followed
+ * YV12 is 4:2:0 YCrCb planar format comprised of a WxH Y plane followed
* by (W/2) x (H/2) Cr and Cb planes.
*
- * YV16 is a planar format comprised of WxH Y, Cr and Cb planes.
- *
- * For both these formats, the Y plane appears first, followed by the Cr
- * plane and then the Cb plane.
- *
- * Both formats *require* a 16 pixel alignment horizontally and vertically.
+ * This format assumes an horizontal stride of 16 pixels for all planes
+ * and an implicit vertical stride of the image height's next multiple
+ * of two:
+ * y_size = stride * ALIGN(height, 2)
+ * c_size = ALIGN(stride/2, 16) * height
+ * size = y_size + c_size * 2
+ * cr_offset = y_size
+ * cb_offset = y_size + c_size
*
*/
- HAL_PIXEL_FORMAT_YV12 = 0x32315659, // YCrCb 4:2:0 Planar
- HAL_PIXEL_FORMAT_YV16 = 0x36315659, // YCrCb 4:2:2 Planar
+ HAL_PIXEL_FORMAT_YV12 = 0x32315659, // YCrCb 4:2:0 Planar
+
/* Legacy formats (deprecated), used by ImageFormat.java */