libOverlay : Set correct crop values for overlay with flip
When front camera is in use, overlay is created with 90 degree rotation and vertical flip. This change considers 90 degree rotation with flip, and updates the crop rectangle accordingly. CRs-Fixed : 283348, 284193 Change-Id: Ia0d7830f12d607ae698b019396cd0e2bef168a6a
This commit is contained in:
parent
1b5cb629f4
commit
9d4f87e88c
@ -1361,7 +1361,9 @@ bool OverlayDataChannel::setCrop(uint32_t x, uint32_t y, uint32_t w, uint32_t h)
|
||||
return false;
|
||||
}
|
||||
|
||||
if (ov.user_data[0] == MDP_ROT_90) {
|
||||
if ((ov.user_data[0] == MDP_ROT_90) ||
|
||||
(ov.user_data[0] == (MDP_ROT_90 | MDP_FLIP_UD)) ||
|
||||
(ov.user_data[0] == (MDP_ROT_90 | MDP_FLIP_LR))){
|
||||
if (ov.src.width < (y + h))
|
||||
return false;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user