Chromium Code Reviews| Index: include/core/SkRRect.h |
| diff --git a/include/core/SkRRect.h b/include/core/SkRRect.h |
| index 32d62856bc90fddec1a33196f8f691ce8506de68..d8029bb5c72aab7420c95af3a56e7743f5e578f8 100644 |
| --- a/include/core/SkRRect.h |
| +++ b/include/core/SkRRect.h |
| @@ -12,6 +12,7 @@ |
| #include "SkPoint.h" |
| class SkPath; |
| +class SkMatrix; |
| // Path forward: |
| // core work |
| @@ -277,6 +278,17 @@ public: |
| */ |
| uint32_t readFromMemory(const void* buffer); |
| + /** |
| + * Transform by the specified matrix, and put the result in dst. |
| + * |
| + * @param matrix SkMatrix specifying the transform. Must only contain |
| + * scale and/or translate, or this call will fail. |
| + * @param dst SkRRect to store the result. It is an error to use this, |
|
reed1
2013/11/04 20:21:09
FYI -- we explicitly support modifying self in SkP
scroggo
2013/11/04 22:29:55
In patch set 1 I allowed modifying the SkRRect, fo
|
| + * which would make this function no longer const. |
| + * @return true on success, false on failure. If false, dst is unmodified. |
| + */ |
| + bool transform(const SkMatrix& matrix, SkRRect* dst) const; |
| + |
| private: |
| SkRect fRect; |
| // Radii order is UL, UR, LR, LL. Use Corner enum to index into fRadii[] |