Chromium Code Reviews| Index: skia/ext/platform_canvas.h |
| diff --git a/skia/ext/platform_canvas.h b/skia/ext/platform_canvas.h |
| index cbeb95b2bbe252cf5c5ebc7bd3abeeb3ad29dcf8..db10ac66b00aca27272371c09ab1eea0817462e8 100644 |
| --- a/skia/ext/platform_canvas.h |
| +++ b/skia/ext/platform_canvas.h |
| @@ -120,6 +120,15 @@ SK_API SkCanvas* TryCreateBitmapCanvas(int width, int height, bool is_opaque); |
| // return NULL PlatformSurface. |
| SK_API bool SupportsPlatformPaint(const SkCanvas* canvas); |
| +// Returns true if native platform routines can be used to draw on the |
|
alokp
2012/09/20 15:47:51
I am still not quite clear on the differences betw
reveman
2012/09/20 17:01:26
In the current implementation this means use of a
|
| +// given canvas without any indirect rendering taking place. Indirect |
| +// rendering can be expensive so it's recommended to avoid using |
| +// platform paint if possible when direct platform paint isn't supported. |
| +// E.g. if there's a method to perform text rendering without platform |
| +// paint then it's likely much more efficient to use that method in the |
| +// case when this function returns false. |
| +SK_API bool SupportsDirectPlatformPaint(const SkCanvas* canvas); |
| + |
| // Draws into the a native platform surface, |context|. Forwards to |
| // DrawToNativeContext on a PlatformDevice instance bound to the top device. |
| // If no PlatformDevice instance is bound, is a no-operation. |