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

Unified Diff: src/gpu/GrGpu.cpp

Issue 1124733004: Move DrawInfo out from GrDrawTarget and rename to GrVertices. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: comment changes Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrTessellatingPathRenderer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrGpu.cpp
diff --git a/src/gpu/GrGpu.cpp b/src/gpu/GrGpu.cpp
index cdf5226ed1f4c8418f7748efbe022e3c1dcb4090..d98b3ced2513ceabdca35b6995a7b2a45c365baf 100644
--- a/src/gpu/GrGpu.cpp
+++ b/src/gpu/GrGpu.cpp
@@ -18,6 +18,24 @@
#include "GrRenderTargetPriv.h"
#include "GrStencilAttachment.h"
#include "GrVertexBuffer.h"
+#include "GrVertices.h"
+
+GrVertices& GrVertices::operator =(const GrVertices& di) {
+ fPrimitiveType = di.fPrimitiveType;
+ fStartVertex = di.fStartVertex;
+ fStartIndex = di.fStartIndex;
+ fVertexCount = di.fVertexCount;
+ fIndexCount = di.fIndexCount;
+
+ fInstanceCount = di.fInstanceCount;
+ fVerticesPerInstance = di.fVerticesPerInstance;
+ fIndicesPerInstance = di.fIndicesPerInstance;
+
+ fVertexBuffer.reset(di.vertexBuffer());
+ fIndexBuffer.reset(di.indexBuffer());
+
+ return *this;
+}
////////////////////////////////////////////////////////////////////////////////
@@ -269,9 +287,9 @@ void GrGpu::removeGpuTraceMarker(const GrGpuTraceMarker* marker) {
////////////////////////////////////////////////////////////////////////////////
-void GrGpu::draw(const DrawArgs& args, const GrDrawTarget::DrawInfo& info) {
+void GrGpu::draw(const DrawArgs& args, const GrVertices& vertices) {
this->handleDirtyContext();
- this->onDraw(args, info);
+ this->onDraw(args, vertices);
}
void GrGpu::stencilPath(const GrPath* path, const StencilPathState& state) {
« no previous file with comments | « src/gpu/GrGpu.h ('k') | src/gpu/GrTessellatingPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698