aboutsummaryrefslogtreecommitdiffhomepage
path: root/dm/DMSrcSink.h
diff options
context:
space:
mode:
authorGravatar brianosman <brianosman@google.com>2016-02-29 13:39:09 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-02-29 13:39:09 -0800
commiteef980270d3385fee340eb1633962fe3ba8b7132 (patch)
tree5a05ca058744f35b15c32a850f462087447a6176 /dm/DMSrcSink.h
parent683ea9a08d43cc3a3a5ca7f1bc3452823a881f82 (diff)
Progress on gamma-correctness in the GPU backend. Fixed conversion of color and profile type to pixel config, which makes many things "just work".
Added (color=8888|f16|srgb) option to gpu configurations, along with gpuf16, gpusrgb, and anglesrgb predefined configs. Runs the gpu backend in gamma-correct mode (with either FP16 linear or sRGB 8888 frambuffers). BUG=skia: GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1746253002 Review URL: https://codereview.chromium.org/1746253002
Diffstat (limited to 'dm/DMSrcSink.h')
-rw-r--r--dm/DMSrcSink.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/dm/DMSrcSink.h b/dm/DMSrcSink.h
index bbf47cffd8..babe14d135 100644
--- a/dm/DMSrcSink.h
+++ b/dm/DMSrcSink.h
@@ -213,7 +213,8 @@ public:
class GPUSink : public Sink {
public:
GPUSink(GrContextFactory::GLContextType, GrContextFactory::GLContextOptions,
- int samples, bool diText, bool threaded);
+ int samples, bool diText, SkColorType colorType, SkColorProfileType profileType,
+ bool threaded);
Error draw(const Src&, SkBitmap*, SkWStream*, SkString*) const override;
bool serial() const override { return !fThreaded; }
@@ -224,6 +225,8 @@ private:
GrContextFactory::GLContextOptions fContextOptions;
int fSampleCount;
bool fUseDIText;
+ SkColorType fColorType;
+ SkColorProfileType fProfileType;
bool fThreaded;
};