Apply gamma correction to font rendering.
Change-Id: I1b05f40e356221b2a5eb9400e67d77ecd98ed6c4
diff --git a/libs/hwui/FontRenderer.h b/libs/hwui/FontRenderer.h
index 96c92d5..a03ea92 100644
--- a/libs/hwui/FontRenderer.h
+++ b/libs/hwui/FontRenderer.h
@@ -124,6 +124,10 @@
void init();
void deinit();
+ void setGammaTable(const uint8_t* gammaTable) {
+ mGammaTable = gammaTable;
+ }
+
void setFont(SkPaint* paint, uint32_t fontId, float fontSize);
void renderText(SkPaint* paint, const Rect* clip, const char *text, uint32_t startIndex,
uint32_t len, int numGlyphs, int x, int y);
@@ -157,6 +161,8 @@
protected:
friend class Font;
+ const uint8_t* mGammaTable;
+
struct CacheTextureLine {
uint16_t mMaxHeight;
uint16_t mMaxWidth;