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

Unified Diff: src/gpu/GrGpu.cpp

Issue 1490473003: Add transfer buffer support. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Some clean up 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 side-by-side diff with in-line comments
Download patch
Index: src/gpu/GrGpu.cpp
diff --git a/src/gpu/GrGpu.cpp b/src/gpu/GrGpu.cpp
index 439fe1b70fa9779c9d3e5b0325aebe85d8f7156a..97938ab686d7575252e29964bfb740288b70db34 100644
--- a/src/gpu/GrGpu.cpp
+++ b/src/gpu/GrGpu.cpp
@@ -20,6 +20,7 @@
#include "GrRenderTargetPriv.h"
#include "GrStencilAttachment.h"
#include "GrSurfacePriv.h"
+#include "GrTransferBuffer.h"
#include "GrVertexBuffer.h"
#include "GrVertices.h"
@@ -197,6 +198,12 @@ GrIndexBuffer* GrGpu::createIndexBuffer(size_t size, bool dynamic) {
return ib;
}
+GrTransferBuffer* GrGpu::createTransferBuffer(size_t size, bool toGpu) {
+ this->handleDirtyContext();
+ GrTransferBuffer* tb = this->onCreateTransferBuffer(size, toGpu);
+ return tb;
+}
+
void GrGpu::clear(const SkIRect& rect,
GrColor color,
GrRenderTarget* renderTarget) {

Powered by Google App Engine
This is Rietveld 408576698