From 081a89a5ad82161e7dfc83776e3468e1421628b0 Mon Sep 17 00:00:00 2001 From: Andrew Sutherland Date: Fri, 16 Mar 2012 23:53:44 -0500 Subject: [PATCH] fixup after huge update this brings us inline with cafs ics_chocolate branch per: f696608c9d9e3b6b60a92423338f08d59d19d746 Change-Id: Ibaff05220e7d7f0ddd1b4d7507626a38d717340c --- libgralloc/Android.mk | 3 ++- libgralloc/framebuffer.cpp | 4 +++- libhwcomposer/Android.mk | 5 ++--- liboverlay/overlayLib.cpp | 14 ++++++-------- libqcomui/qcom_ui.cpp | 4 ++-- 5 files changed, 15 insertions(+), 15 deletions(-) diff --git a/libgralloc/Android.mk b/libgralloc/Android.mk index d727017..82c92ee 100644 --- a/libgralloc/Android.mk +++ b/libgralloc/Android.mk @@ -40,7 +40,8 @@ ifeq ($(call is-board-platform,msm7x27),true) endif ifeq ($(TARGET_QCOM_HDMI_OUT),true) - LOCAL_CFLAGS += -DHDMI_DUAL_DISPLAY -DQCOM_HDMI_OUT + LOCAL_CFLAGS += -DHDMI_DUAL_DISPLAY + LOCAL_CFLAGS += -DQCOM_HDMI_OUT LOCAL_C_INCLUDES += hardware/qcom/display/liboverlay LOCAL_SHARED_LIBRARIES += liboverlay endif diff --git a/libgralloc/framebuffer.cpp b/libgralloc/framebuffer.cpp index 2abe2ee..66c6d9b 100644 --- a/libgralloc/framebuffer.cpp +++ b/libgralloc/framebuffer.cpp @@ -362,6 +362,8 @@ static int fb_enableHDMIOutput(struct framebuffer_device_t* dev, int externaltyp dev->common.module); pthread_mutex_lock(&m->overlayLock); Overlay* pTemp = m->pobjOverlay; + //Check if true mirroring can be supported + m->trueMirrorSupport = FrameBufferInfo::getInstance()->canSupportTrueMirroring(); m->enableHDMIOutput = externaltype; LOGE("In fb_enableHDMIOutput: externaltype = %d", m->enableHDMIOutput); if(externaltype) { @@ -793,7 +795,7 @@ int mapFrameBufferLocked(struct private_module_t* module) pthread_t hdmiUIThread; pthread_create(&hdmiUIThread, NULL, &hdmi_ui_loop, (void *) module); module->hdmiMirroringState = HDMI_NO_MIRRORING; - module->trueMirrorSupport = FrameBufferInfo::getInstance()->canSupportTrueMirroring(); + module->trueMirrorSupport = false; #endif return 0; diff --git a/libhwcomposer/Android.mk b/libhwcomposer/Android.mk index 49cfe00..c0afc43 100644 --- a/libhwcomposer/Android.mk +++ b/libhwcomposer/Android.mk @@ -22,10 +22,9 @@ LOCAL_C_INCLUDES += hardware/qcom/display/libcopybit LOCAL_C_INCLUDES += hardware/qcom/display/libgenlock LOCAL_C_INCLUDES += hardware/qcom/display/libqcomui -LOCAL_CFLAGS += -DQCOM_HARDWARE - ifeq ($(TARGET_QCOM_HDMI_OUT),true) -LOCAL_CFLAGS += -DHDMI_DUAL_DISPLAY -DQCOM_HDMI_OUT +LOCAL_CFLAGS += -DHDMI_DUAL_DISPLAY +LOCAL_CFLAGS += -DQCOM_HDMI_OUT endif ifeq ($(TARGET_USES_OVERLAY),true) LOCAL_CFLAGS += -DUSE_OVERLAY diff --git a/liboverlay/overlayLib.cpp b/liboverlay/overlayLib.cpp index dbfebc9..90261dc 100755 --- a/liboverlay/overlayLib.cpp +++ b/liboverlay/overlayLib.cpp @@ -913,11 +913,11 @@ bool Overlay::setFd(int fd, int channel) { bool Overlay::queueBuffer(uint32_t offset, int channel) { return objOvDataChannel[channel].queueBuffer(offset); } -#if 0 + bool Overlay::waitForHdmiVsync(int channel) { return objOvDataChannel[channel].waitForHdmiVsync(); } -#endif + bool Overlay::queueBuffer(buffer_handle_t buffer) { private_handle_t const* hnd = reinterpret_cast (buffer); @@ -946,13 +946,11 @@ bool Overlay::queueBuffer(buffer_handle_t buffer) { return false; } } -#if 0 //Wait for HDMI done.. if(!waitForHdmiVsync(VG1_PIPE)) { LOGE("%s: waitforHdmiVsync failed", __FUNCTION__); return false; } -#endif break; default: LOGE("%s:Unknown state %d", __FUNCTION__, mState); @@ -1869,11 +1867,11 @@ bool OverlayDataChannel::mapRotatorMemory(int num_buffers, bool uiChannel, int r mPmemFD = data.fd; mPmemAddr = data.base; mBufferType = data.allocType; -#if 0 + // Set this flag if source memory is fb if(uiChannel) mRotData.src.flags |= MDP_MEMORY_ID_TYPE_FB; -#endif + mOvDataRot.data.memory_id = mPmemFD; mRotData.dst.memory_id = mPmemFD; mRotData.dst.offset = 0; @@ -2003,7 +2001,7 @@ bool OverlayDataChannel::queue(uint32_t offset) { return true; } -#if 0 + bool OverlayDataChannel::waitForHdmiVsync() { if (!isChannelUP()) { LOGE("%s: channel not up", __FUNCTION__); @@ -2015,7 +2013,7 @@ bool OverlayDataChannel::waitForHdmiVsync() { } return true; } -#endif + bool OverlayDataChannel::getCropS3D(overlay_rect *inRect, int channel, int format, overlay_rect *rect) { // for the 3D usecase extract channels from a frame diff --git a/libqcomui/qcom_ui.cpp b/libqcomui/qcom_ui.cpp index 6bc4eed..ae203e1 100644 --- a/libqcomui/qcom_ui.cpp +++ b/libqcomui/qcom_ui.cpp @@ -193,7 +193,7 @@ int decideTextureTarget(int pixel_format) * @return true if the format is supported by the GPU. */ bool isGPUSupportedFormatInHW(int format) { - // For 7x27A bypass creating EGL image for formats not natively supported + // For 7x27A bypass creating EGL image for formats not natively supported // in GPU. // This is done to save CPU utilization by SurfaceFlinger thread #ifdef CHECK_FOR_EXTERNAL_FORMAT @@ -212,6 +212,7 @@ bool isGPUSupportedFormatInHW(int format) { return true; } + /* * Function to check if the allocated buffer is of the correct size. * Reallocate the buffer with the correct size, if the size doesn't @@ -535,7 +536,6 @@ external_display handleEventHDMI(external_display newState, external_display } return retState; } - #ifdef DEBUG_CALC_FPS ANDROID_SINGLETON_STATIC_INSTANCE(CalcFps) ;