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

Unified Diff: src/core/SkPicture.cpp

Issue 176863004: Add new skpinfo tool (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Next round of review changes Created 6 years, 10 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 | « include/core/SkPicture.h ('k') | src/core/SkPicturePlayback.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkPicture.cpp
===================================================================
--- src/core/SkPicture.cpp (revision 13640)
+++ src/core/SkPicture.cpp (working copy)
@@ -256,7 +256,7 @@
static const char kMagic[] = { 's', 'k', 'i', 'a', 'p', 'i', 'c', 't' };
static const size_t kHeaderSize = sizeof(kMagic) + sizeof(SkPictInfo);
-bool SkPicture::StreamIsSKP(SkStream* stream, SkPictInfo* pInfo) {
+bool SkPicture::InternalOnly_StreamIsSKP(SkStream* stream, SkPictInfo* pInfo) {
if (NULL == stream) {
return false;
}
@@ -283,7 +283,7 @@
return true;
}
-bool SkPicture::BufferIsSKP(SkReadBuffer& buffer, SkPictInfo* pInfo) {
+bool SkPicture::InternalOnly_BufferIsSKP(SkReadBuffer& buffer, SkPictInfo* pInfo) {
// Check magic bytes.
char magic[sizeof(kMagic)];
@@ -316,7 +316,7 @@
SkPicture* SkPicture::CreateFromStream(SkStream* stream, InstallPixelRefProc proc) {
SkPictInfo info;
- if (!StreamIsSKP(stream, &info)) {
+ if (!InternalOnly_StreamIsSKP(stream, &info)) {
return NULL;
}
@@ -337,7 +337,7 @@
SkPicture* SkPicture::CreateFromBuffer(SkReadBuffer& buffer) {
SkPictInfo info;
- if (!BufferIsSKP(buffer, &info)) {
+ if (!InternalOnly_BufferIsSKP(buffer, &info)) {
return NULL;
}
@@ -360,7 +360,7 @@
SkASSERT(sizeof(kMagic) == 8);
memcpy(header, kMagic, sizeof(kMagic));
- // Set piture info after magic bytes in the header
+ // Set picture info after magic bytes in the header
SkPictInfo* info = (SkPictInfo*)(((char*)header) + sizeof(kMagic));
info->fVersion = CURRENT_PICTURE_VERSION;
info->fWidth = fWidth;
@@ -382,7 +382,7 @@
}
char header[kHeaderSize];
- createHeader(&header);
+ this->createHeader(&header);
stream->write(header, kHeaderSize);
if (playback) {
stream->writeBool(true);
@@ -404,7 +404,7 @@
}
char header[kHeaderSize];
- createHeader(&header);
+ this->createHeader(&header);
buffer.writeByteArray(header, kHeaderSize);
if (playback) {
buffer.writeBool(true);
« no previous file with comments | « include/core/SkPicture.h ('k') | src/core/SkPicturePlayback.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698