Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(148)

Side by Side Diff: src/codec/SkCodec_libgif.h

Issue 1332053002: Fill incomplete images in SkCodec parent class (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #include "SkCodec.h" 8 #include "SkCodec.h"
9 #include "SkColorTable.h" 9 #include "SkColorTable.h"
10 #include "SkImageInfo.h" 10 #include "SkImageInfo.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 */ 64 */
65 Result onGetPixels(const SkImageInfo&, void*, size_t, const Options&, 65 Result onGetPixels(const SkImageInfo&, void*, size_t, const Options&,
66 SkPMColor*, int32_t*) override; 66 SkPMColor*, int32_t*) override;
67 67
68 SkEncodedFormat onGetEncodedFormat() const override { 68 SkEncodedFormat onGetEncodedFormat() const override {
69 return kGIF_SkEncodedFormat; 69 return kGIF_SkEncodedFormat;
70 } 70 }
71 71
72 bool onRewind() override; 72 bool onRewind() override;
73 73
74 uint32_t onGetFillValue(const SkImageInfo& dstInfo) const override;
75
74 private: 76 private:
75 77
76 /* 78 /*
77 * A gif can contain multiple image frames. We will only decode the first 79 * A gif can contain multiple image frames. We will only decode the first
78 * frame. This function reads up to the first image frame, processing 80 * frame. This function reads up to the first image frame, processing
79 * transparency and/or animation information that comes before the image 81 * transparency and/or animation information that comes before the image
80 * data. 82 * data.
81 * 83 *
82 * @param gif Pointer to the library type that manages the gif decode 84 * @param gif Pointer to the library type that manages the gif decode
83 * @param transIndex This call will set the transparent index based on the 85 * @param transIndex This call will set the transparent index based on the
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 const uint32_t fTransIndex; 167 const uint32_t fTransIndex;
166 uint32_t fFillIndex; 168 uint32_t fFillIndex;
167 bool fFrameIsSubset; 169 bool fFrameIsSubset;
168 SkAutoTDelete<SkSwizzler> fSwizzler; 170 SkAutoTDelete<SkSwizzler> fSwizzler;
169 SkAutoTUnref<SkColorTable> fColorTable; 171 SkAutoTUnref<SkColorTable> fColorTable;
170 172
171 friend class SkGifScanlineDecoder; 173 friend class SkGifScanlineDecoder;
172 174
173 typedef SkCodec INHERITED; 175 typedef SkCodec INHERITED;
174 }; 176 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698