Chromium Code Reviews| Index: src/core/SkPictureImageGenerator.h |
| diff --git a/src/core/SkPictureImageGenerator.h b/src/core/SkPictureImageGenerator.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..ef8ad361ff2fc7cb4ec7d041e7e6d5c36187258e |
| --- /dev/null |
| +++ b/src/core/SkPictureImageGenerator.h |
| @@ -0,0 +1,35 @@ |
| +/* |
| + * Copyright 2015 Google Inc. |
| + * |
| + * Use of this source code is governed by a BSD-style license that can be |
| + * found in the LICENSE file. |
| + */ |
| + |
| +#include "SkImageGenerator.h" |
| + |
| +#include "SkMatrix.h" |
| +#include "SkPaint.h" |
| +#include "SkRefCnt.h" |
| +#include "SkTLazy.h" |
| + |
| +class SkPicture; |
| + |
| +class SkPictureImageGenerator : SkImageGenerator { |
| +public: |
| + static SkImageGenerator* create(const SkISize&, const SkPicture*, const SkMatrix*, |
|
reed1
2015/07/17 18:25:42
Create
f(malita)
2015/07/17 18:39:01
Done.
|
| + const SkPaint*); |
| + |
| +protected: |
| + bool onGetPixels(const SkImageInfo& info, void* pixels, size_t rowBytes, SkPMColor ctable[], |
| + int* ctableCount) override; |
| + |
| +private: |
| + SkPictureImageGenerator(const SkISize&, const SkPicture*, const SkMatrix*, const SkPaint*); |
| + |
| + const SkImageInfo fInfo; |
| + SkAutoTUnref<const SkPicture> fPicture; |
| + SkTLazy<SkMatrix> fMatrix; |
|
reed1
2015/07/17 18:25:42
No real reason to make matrix lazy -- it could jus
f(malita)
2015/07/17 18:39:01
Done.
|
| + SkTLazy<SkPaint> fPaint; |
| + |
| + typedef SkImageGenerator INHERITED; |
| +}; |