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

Side by Side Diff: include/gpu/GrRenderTarget.h

Issue 1414903002: Dependencies are now added between the drawTargets in GrPipeline (Closed) Base URL: https://skia.googlesource.com/skia.git@mdb-adddeps
Patch Set: Fix leak on abandon issue 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 | « 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 * 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 #ifndef GrRenderTarget_DEFINED 8 #ifndef GrRenderTarget_DEFINED
9 #define GrRenderTarget_DEFINED 9 #define GrRenderTarget_DEFINED
10 10
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 protected: 158 protected:
159 GrRenderTarget(GrGpu* gpu, LifeCycle lifeCycle, const GrSurfaceDesc& desc, 159 GrRenderTarget(GrGpu* gpu, LifeCycle lifeCycle, const GrSurfaceDesc& desc,
160 SampleConfig sampleConfig, GrStencilAttachment* stencil = nul lptr) 160 SampleConfig sampleConfig, GrStencilAttachment* stencil = nul lptr)
161 : INHERITED(gpu, lifeCycle, desc) 161 : INHERITED(gpu, lifeCycle, desc)
162 , fStencilAttachment(stencil) 162 , fStencilAttachment(stencil)
163 , fSampleConfig(sampleConfig) 163 , fSampleConfig(sampleConfig)
164 , fLastDrawTarget(nullptr) { 164 , fLastDrawTarget(nullptr) {
165 fResolveRect.setLargestInverted(); 165 fResolveRect.setLargestInverted();
166 } 166 }
167 167
168 ~GrRenderTarget() override;
169
168 // override of GrResource 170 // override of GrResource
169 void onAbandon() override; 171 void onAbandon() override;
170 void onRelease() override; 172 void onRelease() override;
171 173
172 private: 174 private:
173 // Allows the backends to perform any additional work that is required for a ttaching a 175 // Allows the backends to perform any additional work that is required for a ttaching a
174 // GrStencilAttachment. When this is called, the GrStencilAttachment has alr eady been put onto 176 // GrStencilAttachment. When this is called, the GrStencilAttachment has alr eady been put onto
175 // the GrRenderTarget. This function must return false if any failures occur when completing the 177 // the GrRenderTarget. This function must return false if any failures occur when completing the
176 // stencil attachment. 178 // stencil attachment.
177 virtual bool completeStencilAttachment() = 0; 179 virtual bool completeStencilAttachment() = 0;
(...skipping 11 matching lines...) Expand all
189 // This back-pointer is required so that we can add a dependancy between 191 // This back-pointer is required so that we can add a dependancy between
190 // the drawTarget used to create the current contents of this renderTarget 192 // the drawTarget used to create the current contents of this renderTarget
191 // and the drawTarget of a destination renderTarget to which this one is bei ng drawn. 193 // and the drawTarget of a destination renderTarget to which this one is bei ng drawn.
192 GrDrawTarget* fLastDrawTarget; 194 GrDrawTarget* fLastDrawTarget;
193 195
194 typedef GrSurface INHERITED; 196 typedef GrSurface INHERITED;
195 }; 197 };
196 198
197 199
198 #endif 200 #endif
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