aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/core/SkPictureRecord.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/SkPictureRecord.cpp')
-rw-r--r--src/core/SkPictureRecord.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/core/SkPictureRecord.cpp b/src/core/SkPictureRecord.cpp
index 3bf9851216..5ce35d6fe8 100644
--- a/src/core/SkPictureRecord.cpp
+++ b/src/core/SkPictureRecord.cpp
@@ -1,10 +1,10 @@
-
/*
* Copyright 2011 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
+
#include "SkPictureRecord.h"
#include "SkTSearch.h"
#include "SkPixelRef.h"
@@ -12,6 +12,7 @@
#include "SkBBoxHierarchy.h"
#include "SkDevice.h"
#include "SkPictureStateTree.h"
+#include "SkSurface.h"
#define HEAP_BLOCK_SIZE 4096
@@ -1316,6 +1317,10 @@ void SkPictureRecord::endCommentGroup() {
///////////////////////////////////////////////////////////////////////////////
+SkSurface* SkPictureRecord::onNewSurface(const SkImageInfo& info) {
+ return SkSurface::NewPicture(info.fWidth, info.fHeight);
+}
+
void SkPictureRecord::addBitmap(const SkBitmap& bitmap) {
const int index = fBitmapHeap->insert(bitmap);
// In debug builds, a bad return value from insert() will crash, allowing for debugging. In