RE: DSS2 Video Overlay Scaling Patch

Fischer Steven-P27614
2009-07-07T13:04:56Z

Sorry, missed the subject line.

-----Original Message-----
From: linux-omap-owner@vger.kernel.org
[mailto:linux-omap-owner@vger.kernel.org] On Behalf Of Fischer
Steven-P27614
Sent: Tuesday, July 07, 2009 7:54 AM
To: linux-omap@vger.kernel.org
Subject:

All,

The DSS2 code base seems to inadvertently prevent downscaling of video
overlay frames. Attached is my attempt at a patch to resolve this
issue.

As I gather from the code, there is an attempt to limit the overlay
output frame size (x, y, outw, outh) to the managers updated window
(mc->x, mc->y, mc->w, mc->h). The problem is that the input frame size
(w & h) is being used to instead of the output frame size (outw, outh).
Due to this, when the input frame size is large than the output frame
size, the input frame is being cropped, thus no downscaling occurs. My
patch corrects this issue and also attempts to properly scale the input
frame size if indeed the output frame is cropped.

In my particular case, the output frame size is never cropped, so I have
not explicitly tested these equations, but I believe they are
mathematically correct.

With this patch overlay downscaling is functional.

Steve.