OLD | NEW |
---|---|
(Empty) | |
1 /* | |
2 * Copyright 2015 Google Inc. | |
3 * | |
4 * Use of this source code is governed by a BSD-style license that can be | |
5 * found in the LICENSE file. | |
6 */ | |
7 | |
8 #ifndef SkBitmapController_DEFINED | |
9 #define SkBitmapController_DEFINED | |
10 | |
11 #include "SkFilterQuality.h" | |
12 | |
13 class SkBitmap; | |
14 class SkMatrix; | |
15 | |
16 /** | |
17 * Handles request to scale, filter, and lock a bitmap to be rasterized. | |
18 */ | |
19 class SkBitmapController { | |
20 public: | |
21 bool requestBitmap(const SkBitmap& inBM, const SkMatrix& inverse, SkFilterQu ality inQuality, | |
22 SkBitmap* outBM, SkMatrix* outInv, SkFilterQuality* outQu ality); | |
scroggo
2015/06/02 13:24:54
Maybe add a comment - it looks like all of these m
reed1
2015/06/02 14:07:46
New version is simpler/clearer.
| |
23 | |
24 protected: | |
25 virtual bool onRequestBitmap(const SkBitmap& inBM, const SkMatrix& inverse, SkFilterQuality inQ, | |
26 SkBitmap* outBM, SkMatrix* outInv, SkFilterQual ity* outQ) = 0; | |
27 }; | |
28 | |
29 //////////////////////////////////////////////////////////////////////////////// /////////////////// | |
30 | |
31 class SkDefaultBitmapController : public SkBitmapController { | |
32 public: | |
33 SkDefaultBitmapController() {} | |
34 | |
35 protected: | |
36 bool onRequestBitmap(const SkBitmap&, const SkMatrix&, SkFilterQuality, | |
37 SkBitmap*, SkMatrix*, SkFilterQuality*) override; | |
38 }; | |
39 | |
40 #endif | |
OLD | NEW |