hwc: adjust protected content scaling for gscaler width constraints
authorGreg Hackmann <ghackmann@google.com>
Thu, 18 Oct 2012 17:37:59 +0000 (10:37 -0700)
committerGreg Hackmann <ghackmann@google.com>
Thu, 18 Oct 2012 23:33:17 +0000 (16:33 -0700)
commit92b0aadb2237196ee193c6500c6f864c8497c97a
tree6bd3bc9535925526eb33e6d1dd57b55907ab4e72
parentd08bf0b27662d58d1768123dc5e370322fc0308a
hwc: adjust protected content scaling for gscaler width constraints

Protected content cannot be sent through the GPU.  Instead slightly
over-scale to meet the Gscaler's 32-pixel alignment constraint and crop
back to the requested display frame.

Also move the minimum-width check to prevent a potential divide-by-zero
in the padding calculations.

Bug: 7365351
Change-Id: Ia0807fe6c4a6c25364fe08ed1f2eb223f3cb0d4e
Signed-off-by: Greg Hackmann <ghackmann@google.com>
libhwc/hwc.cpp