OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2006 The Android Open Source Project | 3 * Copyright 2006 The Android Open Source Project |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 #include "SkBitmap.h" | 9 #include "SkBitmap.h" |
10 #include "SkBitmapFactory.h" | 10 #include "SkBitmapFactory.h" |
11 #include "SkImage.h" | 11 #include "SkImage.h" |
12 #include "SkImageDecoder.h" | 12 #include "SkImageDecoder.h" |
13 #include "SkImageEncoder.h" | 13 #include "SkImageEncoder.h" |
14 #include "SkMovie.h" | 14 #include "SkMovie.h" |
15 | 15 |
16 class SkColorTable; | 16 class SkColorTable; |
17 class SkStream; | 17 class SkStream; |
| 18 class SkStreamRewindable; |
18 | 19 |
19 // Empty implementations for SkImageDecoder. | 20 // Empty implementations for SkImageDecoder. |
20 | 21 |
21 SkImageDecoder* SkImageDecoder::Factory(SkStream*) { | 22 SkImageDecoder* SkImageDecoder::Factory(SkStreamRewindable*) { |
22 return NULL; | 23 return NULL; |
23 } | 24 } |
24 | 25 |
25 void SkImageDecoder::copyFieldsToOther(SkImageDecoder* ) {} | 26 void SkImageDecoder::copyFieldsToOther(SkImageDecoder* ) {} |
26 | 27 |
27 bool SkImageDecoder::DecodeFile(const char[], SkBitmap*, SkBitmap::Config, | 28 bool SkImageDecoder::DecodeFile(const char[], SkBitmap*, SkBitmap::Config, |
28 SkImageDecoder::Mode, SkImageDecoder::Format*) { | 29 SkImageDecoder::Mode, SkImageDecoder::Format*) { |
29 return false; | 30 return false; |
30 } | 31 } |
31 | 32 |
32 bool SkImageDecoder::decode(SkStream*, SkBitmap*, SkBitmap::Config, Mode) { | 33 bool SkImageDecoder::decode(SkStream*, SkBitmap*, SkBitmap::Config, Mode) { |
33 return false; | 34 return false; |
34 } | 35 } |
35 | 36 |
36 bool SkImageDecoder::DecodeStream(SkStream*, SkBitmap*, SkBitmap::Config, | 37 bool SkImageDecoder::DecodeStream(SkStreamRewindable*, SkBitmap*, SkBitmap::Conf
ig, |
37 SkImageDecoder::Mode, | 38 SkImageDecoder::Mode, |
38 SkImageDecoder::Format*) { | 39 SkImageDecoder::Format*) { |
39 return false; | 40 return false; |
40 } | 41 } |
41 | 42 |
42 bool SkImageDecoder::DecodeMemory(const void*, size_t, SkBitmap*, | 43 bool SkImageDecoder::DecodeMemory(const void*, size_t, SkBitmap*, |
43 SkBitmap::Config, SkImageDecoder::Mode, | 44 SkBitmap::Config, SkImageDecoder::Mode, |
44 SkImageDecoder::Format*) { | 45 SkImageDecoder::Format*) { |
45 return false; | 46 return false; |
46 } | 47 } |
47 | 48 |
48 bool SkImageDecoder::buildTileIndex(SkStream*, int *width, int *height) { | 49 bool SkImageDecoder::buildTileIndex(SkStreamRewindable*, int *width, int *height
) { |
49 return false; | 50 return false; |
50 } | 51 } |
51 | 52 |
52 bool SkImageDecoder::decodeSubset(SkBitmap*, const SkIRect&, SkBitmap::Config) { | 53 bool SkImageDecoder::decodeSubset(SkBitmap*, const SkIRect&, SkBitmap::Config) { |
53 return false; | 54 return false; |
54 } | 55 } |
55 | 56 |
56 SkImageDecoder::Format SkImageDecoder::getFormat() const { | 57 SkImageDecoder::Format SkImageDecoder::getFormat() const { |
57 return kUnknown_Format; | 58 return kUnknown_Format; |
58 } | 59 } |
59 | 60 |
60 SkImageDecoder::Format SkImageDecoder::GetStreamFormat(SkStream*) { | 61 SkImageDecoder::Format SkImageDecoder::GetStreamFormat(SkStreamRewindable*) { |
61 return kUnknown_Format; | 62 return kUnknown_Format; |
62 } | 63 } |
63 | 64 |
64 const char* SkImageDecoder::GetFormatName(Format) { | 65 const char* SkImageDecoder::GetFormatName(Format) { |
65 return NULL; | 66 return NULL; |
66 } | 67 } |
67 | 68 |
68 SkImageDecoder::Peeker* SkImageDecoder::setPeeker(Peeker*) { | 69 SkImageDecoder::Peeker* SkImageDecoder::setPeeker(Peeker*) { |
69 return NULL; | 70 return NULL; |
70 } | 71 } |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
105 | 106 |
106 SkBitmap::Config SkImageDecoder::getPrefConfig(SrcDepth, bool) const { | 107 SkBitmap::Config SkImageDecoder::getPrefConfig(SrcDepth, bool) const { |
107 return SkBitmap::kNo_Config; | 108 return SkBitmap::kNo_Config; |
108 } | 109 } |
109 | 110 |
110 | 111 |
111 ///////////////////////////////////////////////////////////////////////// | 112 ///////////////////////////////////////////////////////////////////////// |
112 | 113 |
113 // Empty implementation for SkMovie. | 114 // Empty implementation for SkMovie. |
114 | 115 |
115 SkMovie* SkMovie::DecodeStream(SkStream* stream) { | 116 SkMovie* SkMovie::DecodeStream(SkStreamRewindable* stream) { |
116 return NULL; | 117 return NULL; |
117 } | 118 } |
118 | 119 |
119 ///////////////////////////////////////////////////////////////////////// | 120 ///////////////////////////////////////////////////////////////////////// |
120 | 121 |
121 // Empty implementations for SkImageEncoder. | 122 // Empty implementations for SkImageEncoder. |
122 | 123 |
123 SkImageEncoder* SkImageEncoder::Create(Type t) { | 124 SkImageEncoder* SkImageEncoder::Create(Type t) { |
124 return NULL; | 125 return NULL; |
125 } | 126 } |
(...skipping 21 matching lines...) Expand all Loading... |
147 bool SkImageEncoder::encodeFile(const char file[], const SkBitmap& bm, int quali
ty) { | 148 bool SkImageEncoder::encodeFile(const char file[], const SkBitmap& bm, int quali
ty) { |
148 return false; | 149 return false; |
149 } | 150 } |
150 ///////////////////////////////////////////////////////////////////////// | 151 ///////////////////////////////////////////////////////////////////////// |
151 | 152 |
152 // Empty implementation for SkImages. | 153 // Empty implementation for SkImages. |
153 | 154 |
154 #include "SkImages.h" | 155 #include "SkImages.h" |
155 | 156 |
156 void SkImages::InitializeFlattenables() {} | 157 void SkImages::InitializeFlattenables() {} |
OLD | NEW |