summaryrefslogtreecommitdiff
path: root/libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp
diff options
context:
space:
mode:
authorRomain Guy <romainguy@google.com>2017-04-17 09:39:51 -0700
committerRomain Guy <romainguy@google.com>2017-06-02 11:02:13 -0700
commit26a2b97dbe48ee45e9ae70110714048f2f360f97 (patch)
tree1e8e25d446c598d0b552708c90878246a370ba42 /libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp
parent3b3388ca64a818f2c036cf0dbf02a9e011ccc8de (diff)
Enable wide color gamut rendering
When wide color gamut rendering is requested, hwui will now use an rgba16f scRGB-nl surface for rendering. This change also fixes the way screenshots are handled in the platform to behave properly with wide gamut rendering. This change does not affect hardware layers. They also need to use rgba16f scRGB-nl; this will be addressed in another CL. Bug: 29940137 Test: CtsUiRenderingTestCases, CtsGraphicsTestCases Change-Id: I68fd96c451652136c566ec48fb0e97c2a7a257c5
Diffstat (limited to 'libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp')
-rw-r--r--libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp b/libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp
index d28e605a051f..e8e8ccd96654 100644
--- a/libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp
+++ b/libs/hwui/pipeline/skia/SkiaVulkanPipeline.cpp
@@ -131,13 +131,15 @@ DeferredLayerUpdater* SkiaVulkanPipeline::createTextureLayer() {
void SkiaVulkanPipeline::onStop() {
}
-bool SkiaVulkanPipeline::setSurface(Surface* surface, SwapBehavior swapBehavior) {
+bool SkiaVulkanPipeline::setSurface(Surface* surface, SwapBehavior swapBehavior,
+ ColorMode colorMode) {
if (mVkSurface) {
mVkManager.destroySurface(mVkSurface);
mVkSurface = nullptr;
}
if (surface) {
+ // TODO: handle color mode
mVkSurface = mVkManager.createSurface(surface);
}