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

Side by Side Diff: src/gpu/GrContext.cpp

Issue 2339213002: Add GrContextOptions flag to disable distance field path renderer. (Closed)
Patch Set: Add trivial default constructor to satisfy clang Created 4 years, 3 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 | « include/gpu/GrContextOptions.h ('k') | src/gpu/GrDrawingManager.h » ('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 2011 Google Inc. 2 * Copyright 2011 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 "GrContext.h" 8 #include "GrContext.h"
9 #include "GrContextPriv.h" 9 #include "GrContextPriv.h"
10 #include "GrContextOptions.h" 10 #include "GrContextOptions.h"
(...skipping 77 matching lines...) Expand 10 before | Expand all | Expand 10 after
88 fResourceCache = new GrResourceCache(fCaps); 88 fResourceCache = new GrResourceCache(fCaps);
89 fResourceProvider = new GrResourceProvider(fGpu, fResourceCache, &fSingleOwn er); 89 fResourceProvider = new GrResourceProvider(fGpu, fResourceCache, &fSingleOwn er);
90 90
91 fDidTestPMConversions = false; 91 fDidTestPMConversions = false;
92 92
93 GrDrawTarget::Options dtOptions; 93 GrDrawTarget::Options dtOptions;
94 dtOptions.fClipBatchToBounds = options.fClipBatchToBounds; 94 dtOptions.fClipBatchToBounds = options.fClipBatchToBounds;
95 dtOptions.fDrawBatchBounds = options.fDrawBatchBounds; 95 dtOptions.fDrawBatchBounds = options.fDrawBatchBounds;
96 dtOptions.fMaxBatchLookback = options.fMaxBatchLookback; 96 dtOptions.fMaxBatchLookback = options.fMaxBatchLookback;
97 dtOptions.fMaxBatchLookahead = options.fMaxBatchLookahead; 97 dtOptions.fMaxBatchLookahead = options.fMaxBatchLookahead;
98 fDrawingManager.reset(new GrDrawingManager(this, dtOptions, options.fImmedia teMode, 98 GrPathRendererChain::Options prcOptions;
99 prcOptions.fDisableDistanceFieldRenderer = options.fDisableDistanceFieldPath s;
100 fDrawingManager.reset(new GrDrawingManager(this, dtOptions, prcOptions, opti ons.fImmediateMode,
99 &fSingleOwner)); 101 &fSingleOwner));
100 102
101 // GrBatchFontCache will eventually replace GrFontCache 103 // GrBatchFontCache will eventually replace GrFontCache
102 fBatchFontCache = new GrBatchFontCache(this); 104 fBatchFontCache = new GrBatchFontCache(this);
103 105
104 fTextBlobCache.reset(new GrTextBlobCache(TextBlobCacheOverBudgetCB, this)); 106 fTextBlobCache.reset(new GrTextBlobCache(TextBlobCacheOverBudgetCB, this));
105 } 107 }
106 108
107 GrContext::~GrContext() { 109 GrContext::~GrContext() {
108 ASSERT_SINGLE_OWNER 110 ASSERT_SINGLE_OWNER
(...skipping 721 matching lines...) Expand 10 before | Expand all | Expand 10 after
830 ASSERT_SINGLE_OWNER 832 ASSERT_SINGLE_OWNER
831 fResourceCache->setLimits(maxTextures, maxTextureBytes); 833 fResourceCache->setLimits(maxTextures, maxTextureBytes);
832 } 834 }
833 835
834 ////////////////////////////////////////////////////////////////////////////// 836 //////////////////////////////////////////////////////////////////////////////
835 837
836 void GrContext::dumpMemoryStatistics(SkTraceMemoryDump* traceMemoryDump) const { 838 void GrContext::dumpMemoryStatistics(SkTraceMemoryDump* traceMemoryDump) const {
837 ASSERT_SINGLE_OWNER 839 ASSERT_SINGLE_OWNER
838 fResourceCache->dumpMemoryStatistics(traceMemoryDump); 840 fResourceCache->dumpMemoryStatistics(traceMemoryDump);
839 } 841 }
OLDNEW
« no previous file with comments | « include/gpu/GrContextOptions.h ('k') | src/gpu/GrDrawingManager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698