From dcda8a5f279bc46d6dfd19d31d6f05ce3d44397b Mon Sep 17 00:00:00 2001 From: Ramakant Singh Date: Thu, 27 Sep 2012 10:17:55 +0530 Subject: [PATCH] HWC/copybit::Add condition for video layer composition In case of non overlay target composition of the video layer should base on composition of UI layer as well. (if taget has dynamic composition) Change-Id: I5eb91adec340297fdc4b0560f01f74aaf8459586 CRs-fixed: 397517 --- libhwcomposer/hwc_copybit.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libhwcomposer/hwc_copybit.cpp b/libhwcomposer/hwc_copybit.cpp index bab7184..343f9ce 100644 --- a/libhwcomposer/hwc_copybit.cpp +++ b/libhwcomposer/hwc_copybit.cpp @@ -155,7 +155,9 @@ bool CopyBit::prepare(hwc_context_t *ctx, hwc_layer_list_t *list) { if (hnd->bufferType == BUFFER_TYPE_VIDEO) { //YUV layer, check, if copybit can be used - if (useCopybitForYUV) { + // mark the video layer to gpu when all layer is + // going to gpu in case of dynamic composition. + if (useCopybitForYUV && useCopybitForRGB) { list->hwLayers[i].compositionType = HWC_USE_COPYBIT; sCopyBitDraw = true; }