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

Unified Diff: src/gpu/text/GrAtlasTextBlob.cpp

Issue 1884873006: Rename lots of things from 'sRGB' to 'GammaCorrect', where appropriate (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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: src/gpu/text/GrAtlasTextBlob.cpp
diff --git a/src/gpu/text/GrAtlasTextBlob.cpp b/src/gpu/text/GrAtlasTextBlob.cpp
index 60f905df5f2946657ad0f150f05197a43603fada..65b84ddbc8fe57b99c51d4cdd923724db117014a 100644
--- a/src/gpu/text/GrAtlasTextBlob.cpp
+++ b/src/gpu/text/GrAtlasTextBlob.cpp
@@ -257,7 +257,7 @@ inline GrDrawBatch* GrAtlasTextBlob::createBatch(
GrColor color,
const SkPaint& skPaint, const SkSurfaceProps& props,
const GrDistanceFieldAdjustTable* distanceAdjustTable,
- bool useSRGBDistanceTable,
+ bool useGammaCorrectDistanceTable,
GrBatchFontCache* cache) {
GrMaskFormat format = info.maskFormat();
GrColor subRunColor;
@@ -279,7 +279,8 @@ inline GrDrawBatch* GrAtlasTextBlob::createBatch(
}
bool useBGR = SkPixelGeometryIsBGR(props.pixelGeometry());
batch = GrAtlasTextBatch::CreateDistanceField(glyphCount, cache,
- distanceAdjustTable, useSRGBDistanceTable,
+ distanceAdjustTable,
+ useGammaCorrectDistanceTable,
filteredColor, info.hasUseLCDText(), useBGR);
} else {
batch = GrAtlasTextBatch::CreateBitmap(format, glyphCount, cache);
@@ -311,13 +312,13 @@ void GrAtlasTextBlob::flushRun(GrDrawContext* dc, GrPipelineBuilder* pipelineBui
continue;
}
- bool useSRGBDistanceTable = GrPixelConfigIsSRGB(dc->accessRenderTarget()->config()) &&
+ bool useGammaCorrectTable = GrPixelConfigIsSRGB(dc->accessRenderTarget()->config()) &&
!pipelineBuilder->getDisableOutputConversionToSRGB();
SkAutoTUnref<GrDrawBatch> batch(this->createBatch(info, glyphCount, run,
subRun, viewMatrix, x, y, color,
skPaint, props,
- distanceAdjustTable, useSRGBDistanceTable,
+ distanceAdjustTable, useGammaCorrectTable,
cache));
dc->drawBatch(pipelineBuilder, batch);
}

Powered by Google App Engine
This is Rietveld 408576698