OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 | 9 |
10 #ifndef SkPDFDevice_DEFINED | 10 #ifndef SkPDFDevice_DEFINED |
(...skipping 239 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
250 // Glyph ids used for each font on this device. | 250 // Glyph ids used for each font on this device. |
251 SkAutoTDelete<SkPDFGlyphSetMap> fFontGlyphUsage; | 251 SkAutoTDelete<SkPDFGlyphSetMap> fFontGlyphUsage; |
252 | 252 |
253 SkPicture::EncodeBitmap fEncoder; | 253 SkPicture::EncodeBitmap fEncoder; |
254 SkScalar fRasterDpi; | 254 SkScalar fRasterDpi; |
255 | 255 |
256 SkPDFDevice(const SkISize& layerSize, const SkClipStack& existingClipStack, | 256 SkPDFDevice(const SkISize& layerSize, const SkClipStack& existingClipStack, |
257 const SkRegion& existingClipRegion); | 257 const SkRegion& existingClipRegion); |
258 | 258 |
259 // override from SkBaseDevice | 259 // override from SkBaseDevice |
260 virtual SkBaseDevice* onCreateCompatibleDevice(SkBitmap::Config config, | 260 virtual SkBaseDevice* onCreateDevice(const SkImageInfo&, Usage) SK_OVERRIDE; |
261 int width, int height, | |
262 bool isOpaque, | |
263 Usage usage) SK_OVERRIDE; | |
264 | 261 |
265 void init(); | 262 void init(); |
266 void cleanUp(bool clearFontUsage); | 263 void cleanUp(bool clearFontUsage); |
267 SkPDFFormXObject* createFormXObjectFromDevice(); | 264 SkPDFFormXObject* createFormXObjectFromDevice(); |
268 | 265 |
269 void drawFormXObjectWithMask(int xObjectIndex, | 266 void drawFormXObjectWithMask(int xObjectIndex, |
270 SkPDFFormXObject* mask, | 267 SkPDFFormXObject* mask, |
271 const SkClipStack* clipStack, | 268 const SkClipStack* clipStack, |
272 const SkRegion& clipRegion, | 269 const SkRegion& clipRegion, |
273 SkXfermode::Mode mode, | 270 SkXfermode::Mode mode, |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 | 330 |
334 typedef SkBitmapDevice INHERITED; | 331 typedef SkBitmapDevice INHERITED; |
335 | 332 |
336 // TODO(edisonn): Only SkDocument_PDF and SkPDFImageShader should be able to
create | 333 // TODO(edisonn): Only SkDocument_PDF and SkPDFImageShader should be able to
create |
337 // an SkPDFDevice | 334 // an SkPDFDevice |
338 //friend class SkDocument_PDF; | 335 //friend class SkDocument_PDF; |
339 //friend class SkPDFImageShader; | 336 //friend class SkPDFImageShader; |
340 }; | 337 }; |
341 | 338 |
342 #endif | 339 #endif |
OLD | NEW |