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

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

Issue 1954103002: Revert of Retract GrRenderTarget a bit within SkGpuDevice (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 7 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/SkGpuDevice.cpp » ('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 2015 Google Inc. 2 * Copyright 2015 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 GrDrawContext_DEFINED 8 #ifndef GrDrawContext_DEFINED
9 #define GrDrawContext_DEFINED 9 #define GrDrawContext_DEFINED
10 10
(...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after
266 void drawBatch(const GrClip&, const GrPaint&, GrDrawBatch*); 266 void drawBatch(const GrClip&, const GrPaint&, GrDrawBatch*);
267 267
268 /** 268 /**
269 * Draws a path batch. This needs to be separate from drawBatch because we i nstall path stencil 269 * Draws a path batch. This needs to be separate from drawBatch because we i nstall path stencil
270 * settings late. 270 * settings late.
271 * 271 *
272 * TODO: Figure out a better model that allows us to roll this method into d rawBatch. 272 * TODO: Figure out a better model that allows us to roll this method into d rawBatch.
273 */ 273 */
274 void drawPathBatch(const GrPipelineBuilder&, GrDrawPathBatchBase*); 274 void drawPathBatch(const GrPipelineBuilder&, GrDrawPathBatchBase*);
275 275
276 const GrSurfaceDesc& desc() const { return fRenderTarget->desc(); }
277 int width() const { return fRenderTarget->width(); } 276 int width() const { return fRenderTarget->width(); }
278 int height() const { return fRenderTarget->height(); } 277 int height() const { return fRenderTarget->height(); }
279 int numColorSamples() const { return fRenderTarget->numColorSamples(); } 278 int numColorSamples() const { return fRenderTarget->numColorSamples(); }
280 bool isGammaCorrect() const { return fSurfaceProps.isGammaCorrect(); } 279 bool isGammaCorrect() const { return fSurfaceProps.isGammaCorrect(); }
281 280
282 GrRenderTarget* accessRenderTarget() { return fRenderTarget.get(); } 281 GrRenderTarget* accessRenderTarget() { return fRenderTarget.get(); }
283 282
284 sk_sp<GrRenderTarget> renderTarget() { return fRenderTarget; } 283 sk_sp<GrRenderTarget> renderTarget() { return fRenderTarget; }
285 284
286 sk_sp<GrTexture> asTexture() { return sk_ref_sp(fRenderTarget->asTexture()); } 285 sk_sp<GrTexture> asTexture() { return sk_ref_sp(fRenderTarget->asTexture()); }
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 GrContext* fContext; 336 GrContext* fContext;
338 337
339 SkSurfaceProps fSurfaceProps; 338 SkSurfaceProps fSurfaceProps;
340 GrAuditTrail* fAuditTrail; 339 GrAuditTrail* fAuditTrail;
341 340
342 // In debug builds we guard against improper thread handling 341 // In debug builds we guard against improper thread handling
343 SkDEBUGCODE(mutable GrSingleOwner* fSingleOwner;) 342 SkDEBUGCODE(mutable GrSingleOwner* fSingleOwner;)
344 }; 343 };
345 344
346 #endif 345 #endif
OLDNEW
« no previous file with comments | « no previous file | src/gpu/SkGpuDevice.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698