diff options
author | Derek Sollenberger <djsollen@google.com> | 2018-11-28 19:40:22 +0000 |
---|---|---|
committer | Android (Google) Code Review <android-gerrit@google.com> | 2018-11-28 19:40:22 +0000 |
commit | 5fdb83b2a3385ebf9fff4cd6f717d22bfc0fa912 (patch) | |
tree | 6470bd6443634e2887023ad98dc8020fcfdb6a94 /libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp | |
parent | 1e44f82dd89bbd863619f8a17a2fbf65cbf2ab84 (diff) | |
parent | d01b5916d8b512ee4df8d749022c10419b58b4b2 (diff) |
Merge "Set the color space to sRGB on the Surface and remove colorFilter."
Diffstat (limited to 'libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp')
-rw-r--r-- | libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp b/libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp index 6ae59990d0ab..142bca95e598 100644 --- a/libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp +++ b/libs/hwui/pipeline/skia/SkiaOpenGLPipeline.cpp @@ -97,7 +97,7 @@ bool SkiaOpenGLPipeline::draw(const Frame& frame, const SkRect& screenDirty, con SkASSERT(mRenderThread.getGrContext() != nullptr); sk_sp<SkSurface> surface(SkSurface::MakeFromBackendRenderTarget( mRenderThread.getGrContext(), backendRT, kBottomLeft_GrSurfaceOrigin, colorType, - nullptr, &props)); + mSurfaceColorSpace, &props)); SkiaPipeline::updateLighting(lightGeometry, lightInfo); renderFrame(*layerUpdateQueue, dirty, renderNodes, opaque, contentDrawBounds, surface); @@ -176,6 +176,7 @@ bool SkiaOpenGLPipeline::setSurface(Surface* surface, SwapBehavior swapBehavior, } else if (colorMode == ColorMode::WideColorGamut) { mSurfaceColorType = SkColorType::kRGBA_F16_SkColorType; } + mSurfaceColorSpace = SkColorSpace::MakeSRGB(); if (mEglSurface != EGL_NO_SURFACE) { const bool preserveBuffer = (swapBehavior != SwapBehavior::kSwap_discardBuffer); |