hwc: Use GPU Composition for 8x26 virtual dpy scaling case

For 8x26, if there is only one layer which needs scale for
secondary display, while no scale for primary display, DMA
pipe is occupied by primary. If layer changed and need to
fall back to GLES composition, virtual display lacks DMA
pipe and error is reported.

To avoid this case, use GPU composition for virtual display
scaling case on 8x26.

Change-Id: I42297a18006517532e30d1a01c67ff8ca187482a
This commit is contained in:
Yang Xu
2013-11-26 01:28:13 +08:00
parent bff954800a
commit 9c1eb2be21

View File

@@ -586,6 +586,15 @@ bool MDPComp::fullMDPComp(hwc_context_t *ctx, hwc_display_contents_1_t* list) {
ALOGD_IF(isDebug(), "%s: Unsupported layer in list",__FUNCTION__); ALOGD_IF(isDebug(), "%s: Unsupported layer in list",__FUNCTION__);
return false; return false;
} }
//For 8x26, if there is only one layer which needs scale for secondary
//while no scale for primary display, DMA pipe is occupied by primary.
//If need to fall back to GLES composition, virtual display lacks DMA
//pipe and error is reported.
if(qdutils::MDPVersion::getInstance().is8x26() &&
mDpy >= HWC_DISPLAY_EXTERNAL &&
qhwc::needsScaling(ctx, layer, mDpy))
return false;
} }
mCurrentFrame.fbCount = 0; mCurrentFrame.fbCount = 0;
mCurrentFrame.fbZ = -1; mCurrentFrame.fbZ = -1;