Index: tools/skiaserve/urlhandlers/UrlHandler.h |
diff --git a/tools/skiaserve/urlhandlers/UrlHandler.h b/tools/skiaserve/urlhandlers/UrlHandler.h |
index adbdcb9aa2e3540eb3ecc06b9c4f2fef5a9eadc5..d767aaebd4eb6a1fee7d65c4473a41cb644fa868 100644 |
--- a/tools/skiaserve/urlhandlers/UrlHandler.h |
+++ b/tools/skiaserve/urlhandlers/UrlHandler.h |
@@ -141,3 +141,16 @@ public: |
const char* url, const char* method, |
const char* upload_data, size_t* upload_data_size) override; |
}; |
+ |
+/** |
+ * Controls the global sRGB flag (is SkColor treated as sRGB or not). |
+ * Posting to /srgbMode/0 causes SkColor to be linear, /colorMode/1 |
+ * causes SkColor to be sRGB; |
+ */ |
+class SRGBModeHandler : public UrlHandler { |
+public: |
+ bool canHandle(const char* method, const char* url) override; |
+ int handle(Request* request, MHD_Connection* connection, |
+ const char* url, const char* method, |
+ const char* upload_data, size_t* upload_data_size) override; |
+}; |