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

Side by Side Diff: src/gpu/GrGpu.h

Issue 1083133002: Rename GrStencilBuffer to GrStencilAttachment (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: line formatting Created 5 years, 8 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 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 GrGpu_DEFINED 8 #ifndef GrGpu_DEFINED
9 #define GrGpu_DEFINED 9 #define GrGpu_DEFINED
10 10
11 #include "GrDrawTarget.h" 11 #include "GrDrawTarget.h"
12 #include "GrPathRendering.h" 12 #include "GrPathRendering.h"
13 #include "GrProgramDesc.h" 13 #include "GrProgramDesc.h"
14 #include "SkPath.h" 14 #include "SkPath.h"
15 15
16 class GrContext; 16 class GrContext;
17 class GrIndexBufferAllocPool; 17 class GrIndexBufferAllocPool;
18 class GrPath; 18 class GrPath;
19 class GrPathRange; 19 class GrPathRange;
20 class GrPathRenderer; 20 class GrPathRenderer;
21 class GrPathRendererChain; 21 class GrPathRendererChain;
22 class GrPipeline; 22 class GrPipeline;
23 class GrPrimitiveProcessor; 23 class GrPrimitiveProcessor;
24 class GrStencilBuffer; 24 class GrStencilAttachment;
25 class GrVertexBufferAllocPool; 25 class GrVertexBufferAllocPool;
26 26
27 class GrGpu : public SkRefCnt { 27 class GrGpu : public SkRefCnt {
28 public: 28 public:
29 /** 29 /**
30 * Create an instance of GrGpu that matches the specified backend. If the re quested backend is 30 * Create an instance of GrGpu that matches the specified backend. If the re quested backend is
31 * not supported (at compile-time or run-time) this returns NULL. The contex t will not be 31 * not supported (at compile-time or run-time) this returns NULL. The contex t will not be
32 * fully constructed and should not be used by GrGpu until after this functi on returns. 32 * fully constructed and should not be used by GrGpu until after this functi on returns.
33 */ 33 */
34 static GrGpu* Create(GrBackend, GrBackendContext, GrContext* context); 34 static GrGpu* Create(GrBackend, GrBackendContext, GrContext* context);
(...skipping 449 matching lines...) Expand 10 before | Expand all | Expand 10 after
484 484
485 // overridden by backend-specific derived class to perform the resolve 485 // overridden by backend-specific derived class to perform the resolve
486 virtual void onResolveRenderTarget(GrRenderTarget* target) = 0; 486 virtual void onResolveRenderTarget(GrRenderTarget* target) = 0;
487 487
488 // width and height may be larger than rt (if underlying API allows it). 488 // width and height may be larger than rt (if underlying API allows it).
489 // Should attach the SB to the RT. Returns false if compatible sb could 489 // Should attach the SB to the RT. Returns false if compatible sb could
490 // not be created. 490 // not be created.
491 virtual bool createStencilBufferForRenderTarget(GrRenderTarget*, int width, int height) = 0; 491 virtual bool createStencilBufferForRenderTarget(GrRenderTarget*, int width, int height) = 0;
492 492
493 // attaches an existing SB to an existing RT. 493 // attaches an existing SB to an existing RT.
494 virtual bool attachStencilBufferToRenderTarget(GrStencilBuffer*, GrRenderTar get*) = 0; 494 virtual bool attachStencilBufferToRenderTarget(GrStencilAttachment*, GrRende rTarget*) = 0;
495 495
496 // clears target's entire stencil buffer to 0 496 // clears target's entire stencil buffer to 0
497 virtual void clearStencil(GrRenderTarget* target) = 0; 497 virtual void clearStencil(GrRenderTarget* target) = 0;
498 498
499 virtual void didAddGpuTraceMarker() = 0; 499 virtual void didAddGpuTraceMarker() = 0;
500 virtual void didRemoveGpuTraceMarker() = 0; 500 virtual void didRemoveGpuTraceMarker() = 0;
501 501
502 void resetContext() { 502 void resetContext() {
503 this->onResetContext(fResetBits); 503 this->onResetContext(fResetBits);
504 fResetBits = 0; 504 fResetBits = 0;
(...skipping 14 matching lines...) Expand all
519 int fGpuTrac eMarkerCount; 519 int fGpuTrac eMarkerCount;
520 GrTraceMarkerSet fActiveT raceMarkers; 520 GrTraceMarkerSet fActiveT raceMarkers;
521 GrTraceMarkerSet fStoredT raceMarkers; 521 GrTraceMarkerSet fStoredT raceMarkers;
522 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu. 522 // The context owns us, not vice-versa, so this ptr is not ref'ed by Gpu.
523 GrContext* fContext ; 523 GrContext* fContext ;
524 524
525 typedef SkRefCnt INHERITED; 525 typedef SkRefCnt INHERITED;
526 }; 526 };
527 527
528 #endif 528 #endif
OLDNEW
« include/gpu/GrRenderTarget.h ('K') | « src/gpu/GrDrawTarget.cpp ('k') | src/gpu/GrGpu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698