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

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

Issue 1450513002: Revert of Update testing frameworks/tests for MDB (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 1 month 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/GrDrawContext.cpp ('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 /* 2 /*
3 * Copyright 2010 Google Inc. 3 * Copyright 2010 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 "GrDrawTarget.h" 9 #include "GrDrawTarget.h"
10 10
(...skipping 24 matching lines...) Expand all
35 GrDrawTarget::GrDrawTarget(GrRenderTarget* rt, GrGpu* gpu, GrResourceProvider* r esourceProvider) 35 GrDrawTarget::GrDrawTarget(GrRenderTarget* rt, GrGpu* gpu, GrResourceProvider* r esourceProvider)
36 : fGpu(SkRef(gpu)) 36 : fGpu(SkRef(gpu))
37 , fResourceProvider(resourceProvider) 37 , fResourceProvider(resourceProvider)
38 , fFlushing(false) 38 , fFlushing(false)
39 , fFlags(0) 39 , fFlags(0)
40 , fRenderTarget(rt) { 40 , fRenderTarget(rt) {
41 // TODO: Stop extracting the context (currently needed by GrClipMaskManager) 41 // TODO: Stop extracting the context (currently needed by GrClipMaskManager)
42 fContext = fGpu->getContext(); 42 fContext = fGpu->getContext();
43 fClipMaskManager.reset(new GrClipMaskManager(this)); 43 fClipMaskManager.reset(new GrClipMaskManager(this));
44 44
45 rt->setLastDrawTarget(this);
46
47 #ifdef SK_DEBUG 45 #ifdef SK_DEBUG
48 static int debugID = 0; 46 static int debugID = 0;
49 fDebugID = debugID++; 47 fDebugID = debugID++;
50 #endif 48 #endif
51 } 49 }
52 50
53 GrDrawTarget::~GrDrawTarget() { 51 GrDrawTarget::~GrDrawTarget() {
54 if (fRenderTarget && this == fRenderTarget->getLastDrawTarget()) { 52 if (fRenderTarget && this == fRenderTarget->getLastDrawTarget()) {
55 fRenderTarget->setLastDrawTarget(nullptr); 53 fRenderTarget->setLastDrawTarget(nullptr);
56 } 54 }
(...skipping 490 matching lines...) Expand 10 before | Expand all | Expand 10 after
547 } 545 }
548 546
549 return true; 547 return true;
550 } 548 }
551 549
552 void GrDrawTarget::clearStencilClip(const SkIRect& rect, bool insideClip, GrRend erTarget* rt) { 550 void GrDrawTarget::clearStencilClip(const SkIRect& rect, bool insideClip, GrRend erTarget* rt) {
553 GrBatch* batch = new GrClearStencilClipBatch(rect, insideClip, rt); 551 GrBatch* batch = new GrClearStencilClipBatch(rect, insideClip, rt);
554 this->recordBatch(batch); 552 this->recordBatch(batch);
555 batch->unref(); 553 batch->unref();
556 } 554 }
OLDNEW
« no previous file with comments | « src/gpu/GrDrawContext.cpp ('k') | src/gpu/GrDrawingManager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698