Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(244)

Unified Diff: include/gpu/GrPaint.h

Issue 1845283003: Gamma-correctness pushed into Skia, top-down. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Remove helper function for old pixel-config method of enabling decode Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: include/gpu/GrPaint.h
diff --git a/include/gpu/GrPaint.h b/include/gpu/GrPaint.h
index 3f06f092ab45fe55b132252f2d647356c0feefe8..0cfc49f1e27ad42b16f73d4beda96341f0f92d15 100644
--- a/include/gpu/GrPaint.h
+++ b/include/gpu/GrPaint.h
@@ -63,6 +63,12 @@ public:
void setDisableOutputConversionToSRGB(bool srgb) { fDisableOutputConversionToSRGB = srgb; }
bool getDisableOutputConversionToSRGB() const { return fDisableOutputConversionToSRGB; }
+ /**
robertphillips 2016/04/05 12:54:34 Expand on this a bit?
Brian Osman 2016/04/05 15:36:41 Acknowledged.
+ * Should sRGB inputs be allowed to perform sRGB to linear conversion.
+ */
+ void setAllowSRGBInputs(bool allowSRGBInputs) { fAllowSRGBInputs = allowSRGBInputs; }
+ bool getAllowSRGBInputs() const { return fAllowSRGBInputs; }
+
const GrXPFactory* setXPFactory(const GrXPFactory* xpFactory) {
fXPFactory.reset(SkSafeRef(xpFactory));
return xpFactory;
@@ -120,6 +126,7 @@ public:
GrPaint& operator=(const GrPaint& paint) {
fAntiAlias = paint.fAntiAlias;
fDisableOutputConversionToSRGB = paint.fDisableOutputConversionToSRGB;
+ fAllowSRGBInputs = paint.fAllowSRGBInputs;
fColor = paint.fColor;
this->resetFragmentProcessors();
@@ -163,6 +170,7 @@ private:
bool fAntiAlias;
bool fDisableOutputConversionToSRGB;
+ bool fAllowSRGBInputs;
GrColor fColor;
};

Powered by Google App Engine
This is Rietveld 408576698