am 3a90d596: Merge "Camera2: Add JPEG transport header" into jb-mr1-dev

* commit '3a90d5964bc17ace1097e06a62d0410241c6c99c':
  Camera2: Add JPEG transport header
This commit is contained in:
Eino-Ville Talvala 2012-09-24 08:25:53 -07:00 committed by Android Git Automerger
commit 13e8b51d5b

View file

@ -113,6 +113,26 @@ enum {
CAMERA2_HAL_PIXEL_FORMAT_ZSL = -1
};
/**
* Transport header for compressed JPEG buffers in output streams.
*
* To capture JPEG images, a stream is created using the pixel format
* HAL_PIXEL_FORMAT_BLOB, and the static metadata field android.jpeg.maxSize is
* used as the buffer size. Since compressed JPEG images are of variable size,
* the HAL needs to include the final size of the compressed image using this
* structure inside the output stream buffer. The JPEG blob ID field must be set
* to CAMERA2_JPEG_BLOB_ID.
*/
typedef struct camera2_jpeg_blob {
uint16_t jpeg_blob_id;
uint32_t jpeg_size;
uint8_t jpeg_data[0];
};
enum {
CAMERA2_JPEG_BLOB_ID = 0x00FF
};
/**
* Input reprocess stream queue management. A set of these methods is provided
* to the HAL device in allocate_reprocess_stream(); they are used to interact