summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Hui <mhui@codeaurora.org>2012-01-01 16:51:26 -0500
committerSteve Kondik <shade@chemlab.org>2013-01-21 01:19:49 -0800
commit3b32931252a51d5aed91e2028928be907ebdff7c (patch)
tree9f82b2bfec4c0e5d44fb17725723e966812d82c6
parente4a9afa814f96ff1cfaab5a755d903ab16b84650 (diff)
downloadexternal_webkit-3b32931252a51d5aed91e2028928be907ebdff7c.zip
external_webkit-3b32931252a51d5aed91e2028928be907ebdff7c.tar.gz
external_webkit-3b32931252a51d5aed91e2028928be907ebdff7c.tar.bz2
external/webkit: use Cpu Upload path
Use Cpu Upload mode since the Gpu mode is not working and expected to be slower. Change-Id: Iacb6de4a4e054e4f6ebb07d8a8209228e78e5ee0
-rw-r--r--Source/WebCore/Android.mk5
-rw-r--r--Source/WebCore/platform/graphics/android/rendering/TransferQueue.cpp4
-rw-r--r--Source/WebCore/platform/graphics/android/rendering/TransferQueue.h4
3 files changed, 13 insertions, 0 deletions
diff --git a/Source/WebCore/Android.mk b/Source/WebCore/Android.mk
index b1b430c..1f8868e 100644
--- a/Source/WebCore/Android.mk
+++ b/Source/WebCore/Android.mk
@@ -1310,3 +1310,8 @@ ifeq ($(SUPPORT_COMPLEX_SCRIPTS),true)
LOCAL_SRC_FILES := $(LOCAL_SRC_FILES) \
platform/graphics/android/fonts/HarfbuzzSkia.cpp
endif
+
+# HACK for qcom devices CPU upload mode
+ifeq ($(TARGET_FORCE_CPU_UPLOAD),true)
+LOCAL_CFLAGS += -DFORCE_CPU_UPLOAD
+endif
diff --git a/Source/WebCore/platform/graphics/android/rendering/TransferQueue.cpp b/Source/WebCore/platform/graphics/android/rendering/TransferQueue.cpp
index 7c03219..857d377 100644
--- a/Source/WebCore/platform/graphics/android/rendering/TransferQueue.cpp
+++ b/Source/WebCore/platform/graphics/android/rendering/TransferQueue.cpp
@@ -516,7 +516,11 @@ void TransferQueue::setTextureUploadType(TextureUploadType type)
setPendingDiscard();
+#ifdef FORCE_CPU_UPLOAD
+ m_currentUploadType = CpuUpload; // force to cpu upload mode for now until gpu upload mode is fixed
+#else
m_currentUploadType = type;
+#endif
ALOGD("Now we set the upload to %s", m_currentUploadType == GpuUpload ? "GpuUpload" : "CpuUpload");
}
diff --git a/Source/WebCore/platform/graphics/android/rendering/TransferQueue.h b/Source/WebCore/platform/graphics/android/rendering/TransferQueue.h
index 55011b0..4ced1ea 100644
--- a/Source/WebCore/platform/graphics/android/rendering/TransferQueue.h
+++ b/Source/WebCore/platform/graphics/android/rendering/TransferQueue.h
@@ -69,7 +69,11 @@ enum TextureUploadType {
GpuUpload = 1
};
+#ifdef FORCE_CPU_UPLOAD
+#define DEFAULT_UPLOAD_TYPE CpuUpload
+#else
#define DEFAULT_UPLOAD_TYPE GpuUpload
+#endif
class TileTransferData {
public: