}
/* Limit to hardware min/max. */
- v4l_bound_align_image(&pix_fmt_mp->width, 8, 1920, 0,
- &pix_fmt_mp->height, 4, 1088, 0, 0);
+ pix_fmt_mp->width = clamp(pix_fmt_mp->width, 48U, 3840U);
+ pix_fmt_mp->height = clamp(pix_fmt_mp->height, 48U, 2160U);
/* Round up to macroblocks. */
pix_fmt_mp->width = round_up(pix_fmt_mp->width, MB_DIM);
vpu_debug(0, "CAPTURE codec mode: %d\n", fmt->codec_mode);
vpu_debug(0, "fmt - w: %d, h: %d, mb - w: %d, h: %d\n",
- pix_fmt_mp->width, pix_fmt_mp->width,
+ pix_fmt_mp->width, pix_fmt_mp->height,
mb_width, mb_height);
for (i = 0; i < fmt->num_planes; ++i) {
}
/* Limit to hardware min/max. */
- v4l_bound_align_image(&pix_fmt_mp->width, 8, 1920, 0,
- &pix_fmt_mp->height, 4, 1080, 0, 0);
+ pix_fmt_mp->width = clamp(pix_fmt_mp->width, 96U, 1920U);
+ pix_fmt_mp->height = clamp(pix_fmt_mp->height, 96U, 1088U);
/* Round up to macroblocks. */
pix_fmt_mp->width = round_up(pix_fmt_mp->width, MB_DIM);
vpu_debug(0, "OUTPUT codec mode: %d\n", fmt->codec_mode);
vpu_debug(0, "fmt - w: %d, h: %d, mb - w: %d, h: %d\n",
- pix_fmt_mp->width, pix_fmt_mp->width,
+ pix_fmt_mp->width, pix_fmt_mp->height,
mb_width, mb_height);
for (i = 0; i < fmt->num_planes; ++i) {