status_t res;
ExynosRect jpegRect;
bool found = false;
+ int srcW, srcH, srcCropX, srcCropY;
int pictureW, pictureH, pictureFramesize = 0;
int pictureFormat;
int cropX, cropY, cropW, cropH = 0;
return 1;
}
+ m_getRatioSize(selfStreamParms->width, selfStreamParms->height,
+ m_streamThreads[0]->m_parameters.width, m_streamThreads[0]->m_parameters.height,
+ &srcCropX, &srcCropY,
+ &srcW, &srcH,
+ 0);
+
m_jpegPictureRect.w = subParms->width;
m_jpegPictureRect.h = subParms->height;
__FUNCTION__, selfStreamParms->width, selfStreamParms->height,
m_jpegPictureRect.w, m_jpegPictureRect.h);
- m_getRatioSize(selfStreamParms->width, selfStreamParms->height,
+ m_getRatioSize(srcW, srcH,
m_jpegPictureRect.w, m_jpegPictureRect.h,
&cropX, &cropY,
&pictureW, &pictureH,
zoom_h = pictureH / m_zoomRatio;
zoom_w = zoom_h * m_jpegPictureRect.w / m_jpegPictureRect.h;
}
- cropX = (pictureW - zoom_w) / 2;
- cropY = (pictureH - zoom_h) / 2;
+ cropX = (srcW - zoom_w) / 2;
+ cropY = (srcH - zoom_h) / 2;
cropW = zoom_w;
cropH = zoom_h;
__FUNCTION__, cropX, cropY, cropW, cropH);
csc_set_src_format(m_exynosPictureCSC,
- ALIGN(pictureW, 16), ALIGN(pictureH, 16),
+ ALIGN(srcW, 16), ALIGN(srcH, 16),
cropX, cropY, cropW, cropH,
V4L2_PIX_2_HAL_PIXEL_FORMAT(pictureFormat),
0);