| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2015 Google Inc. | 2 * Copyright 2015 Google Inc. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 #ifndef SkMaskSwizzler_DEFINED | 7 #ifndef SkMaskSwizzler_DEFINED |
| 8 #define SkMaskSwizzler_DEFINED | 8 #define SkMaskSwizzler_DEFINED |
| 9 | 9 |
| 10 #include "SkMasks.h" | 10 #include "SkMasks.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 void* dstRow, const uint8_t* srcRow, int width, | 44 void* dstRow, const uint8_t* srcRow, int width, |
| 45 SkMasks* masks, uint32_t startX, uint32_t sampleX); | 45 SkMasks* masks, uint32_t startX, uint32_t sampleX); |
| 46 | 46 |
| 47 /* | 47 /* |
| 48 * Constructor for mask swizzler | 48 * Constructor for mask swizzler |
| 49 */ | 49 */ |
| 50 SkMaskSwizzler(int width, SkMasks* masks, RowProc proc); | 50 SkMaskSwizzler(int width, SkMasks* masks, RowProc proc); |
| 51 | 51 |
| 52 int onSetSampleX(int) override; | 52 int onSetSampleX(int) override; |
| 53 | 53 |
| 54 int onGetScaledWidth() override { |
| 55 return fDstWidth; |
| 56 } |
| 57 |
| 54 SkMasks* fMasks; // unowned | 58 SkMasks* fMasks; // unowned |
| 55 const RowProc fRowProc; | 59 const RowProc fRowProc; |
| 56 | 60 |
| 57 // FIXME: Can this class share more with SkSwizzler? These variables are all
the same. | 61 // FIXME: Can this class share more with SkSwizzler? These variables are all
the same. |
| 58 const int fSrcWidth; // Width of the source - i.e. before any s
ampling. | 62 const int fSrcWidth; // Width of the source - i.e. before any s
ampling. |
| 59 int fDstWidth; // Width of dst, which may differ with sam
pling. | 63 int fDstWidth; // Width of dst, which may differ with sam
pling. |
| 60 int fSampleX; | 64 int fSampleX; |
| 61 int fX0; | 65 int fX0; |
| 62 }; | 66 }; |
| 63 | 67 |
| 64 #endif | 68 #endif |
| OLD | NEW |