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

Unified Diff: src/gpu/batches/GrAAHairLinePathRenderer.cpp

Issue 1831133004: Revert of Consolidate GPU buffer implementations (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 9 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/batches/GrAAFillRectBatch.cpp ('k') | src/gpu/batches/GrAALinearizingConvexPathRenderer.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/batches/GrAAHairLinePathRenderer.cpp
diff --git a/src/gpu/batches/GrAAHairLinePathRenderer.cpp b/src/gpu/batches/GrAAHairLinePathRenderer.cpp
index 2cc91f9740ec263a00142de292ae2c68ba5c184c..7d45ed71f9fc255d490a5c8c36bfe3192ef8f535 100644
--- a/src/gpu/batches/GrAAHairLinePathRenderer.cpp
+++ b/src/gpu/batches/GrAAHairLinePathRenderer.cpp
@@ -9,14 +9,15 @@
#include "GrBatchFlushState.h"
#include "GrBatchTest.h"
-#include "GrBuffer.h"
#include "GrCaps.h"
#include "GrContext.h"
#include "GrDefaultGeoProcFactory.h"
+#include "GrIndexBuffer.h"
#include "GrPathUtils.h"
#include "GrPipelineBuilder.h"
#include "GrProcessor.h"
#include "GrResourceProvider.h"
+#include "GrVertexBuffer.h"
#include "SkGeometry.h"
#include "SkStroke.h"
#include "SkTemplates.h"
@@ -64,7 +65,7 @@
static const int kQuadsNumInIdxBuffer = 256;
GR_DECLARE_STATIC_UNIQUE_KEY(gQuadsIndexBufferKey);
-static const GrBuffer* ref_quads_index_buffer(GrResourceProvider* resourceProvider) {
+static const GrIndexBuffer* ref_quads_index_buffer(GrResourceProvider* resourceProvider) {
GR_DEFINE_STATIC_UNIQUE_KEY(gQuadsIndexBufferKey);
return resourceProvider->findOrCreateInstancedIndexBuffer(
kQuadIdxBufPattern, kIdxsPerQuad, kQuadsNumInIdxBuffer, kQuadNumVertices,
@@ -98,7 +99,7 @@
GR_DECLARE_STATIC_UNIQUE_KEY(gLinesIndexBufferKey);
-static const GrBuffer* ref_lines_index_buffer(GrResourceProvider* resourceProvider) {
+static const GrIndexBuffer* ref_lines_index_buffer(GrResourceProvider* resourceProvider) {
GR_DEFINE_STATIC_UNIQUE_KEY(gLinesIndexBufferKey);
return resourceProvider->findOrCreateInstancedIndexBuffer(
kLineSegIdxBufPattern, kIdxsPerLineSeg, kLineSegsNumInIdxBuffer, kLineSegNumVertices,
@@ -857,11 +858,11 @@
// do lines first
if (lineCount) {
- SkAutoTUnref<const GrBuffer> linesIndexBuffer(
+ SkAutoTUnref<const GrIndexBuffer> linesIndexBuffer(
ref_lines_index_buffer(target->resourceProvider()));
target->initDraw(lineGP);
- const GrBuffer* vertexBuffer;
+ const GrVertexBuffer* vertexBuffer;
int firstVertex;
size_t vertexStride = lineGP->getVertexStride();
@@ -890,10 +891,10 @@
}
if (quadCount || conicCount) {
- const GrBuffer* vertexBuffer;
+ const GrVertexBuffer* vertexBuffer;
int firstVertex;
- SkAutoTUnref<const GrBuffer> quadsIndexBuffer(
+ SkAutoTUnref<const GrIndexBuffer> quadsIndexBuffer(
ref_quads_index_buffer(target->resourceProvider()));
size_t vertexStride = sizeof(BezierVertex);
« no previous file with comments | « src/gpu/batches/GrAAFillRectBatch.cpp ('k') | src/gpu/batches/GrAALinearizingConvexPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698