From: Archit Taneja <archit@ti.com>
To: Peter Meerwald <pmeerw@pmeerw.net>
Cc: linux-omap@vger.kernel.org, Tomi Valkeinen <tomi.valkeinen@ti.com>
Subject: Re: downscaling YUV fails
Date: Wed, 19 Dec 2012 15:46:29 +0530 [thread overview]
Message-ID: <50D193FD.4070401@ti.com> (raw)
In-Reply-To: <alpine.DEB.2.01.1212191025480.16226@pmeerw.net>
Hi,
On Wednesday 19 December 2012 03:21 PM, Peter Meerwald wrote:
> Hello,
>
> downscaling a YUV video from /dev/fb1 silently fails and results in
> incorrectly rendered data (each line is shifted a bit more to the right,
> turning vertical lines into diagonals) -- observed with Linux 3.6.11 on
> omap3/dm3730
>
>
> test data (an image with vertical bars) is produced by:
> gst-launch-0.10 videotestsrc ! video/x-raw-yuv, width=400, height=240 ! freeze ! omapfbsink
>
> cd /sys/devices/platform/omapdss/overlay1
> echo 400,240 > output_size
> echo 100,100 > position
> echo 220,140 > output_size
> this downscales the YUV data from 400x240->220x140 and results in
> distorted output data (see http://pmeerw.net/overlay-distorted.jpg)
>
> note that upscaling works
>
> more observations:
> setting CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK=4 results in correct downscaling
> with x_predecim=1/y_predecim=1
>
> CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK=0 leads to distorted output with
> x_predecim=2/y_predecim=1
>
Configuring CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK to 0 will make the driver
try to derive a closer accurate pixel clock, but it will sacrifice on
the DISPC_FCLK used by scalar.
Configuring it to 4 will ensure that DISPC_FCLK is at least 4 times the
pixel clock.
The DISPC HW can achieve more downscaling when the DISPC_FCLK is higher.
In the case we set it to 4, the DISPC_FCLK is fast enough to do the
required downscaling, but in the case when it's set to 0, it might need
to pre decimate rather than try to scale.
>
>
> I think there is a bug downscaling YUV data when resorting to
> pre-decimation; setting CONFIG_OMAP2_DSS_MIN_FCK_PER_PCK is a workaround
> -- any ideas how this can be fixed?
Pre-decimation should work for YUV formats also. Could you share DISPC
reg dumps when this happens:
mount -t debugfs debugfs /sys/kernel/debug
cat /sys/kernel/debug/omapdss/dispc
Thanks,
Archit
next prev parent reply other threads:[~2012-12-19 10:16 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-12-19 9:51 downscaling YUV fails Peter Meerwald
2012-12-19 10:16 ` Archit Taneja [this message]
2012-12-19 10:51 ` Peter Meerwald
2012-12-19 11:19 ` Tomi Valkeinen
2012-12-19 11:21 ` Tomi Valkeinen
2012-12-19 11:52 ` Archit Taneja
2012-12-19 11:59 ` Tomi Valkeinen
2012-12-19 12:19 ` Archit Taneja
2012-12-19 12:37 ` Tomi Valkeinen
2012-12-19 13:00 ` Archit Taneja
2012-12-19 13:10 ` Tomi Valkeinen
2012-12-19 12:15 ` Peter Meerwald
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50D193FD.4070401@ti.com \
--to=archit@ti.com \
--cc=linux-omap@vger.kernel.org \
--cc=pmeerw@pmeerw.net \
--cc=tomi.valkeinen@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.