diff options
author | Brian Osman <brianosman@google.com> | 2017-08-21 16:48:46 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-08-21 23:07:08 +0000 |
commit | f21aa04dca1ab16e57d9bac3f6a08abb7e107d95 (patch) | |
tree | 1d11e374bd925568750f2dec55a1a17fdab98b33 /dm/DMSrcSink.cpp | |
parent | b30c8d45311bcafba522ee70ba8b3159bf805142 (diff) |
Plumb GrContextOptions to GPU sinks in DM
We were ignoring the path renderer flag when drawing GMs or SKPs.
Bug: skia:
Change-Id: Iee443fb70f1faec65e46925fa0e3cea3716d448d
Reviewed-on: https://skia-review.googlesource.com/36861
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Diffstat (limited to 'dm/DMSrcSink.cpp')
-rw-r--r-- | dm/DMSrcSink.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/dm/DMSrcSink.cpp b/dm/DMSrcSink.cpp index 9eee2d2fd0..f9e5fd3d21 100644 --- a/dm/DMSrcSink.cpp +++ b/dm/DMSrcSink.cpp @@ -1301,7 +1301,8 @@ GPUSink::GPUSink(GrContextFactory::ContextType ct, SkColorType colorType, SkAlphaType alphaType, sk_sp<SkColorSpace> colorSpace, - bool threaded) + bool threaded, + const GrContextOptions& grCtxOptions) : fContextType(ct) , fContextOverrides(overrides) , fSampleCount(samples) @@ -1309,12 +1310,13 @@ GPUSink::GPUSink(GrContextFactory::ContextType ct, , fColorType(colorType) , fAlphaType(alphaType) , fColorSpace(std::move(colorSpace)) - , fThreaded(threaded) {} + , fThreaded(threaded) + , fBaseContextOptions(grCtxOptions) {} DEFINE_bool(drawOpClip, false, "Clip each GrDrawOp to its device bounds for testing."); Error GPUSink::draw(const Src& src, SkBitmap* dst, SkWStream*, SkString* log) const { - GrContextOptions grOptions; + GrContextOptions grOptions = fBaseContextOptions; src.modifyGrContextOptions(&grOptions); |