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

Side by Side Diff: src/gpu/batches/GrDrawBatch.h

Issue 1494473005: Add option to draw wireframe batch bounds (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: init vbo id to 0 Created 5 years 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/batches/GrDiscardBatch.h ('k') | src/gpu/batches/GrStencilPathBatch.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 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 GrDrawBatch_DEFINED 8 #ifndef GrDrawBatch_DEFINED
9 #define GrDrawBatch_DEFINED 9 #define GrDrawBatch_DEFINED
10 10
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 bool installPipeline(const GrPipeline::CreateArgs&); 56 bool installPipeline(const GrPipeline::CreateArgs&);
57 57
58 // TODO no GrPrimitiveProcessors yet read fragment position 58 // TODO no GrPrimitiveProcessors yet read fragment position
59 bool willReadFragmentPosition() const { return false; } 59 bool willReadFragmentPosition() const { return false; }
60 60
61 uint32_t renderTargetUniqueID() const final { 61 uint32_t renderTargetUniqueID() const final {
62 SkASSERT(fPipelineInstalled); 62 SkASSERT(fPipelineInstalled);
63 return this->pipeline()->getRenderTarget()->getUniqueID(); 63 return this->pipeline()->getRenderTarget()->getUniqueID();
64 } 64 }
65 65
66 GrRenderTarget* renderTarget() const final {
67 SkASSERT(fPipelineInstalled);
68 return this->pipeline()->getRenderTarget();
69 }
70
66 SkString dumpInfo() const override { 71 SkString dumpInfo() const override {
67 SkString string; 72 SkString string;
68 string.appendf("RT: %d\n", this->renderTargetUniqueID()); 73 string.appendf("RT: %d\n", this->renderTargetUniqueID());
69 string.append("ColorStages:\n"); 74 string.append("ColorStages:\n");
70 for (int i = 0; i < this->pipeline()->numColorFragmentProcessors(); i++) { 75 for (int i = 0; i < this->pipeline()->numColorFragmentProcessors(); i++) {
71 string.appendf("\t\t%s\n\t\t%s\n", 76 string.appendf("\t\t%s\n\t\t%s\n",
72 this->pipeline()->getColorFragmentProcessor(i).name() , 77 this->pipeline()->getColorFragmentProcessor(i).name() ,
73 this->pipeline()->getColorFragmentProcessor(i).dumpIn fo().c_str()); 78 this->pipeline()->getColorFragmentProcessor(i).dumpIn fo().c_str());
74 } 79 }
75 string.append("CoverageStages:\n"); 80 string.append("CoverageStages:\n");
(...skipping 21 matching lines...) Expand all
97 protected: 102 protected:
98 SkTArray<SkAutoTUnref<GrBatchUploader>, true> fInlineUploads; 103 SkTArray<SkAutoTUnref<GrBatchUploader>, true> fInlineUploads;
99 104
100 private: 105 private:
101 SkAlignedSTStorage<1, GrPipeline> fPipelineStorage; 106 SkAlignedSTStorage<1, GrPipeline> fPipelineStorage;
102 bool fPipelineInstalled; 107 bool fPipelineInstalled;
103 typedef GrBatch INHERITED; 108 typedef GrBatch INHERITED;
104 }; 109 };
105 110
106 #endif 111 #endif
OLDNEW
« no previous file with comments | « src/gpu/batches/GrDiscardBatch.h ('k') | src/gpu/batches/GrStencilPathBatch.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698