Chromium Code Reviews| Index: include/core/SkDocument.h |
| diff --git a/include/core/SkDocument.h b/include/core/SkDocument.h |
| index b941d1bd19ce775be0c83c474dcb42ba5e0f4dc9..a4bbad8d467b6f0028f55858cc8bd7b37e1a566a 100644 |
| --- a/include/core/SkDocument.h |
| +++ b/include/core/SkDocument.h |
| @@ -16,6 +16,10 @@ |
| class SkCanvas; |
| class SkWStream; |
| +/** SK_ScalarDefaultDPI is 72 DPI. |
| +*/ |
| +#define SK_ScalarDefaultDPI SkFloatToScalar(72.0f) |
| + |
| /** |
| * High-level API for creating a document-based canvas. To use.. |
| * |
| @@ -37,7 +41,8 @@ public: |
| * as JPEG (DCT). |
|
reed1
2013/10/21 13:10:24
What does DPI mean to the client when they draw in
edisonn
2013/10/21 14:40:58
No
Does it affect internal
|
| */ |
| static SkDocument* CreatePDF(const char filename[], |
| - SkPicture::EncodeBitmap encoder = NULL); |
| + SkPicture::EncodeBitmap encoder = NULL, |
| + SkScalar dpi = SK_ScalarDefaultDPI); |
| /** |
| * Create a PDF-backed document, writing the results into a stream. |
| @@ -52,7 +57,8 @@ public: |
| * as JPEG (DCT). |
| */ |
| static SkDocument* CreatePDF(SkWStream*, void (*Done)(SkWStream*) = NULL, |
| - SkPicture::EncodeBitmap encoder = NULL); |
| + SkPicture::EncodeBitmap encoder = NULL, |
| + SkScalar dpi = SK_ScalarDefaultDPI); |
| /** |
| * Begin a new page for the document, returning the canvas that will draw |