Merge "hwc/overlay: MDSS driver requires 4-aligned crop.h for interlaced"

This commit is contained in:
Linux Build Service Account
2013-05-30 12:07:27 -07:00
committed by Gerrit - the friendly Code Review server
2 changed files with 8 additions and 0 deletions

View File

@@ -770,6 +770,9 @@ int configRotator(Rotator *rot, const Whf& whf,
if (ovutils::isYuv(whf.format)) {
ovutils::normalizeCrop((uint32_t&)crop.left, crop_w);
ovutils::normalizeCrop((uint32_t&)crop.top, crop_h);
// For interlaced, crop.h should be 4-aligned
if ((mdpFlags & ovutils::OV_MDP_DEINTERLACE) && (crop_h % 4))
crop_h = ovutils::aligndown(crop_h, 4);
crop.right = crop.left + crop_w;
crop.bottom = crop.top + crop_h;
}