diff --git a/libqcomui/Android.mk b/libqcomui/Android.mk index c60f18b..656591d 100644 --- a/libqcomui/Android.mk +++ b/libqcomui/Android.mk @@ -4,9 +4,10 @@ include $(CLEAR_VARS) LOCAL_SRC_FILES := \ qcom_ui.cpp -ifeq ($(call is-board-platform,msm7x27a),true) - LOCAL_CFLAGS += -DCHECK_FOR_EXTERNAL_FORMAT -endif +#ifeq ($(TARGET_BOARD_PLATFORM),qsd8k) # these are originally for 7x27a +# LOCAL_CFLAGS += -DCHECK_FOR_EXTERNAL_FORMAT +# LOCAL_CFLAGS += -DBYPASS_EGLIMAGE +#endif LOCAL_SHARED_LIBRARIES := \ libutils \ diff --git a/libqcomui/qcom_ui.cpp b/libqcomui/qcom_ui.cpp index 725c13f..9e0a593 100644 --- a/libqcomui/qcom_ui.cpp +++ b/libqcomui/qcom_ui.cpp @@ -134,6 +134,14 @@ int getNumberOfArgsForOperation(int operation) { * @return true if the format is supported by the GPU. */ bool isGPUSupportedFormat(int format) { + + // For 7x27A bypass creating EGL image for 420 SP + // This is done to save CPU utilization by SurfaceFlinger thread +#ifdef BYPASS_EGLIMAGE + if (format == HAL_PIXEL_FORMAT_YCrCb_420_SP){ + return false; + } +#endif if (format == HAL_PIXEL_FORMAT_YV12) { // We check the YV12 formats, since some Qcom specific formats // could have the bits set.