OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 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 | 7 |
8 #ifndef SkPictureShader_DEFINED | 8 #ifndef SkPictureShader_DEFINED |
9 #define SkPictureShader_DEFINED | 9 #define SkPictureShader_DEFINED |
10 | 10 |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 protected: | 62 protected: |
63 SkPictureShader(SkReadBuffer&); | 63 SkPictureShader(SkReadBuffer&); |
64 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; | 64 virtual void flatten(SkWriteBuffer&) const SK_OVERRIDE; |
65 | 65 |
66 private: | 66 private: |
67 SkPictureShader(SkPicture*, TileMode, TileMode); | 67 SkPictureShader(SkPicture*, TileMode, TileMode); |
68 | 68 |
69 SkShader* validInternal(const SkBitmap& device, const SkPaint& paint, | 69 SkShader* validInternal(const SkBitmap& device, const SkPaint& paint, |
70 const SkMatrix& matrix, SkMatrix* totalInverse) cons
t; | 70 const SkMatrix& matrix, SkMatrix* totalInverse) cons
t; |
71 | 71 |
72 SkShader* refBitmapShader(const SkMatrix&) const; | 72 SkShader* buildBitmapShader(const SkMatrix&) const; |
73 | 73 |
74 SkPicture* fPicture; | 74 SkPicture* fPicture; |
75 TileMode fTmx, fTmy; | 75 TileMode fTmx, fTmy; |
76 | 76 |
77 mutable SkMutex fCachedBitmapShaderMutex; | 77 mutable SkMutex fCachedBitmapShaderMutex; |
78 mutable SkAutoTUnref<SkShader> fCachedBitmapShader; | 78 mutable SkAutoTUnref<SkShader> fCachedBitmapShader; |
79 mutable SkSize fCachedTileScale; | 79 mutable SkSize fCachedTileScale; |
80 mutable SkMatrix fCachedLocalMatrix; | 80 mutable SkMatrix fCachedLocalMatrix; |
81 | 81 |
82 typedef SkShader INHERITED; | 82 typedef SkShader INHERITED; |
83 }; | 83 }; |
84 | 84 |
85 #endif // SkPictureShader_DEFINED | 85 #endif // SkPictureShader_DEFINED |
OLD | NEW |