From 16dc774fe1e92f3b9239c59ad368b18d3300a7f1 Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Wed, 15 Aug 2012 11:48:40 +0200 Subject: omap3isp: Scale instead of cropping when scaling on the sensor When using sensor scaling the sensor was incorrectly configured to crop the image to a lower size instead of scaling it. Cropping is applied before scaling in the sensor, so the crop rectangle needs to be set to the pipeline input size, not the sensor output size. Signed-off-by: Laurent Pinchart --- isp/omap3isp.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/isp/omap3isp.c b/isp/omap3isp.c index eb5d2e8..00b451b 100644 --- a/isp/omap3isp.c +++ b/isp/omap3isp.c @@ -714,8 +714,8 @@ static int omap3_isp_pipeline_try_format(struct omap3_isp_device *isp, /* If crop is not requested, reset the crop rectangle on the * sensor to its default value. */ - source->source.crop.width = format.width; - source->source.crop.height = format.height; + source->source.crop.width = ifmt->width; + source->source.crop.height = ifmt->height; } /* Try to force the output format code onto the source pad. */ -- cgit v1.2.3