Commit 8cf1fec8 authored by Guennadi Liakhovetski's avatar Guennadi Liakhovetski Committed by Mauro Carvalho Chehab

V4L/DVB (13129): sh_mobile_ceu_camera: fix cropping for scaling clients

Fix a bug in cropping calculation, when the client is also scaling the image.
Signed-off-by: default avatarGuennadi Liakhovetski <g.liakhovetski@gmx.de>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent 1381dfd5
......@@ -1173,8 +1173,8 @@ static int get_scales(struct soc_camera_device *icd,
width_in = scale_up(cam->ceu_rect.width, *scale_h);
height_in = scale_up(cam->ceu_rect.height, *scale_v);
*scale_h = calc_generic_scale(cam->ceu_rect.width, icd->user_width);
*scale_v = calc_generic_scale(cam->ceu_rect.height, icd->user_height);
*scale_h = calc_generic_scale(width_in, icd->user_width);
*scale_v = calc_generic_scale(height_in, icd->user_height);
return 0;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment