switch (format) {
ALOGE("invalid yuv format %d\n", format);
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
{
luma_vstride = ALIGN(h, 16);
luma_size = luma_vstride * *stride;
planes = 3;
break;
}
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_SP_TILED:
{
HAL_PIXEL_FORMAT_CUSTOM_CbYCrY_422_I = 0x117,
HAL_PIXEL_FORMAT_CUSTOM_CrYCbY_422_I = 0x118,
HAL_PIXEL_FORMAT_CUSTOM_CbYCr_422_I = 0x11B,
+
+ HAL_PIXEL_FORMAT_EXYNOS_YV12 = 0x11C,
+ HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP = 0x11D,
HAL_PIXEL_FORMAT_CUSTOM_MAX
};
m_scp_closed = false;
usleep(100000); // TODO : guarantee the codes below will be run after readyToRunInternal()
- *format_actual = HAL_PIXEL_FORMAT_YV12;
+ *format_actual = HAL_PIXEL_FORMAT_EXYNOS_YV12;
*usage = GRALLOC_USAGE_SW_WRITE_OFTEN;
*max_buffers = 8;
csc_set_src_format(m_exynosVideoCSC,
previewW, previewH,
cropX, cropY, cropW, cropH,
- HAL_PIXEL_FORMAT_YV12,
+ HAL_PIXEL_FORMAT_EXYNOS_YV12,
0);
csc_set_dst_format(m_exynosVideoCSC,
v4l2_pixel_format = V4L2_PIX_FMT_RGB444;
break;
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
v4l2_pixel_format = V4L2_PIX_FMT_YVU420M;
break;
v4l2_pixel_format = V4L2_PIX_FMT_NV16;
break;
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCrCb_420_SP:
v4l2_pixel_format = V4L2_PIX_FMT_NV21M;
break;
case V4L2_PIX_FMT_YVU420:
case V4L2_PIX_FMT_YVU420M:
- hal_pixel_format = HAL_PIXEL_FORMAT_YV12;
+ hal_pixel_format = HAL_PIXEL_FORMAT_EXYNOS_YV12;
break;
case V4L2_PIX_FMT_NV16:
int NUM_PLANES(int hal_pixel_format)
{
switch(hal_pixel_format) {
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
case HAL_PIXEL_FORMAT_YCbCr_420_P:
return 3;
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCbCr_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCrCb_420_SP:
break;
// 12bpp
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
case HAL_PIXEL_FORMAT_YCbCr_420_P:
case HAL_PIXEL_FORMAT_YCbCr_420_I:
case HAL_PIXEL_FORMAT_CbYCrY_420_I:
frame_size = size + 2 * ALIGN(width >> 1, 8) * ALIGN(height >> 1, 8);
break;
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCbCr_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCrCb_420_SP:
unsigned int size = 0;
switch(hal_pixel_format) {
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
case HAL_PIXEL_FORMAT_YCbCr_420_P:
size = width * height;
*luma_size = size;
*chroma_size = size >> 2;
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_I:
case HAL_PIXEL_FORMAT_CbYCrY_420_I:
case HAL_PIXEL_FORMAT_YCbCr_420_SP:
switch (format) {
case HAL_PIXEL_FORMAT_RGBX_8888:
case HAL_PIXEL_FORMAT_RGB_565:
- case HAL_PIXEL_FORMAT_YV12:
+ case HAL_PIXEL_FORMAT_EXYNOS_YV12:
case HAL_PIXEL_FORMAT_YCbCr_420_P:
case HAL_PIXEL_FORMAT_YCbCr_422_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCbCr_422_SP:
case HAL_PIXEL_FORMAT_CUSTOM_CbYCrY_422_I:
case HAL_PIXEL_FORMAT_YCrCb_422_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCrCb_422_SP:
- case HAL_PIXEL_FORMAT_YCrCb_420_SP:
+ case HAL_PIXEL_FORMAT_EXYNOS_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_CUSTOM_YCrCb_420_SP:
case HAL_PIXEL_FORMAT_YCbCr_420_SP_TILED:
case HAL_PIXEL_FORMAT_CUSTOM_YCbCr_420_SP_TILED:
static bool exynos5_format_is_ycrcb(int format)
{
- return format == HAL_PIXEL_FORMAT_YV12;
+ return format == HAL_PIXEL_FORMAT_EXYNOS_YV12;
}
static bool exynos5_format_requires_gscaler(int format)
info->h = enum_preset.height;
info->fw = enum_preset.width;
info->fh = enum_preset.height;
- info->format = HAL_PIXEL_FORMAT_YV12;
+ info->format = HAL_PIXEL_FORMAT_EXYNOS_YV12;
found = true;
}
}