Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ | 5 #ifndef SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ |
| 6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ | 6 #define SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 72 const SkPath& path, const SkMatrix* matrix, | 72 const SkPath& path, const SkMatrix* matrix, |
| 73 const SkPaint& paint); | 73 const SkPaint& paint); |
| 74 virtual void drawVertices(const SkDraw& draw, SkCanvas::VertexMode, | 74 virtual void drawVertices(const SkDraw& draw, SkCanvas::VertexMode, |
| 75 int vertexCount, const SkPoint verts[], | 75 int vertexCount, const SkPoint verts[], |
| 76 const SkPoint texs[], const SkColor colors[], | 76 const SkPoint texs[], const SkColor colors[], |
| 77 SkXfermode* xmode, const uint16_t indices[], | 77 SkXfermode* xmode, const uint16_t indices[], |
| 78 int indexCount, const SkPaint& paint); | 78 int indexCount, const SkPaint& paint); |
| 79 virtual void drawDevice(const SkDraw& draw, SkDevice*, int x, int y, | 79 virtual void drawDevice(const SkDraw& draw, SkDevice*, int x, int y, |
| 80 const SkPaint&); | 80 const SkPaint&); |
| 81 | 81 |
| 82 // Sets the drawing area for the device. Subsequent draw calls are | |
| 83 // directed to the specific drawing area (margin or content area). | |
| 84 virtual void setDrawingArea(SkPDFDevice::DrawingArea area); | |
|
Chris Guillory
2011/07/26 00:10:45
Doesn't need to be virtual.
Aayush Kumar
2011/07/26 01:55:41
Done.
| |
| 85 | |
| 82 protected: | 86 protected: |
| 83 virtual SkDevice* onCreateCompatibleDevice(SkBitmap::Config, int width, | 87 virtual SkDevice* onCreateCompatibleDevice(SkBitmap::Config, int width, |
| 84 int height, bool isOpaque, | 88 int height, bool isOpaque, |
| 85 Usage usage); | 89 Usage usage); |
| 86 | 90 |
| 87 private: | 91 private: |
| 88 SkRefPtr<SkPDFDevice> pdf_device_; | 92 SkRefPtr<SkPDFDevice> pdf_device_; |
| 89 SkRefPtr<BitmapPlatformDevice> raster_surface_; | 93 SkRefPtr<BitmapPlatformDevice> raster_surface_; |
| 90 | 94 |
| 91 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceSkia); | 95 DISALLOW_COPY_AND_ASSIGN(VectorPlatformDeviceSkia); |
| 92 }; | 96 }; |
| 93 | 97 |
| 94 } // namespace skia | 98 } // namespace skia |
| 95 | 99 |
| 96 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ | 100 #endif // SKIA_EXT_VECTOR_PLATFORM_DEVICE_SKIA_H_ |
| OLD | NEW |