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

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

Issue 1416753002: Add debugging helper to GrDrawTarget (Closed) Base URL: https://skia.googlesource.com/skia.git@mdb-adddeps
Patch Set: Renamed GrDrawTarget::print to dump Created 5 years, 2 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 | « no previous file | src/gpu/GrDrawTarget.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 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include "GrContext.h" 9 #include "GrContext.h"
10 10
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
93 fDrawTargets[i]->reset(); 93 fDrawTargets[i]->reset();
94 } 94 }
95 } 95 }
96 96
97 void GrDrawingManager::flush() { 97 void GrDrawingManager::flush() {
98 SkDEBUGCODE(bool result =) 98 SkDEBUGCODE(bool result =)
99 SkTTopoSort<GrDrawTarget, GrDrawTarget::TopoSortTraits>( &fDrawTargets); 99 SkTTopoSort<GrDrawTarget, GrDrawTarget::TopoSortTraits>( &fDrawTargets);
100 SkASSERT(result); 100 SkASSERT(result);
101 101
102 for (int i = 0; i < fDrawTargets.count(); ++i) { 102 for (int i = 0; i < fDrawTargets.count(); ++i) {
103 //SkDEBUGCODE(fDrawTargets[i]->dump();)
103 fDrawTargets[i]->flush(); 104 fDrawTargets[i]->flush();
104 } 105 }
105 106
106 #ifndef ENABLE_MDB 107 #ifndef ENABLE_MDB
107 // When MDB is disabled we keep reusing the same drawTarget 108 // When MDB is disabled we keep reusing the same drawTarget
108 if (fDrawTargets.count()) { 109 if (fDrawTargets.count()) {
109 SkASSERT(fDrawTargets.count() == 1); 110 SkASSERT(fDrawTargets.count() == 1);
110 fDrawTargets[0]->resetFlag(GrDrawTarget::kWasOutput_Flag); 111 fDrawTargets[0]->resetFlag(GrDrawTarget::kWasOutput_Flag);
111 } 112 }
112 #endif 113 #endif
(...skipping 695 matching lines...) Expand 10 before | Expand all | Expand 10 after
808 809
809 void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) { 810 void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) {
810 fResourceCache->setLimits(maxTextures, maxTextureBytes); 811 fResourceCache->setLimits(maxTextures, maxTextureBytes);
811 } 812 }
812 813
813 ////////////////////////////////////////////////////////////////////////////// 814 //////////////////////////////////////////////////////////////////////////////
814 815
815 void GrContext::dumpMemoryStatistics(SkTraceMemoryDump* traceMemoryDump) const { 816 void GrContext::dumpMemoryStatistics(SkTraceMemoryDump* traceMemoryDump) const {
816 fResourceCache->dumpMemoryStatistics(traceMemoryDump); 817 fResourceCache->dumpMemoryStatistics(traceMemoryDump);
817 } 818 }
OLDNEW
« no previous file with comments | « no previous file | src/gpu/GrDrawTarget.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698