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

Side by Side Diff: src/gpu/text/GrStencilAndCoverTextContext.cpp

Issue 1711223003: Only use fake gamma with linear devices. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Formatting. Created 4 years, 10 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 unified diff | Download patch
« no previous file with comments | « src/gpu/text/GrAtlasTextBlob.cpp ('k') | src/gpu/text/GrTextUtils.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2014 Google Inc. 2 * Copyright 2014 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "GrStencilAndCoverTextContext.h" 8 #include "GrStencilAndCoverTextContext.h"
9 #include "GrAtlasTextContext.h" 9 #include "GrAtlasTextContext.h"
10 #include "GrDrawContext.h" 10 #include "GrDrawContext.h"
(...skipping 611 matching lines...) Expand 10 before | Expand all | Expand 10 after
622 } 622 }
623 623
624 fallbackTextContext->drawTextBlob(ctx, dc, pipelineBuilder->clip(), fall backSkPaint, 624 fallbackTextContext->drawTextBlob(ctx, dc, pipelineBuilder->clip(), fall backSkPaint,
625 viewMatrix, props, fFallbackTextBlob, x, y, nullptr, 625 viewMatrix, props, fFallbackTextBlob, x, y, nullptr,
626 clipBounds); 626 clipBounds);
627 } 627 }
628 } 628 }
629 629
630 SkGlyphCache* GrStencilAndCoverTextContext::TextRun::getGlyphCache() const { 630 SkGlyphCache* GrStencilAndCoverTextContext::TextRun::getGlyphCache() const {
631 if (!fDetachedGlyphCache) { 631 if (!fDetachedGlyphCache) {
632 fDetachedGlyphCache = fFont.detachCache(nullptr, nullptr, true /*ignoreG amma*/); 632 fDetachedGlyphCache = fFont.detachCache(nullptr, SkPaint::FakeGamma::Off , nullptr);
633 } 633 }
634 return fDetachedGlyphCache; 634 return fDetachedGlyphCache;
635 } 635 }
636 636
637 637
638 void GrStencilAndCoverTextContext::TextRun::releaseGlyphCache() const { 638 void GrStencilAndCoverTextContext::TextRun::releaseGlyphCache() const {
639 if (fDetachedGlyphCache) { 639 if (fDetachedGlyphCache) {
640 SkGlyphCache::AttachCache(fDetachedGlyphCache); 640 SkGlyphCache::AttachCache(fDetachedGlyphCache);
641 fDetachedGlyphCache = nullptr; 641 fDetachedGlyphCache = nullptr;
642 } 642 }
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
697 } 697 }
698 698
699 const SkTextBlob* GrStencilAndCoverTextContext::FallbackBlobBuilder::buildIfNeed ed(int *count) { 699 const SkTextBlob* GrStencilAndCoverTextContext::FallbackBlobBuilder::buildIfNeed ed(int *count) {
700 *count = fCount; 700 *count = fCount;
701 if (fCount) { 701 if (fCount) {
702 this->flush(); 702 this->flush();
703 return fBuilder->build(); 703 return fBuilder->build();
704 } 704 }
705 return nullptr; 705 return nullptr;
706 } 706 }
OLDNEW
« no previous file with comments | « src/gpu/text/GrAtlasTextBlob.cpp ('k') | src/gpu/text/GrTextUtils.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698