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: tools/gpu/GrTest.cpp

Issue 2035823002: Make GrClipMaskManager stateless and push GrPipelineBuilder construction downstack (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Address code review comments Created 4 years, 6 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
OLDNEW
1 /* 1 /*
2 * Copyright 2013 Google Inc. 2 * Copyright 2013 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 "GrTest.h" 8 #include "GrTest.h"
9 9
10 #include "GrBatchAtlas.h" 10 #include "GrBatchAtlas.h"
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
235 235
236 void GrDrawContextPriv::testingOnly_drawBatch(const GrPipelineBuilder& pipelineB uilder, 236 void GrDrawContextPriv::testingOnly_drawBatch(const GrPipelineBuilder& pipelineB uilder,
237 GrDrawBatch* batch, 237 GrDrawBatch* batch,
238 const GrClip* clip) { 238 const GrClip* clip) {
239 ASSERT_SINGLE_OWNER 239 ASSERT_SINGLE_OWNER
240 RETURN_IF_ABANDONED 240 RETURN_IF_ABANDONED
241 SkDEBUGCODE(fDrawContext->validate();) 241 SkDEBUGCODE(fDrawContext->validate();)
242 GR_AUDIT_TRAIL_AUTO_FRAME(fDrawContext->fAuditTrail, "GrDrawContext::testing Only_drawBatch"); 242 GR_AUDIT_TRAIL_AUTO_FRAME(fDrawContext->fAuditTrail, "GrDrawContext::testing Only_drawBatch");
243 243
244 if (clip) { 244 if (clip) {
245 fDrawContext->getDrawTarget()->drawBatch(pipelineBuilder, *clip, batch); 245 fDrawContext->getDrawTarget()->drawBatch(pipelineBuilder, fDrawContext, *clip, batch);
246 } else { 246 } else {
247 fDrawContext->getDrawTarget()->drawBatch(pipelineBuilder, GrNoClip(), ba tch); 247 fDrawContext->getDrawTarget()->drawBatch(pipelineBuilder, fDrawContext, GrNoClip(), batch);
248 } 248 }
249 } 249 }
250 250
251 #undef ASSERT_SINGLE_OWNER 251 #undef ASSERT_SINGLE_OWNER
252 #undef RETURN_IF_ABANDONED 252 #undef RETURN_IF_ABANDONED
253 253
254 /////////////////////////////////////////////////////////////////////////////// 254 ///////////////////////////////////////////////////////////////////////////////
255 // Code for the mock context. It's built on a mock GrGpu class that does nothing . 255 // Code for the mock context. It's built on a mock GrGpu class that does nothing .
256 //// 256 ////
257 257
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 SkASSERT(nullptr == fGpu); 397 SkASSERT(nullptr == fGpu);
398 fGpu = new MockGpu(this, options); 398 fGpu = new MockGpu(this, options);
399 SkASSERT(fGpu); 399 SkASSERT(fGpu);
400 this->initCommon(options); 400 this->initCommon(options);
401 401
402 // We delete these because we want to test the cache starting with zero reso urces. Also, none of 402 // We delete these because we want to test the cache starting with zero reso urces. Also, none of
403 // these objects are required for any of tests that use this context. TODO: make stop allocating 403 // these objects are required for any of tests that use this context. TODO: make stop allocating
404 // resources in the buffer pools. 404 // resources in the buffer pools.
405 fDrawingManager->abandon(); 405 fDrawingManager->abandon();
406 } 406 }
OLDNEW
« src/gpu/batches/GrStencilAndCoverPathRenderer.cpp ('K') | « tests/TessellatingPathRendererTests.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698