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 | 7 |
8 #ifndef SkCodec_DEFINED | 8 #ifndef SkCodec_DEFINED |
9 #define SkCodec_DEFINED | 9 #define SkCodec_DEFINED |
10 | 10 |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
61 return true; | 61 return true; |
62 } | 62 } |
63 | 63 |
64 // Helper for subclasses. | 64 // Helper for subclasses. |
65 const SkImageInfo& getOriginalInfo() { return fInfo; } | 65 const SkImageInfo& getOriginalInfo() { return fInfo; } |
66 | 66 |
67 virtual SkISize onGetScaledDimensions(float desiredScale) const { | 67 virtual SkISize onGetScaledDimensions(float desiredScale) const { |
68 // By default, scaling is not supported. | 68 // By default, scaling is not supported. |
69 return fInfo.dimensions(); | 69 return fInfo.dimensions(); |
70 } | 70 } |
71 | |
72 SkAutoTDelete<SkStream> fStream; | |
msarett
2015/02/24 21:56:06
I needed to make this field protected to use in Sk
scroggo
2015/02/25 17:22:41
I'd prefer a protected accessor:
protected:
SkS
| |
71 | 73 |
72 private: | 74 private: |
73 const SkImageInfo fInfo; | 75 const SkImageInfo fInfo; |
74 SkAutoTDelete<SkStream> fStream; | |
75 }; | 76 }; |
76 #endif // SkCodec_DEFINED | 77 #endif // SkCodec_DEFINED |
OLD | NEW |