aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/skiaserve/Request.h
diff options
context:
space:
mode:
authorGravatar joshualitt <joshualitt@chromium.org>2016-02-25 10:50:28 -0800
committerGravatar Commit bot <commit-bot@chromium.org>2016-02-25 10:50:28 -0800
commit4dcbe431244c2f1abef8416b95ebf2921708fa63 (patch)
tree2db9f55377c0e0647991e654ec66894fe4419555 /tools/skiaserve/Request.h
parentf6bfccd562f4ac071db9902097ad4bea83294085 (diff)
Move some methods to SkiaServe's Request, this is still very leaky
Diffstat (limited to 'tools/skiaserve/Request.h')
-rw-r--r--tools/skiaserve/Request.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/tools/skiaserve/Request.h b/tools/skiaserve/Request.h
index fd18bdad9c..a3276fa38b 100644
--- a/tools/skiaserve/Request.h
+++ b/tools/skiaserve/Request.h
@@ -32,6 +32,18 @@ struct Request {
, fUrlDataManager(rootUrl)
, fGPUEnabled(false) {}
+ SkSurface* createCPUSurface();
+ SkSurface* createGPUSurface();
+ SkData* drawToPng(int n);
+ void drawToCanvas(int n);
+ SkCanvas* getCanvas();
+ SkData* writeCanvasToPng(SkCanvas* canvas);
+ SkBitmap* getBitmapFromCanvas(SkCanvas* canvas);
+
+ // TODO probably want to make this configurable
+ static const int kImageWidth;
+ static const int kImageHeight;
+
UploadContext* fUploadContext;
SkAutoTUnref<SkPicture> fPicture;
SkAutoTUnref<SkDebugCanvas> fDebugCanvas;