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

Unified Diff: src/core/SkMallocPixelRef.cpp

Issue 134163010: Refactor read and write buffers. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: whoops, read buffers have .size() Created 6 years, 11 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/core/SkImageInfo.cpp ('k') | src/core/SkOrderedReadBuffer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkMallocPixelRef.cpp
diff --git a/src/core/SkMallocPixelRef.cpp b/src/core/SkMallocPixelRef.cpp
index 9adcd34ba606d8df49d089e529c9d97d32dadeaa..aa7c4f745cd5e809cb62f8c8f26c455a1197a77f 100644
--- a/src/core/SkMallocPixelRef.cpp
+++ b/src/core/SkMallocPixelRef.cpp
@@ -7,7 +7,8 @@
#include "SkMallocPixelRef.h"
#include "SkBitmap.h"
-#include "SkFlattenableBuffers.h"
+#include "SkReadBuffer.h"
+#include "SkWriteBuffer.h"
// assumes ptr was allocated via sk_malloc
static void sk_free_releaseproc(void* ptr, void*) {
@@ -201,7 +202,7 @@ size_t SkMallocPixelRef::getAllocatedSizeInBytes() const {
return this->info().getSafeSize(fRB);
}
-void SkMallocPixelRef::flatten(SkFlattenableWriteBuffer& buffer) const {
+void SkMallocPixelRef::flatten(SkWriteBuffer& buffer) const {
this->INHERITED::flatten(buffer);
buffer.write32(SkToU32(fRB));
@@ -216,7 +217,7 @@ void SkMallocPixelRef::flatten(SkFlattenableWriteBuffer& buffer) const {
}
}
-SkMallocPixelRef::SkMallocPixelRef(SkFlattenableReadBuffer& buffer)
+SkMallocPixelRef::SkMallocPixelRef(SkReadBuffer& buffer)
: INHERITED(buffer, NULL)
, fReleaseProc(sk_free_releaseproc)
, fReleaseProcContext(NULL)
« no previous file with comments | « src/core/SkImageInfo.cpp ('k') | src/core/SkOrderedReadBuffer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698