| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2007 The Android Open Source Project | 2 * Copyright 2007 The Android Open Source Project |
| 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 | 7 |
| 8 #ifndef SkBitmapProcState_DEFINED | 8 #ifndef SkBitmapProcState_DEFINED |
| 9 #define SkBitmapProcState_DEFINED | 9 #define SkBitmapProcState_DEFINED |
| 10 | 10 |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 class SkPaint; | 28 class SkPaint; |
| 29 | 29 |
| 30 struct SkBitmapProcInfo { | 30 struct SkBitmapProcInfo { |
| 31 SkBitmapProcInfo(const SkBitmapProvider&, SkShader::TileMode tmx, SkShader::
TileMode tmy); | 31 SkBitmapProcInfo(const SkBitmapProvider&, SkShader::TileMode tmx, SkShader::
TileMode tmy); |
| 32 SkBitmapProcInfo(const SkBitmap&, SkShader::TileMode tmx, SkShader::TileMode
tmy); | 32 SkBitmapProcInfo(const SkBitmap&, SkShader::TileMode tmx, SkShader::TileMode
tmy); |
| 33 ~SkBitmapProcInfo(); | 33 ~SkBitmapProcInfo(); |
| 34 | 34 |
| 35 const SkBitmapProvider fProvider; | 35 const SkBitmapProvider fProvider; |
| 36 | 36 |
| 37 SkPixmap fPixmap; | 37 SkPixmap fPixmap; |
| 38 SkMatrix fInvMatrix; // copy of what is in fBMState, can
we remove the dup? | 38 SkMatrix fInvMatrix; // This changes based on tile mode. |
| 39 // TODO: combine fInvMatrix and fRealInvMatrix. |
| 40 SkMatrix fRealInvMatrix; // The actual inverse matrix. |
| 39 SkColor fPaintColor; | 41 SkColor fPaintColor; |
| 40 SkShader::TileMode fTileModeX; | 42 SkShader::TileMode fTileModeX; |
| 41 SkShader::TileMode fTileModeY; | 43 SkShader::TileMode fTileModeY; |
| 42 SkFilterQuality fFilterQuality; | 44 SkFilterQuality fFilterQuality; |
| 43 SkMatrix::TypeMask fInvType; | 45 SkMatrix::TypeMask fInvType; |
| 44 | 46 |
| 45 bool init(const SkMatrix& inverse, const SkPaint&); | 47 bool init(const SkMatrix& inverse, const SkPaint&); |
| 46 | 48 |
| 47 private: | 49 private: |
| 48 enum { | 50 enum { |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 253 SkFixed fixedY() const { return SkFractionalIntToFixed(fY); } | 255 SkFixed fixedY() const { return SkFractionalIntToFixed(fY); } |
| 254 | 256 |
| 255 int intX() const { return SkFractionalIntToInt(fX); } | 257 int intX() const { return SkFractionalIntToInt(fX); } |
| 256 int intY() const { return SkFractionalIntToInt(fY); } | 258 int intY() const { return SkFractionalIntToInt(fY); } |
| 257 | 259 |
| 258 private: | 260 private: |
| 259 SkFractionalInt fX, fY; | 261 SkFractionalInt fX, fY; |
| 260 }; | 262 }; |
| 261 | 263 |
| 262 #endif | 264 #endif |
| OLD | NEW |