| 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 | 9 |
| 10 #ifndef SkImageDecoder_DEFINED | 10 #ifndef SkImageDecoder_DEFINED |
| 11 #define SkImageDecoder_DEFINED | 11 #define SkImageDecoder_DEFINED |
| 12 | 12 |
| 13 #include "SkBitmap.h" | 13 #include "SkBitmap.h" |
| 14 #include "SkImage.h" | 14 #include "SkImage.h" |
| 15 #include "SkRect.h" | 15 #include "SkRect.h" |
| 16 #include "SkRefCnt.h" | 16 #include "SkRefCnt.h" |
| 17 #include "SkTRegistry.h" | 17 #include "SkTRegistry.h" |
| 18 #include "SkTypes.h" | 18 #include "SkTypes.h" |
| 19 | 19 |
| 20 class SkStream; | 20 class SkStream; |
| 21 class SkStreamRewindable; | 21 class SkStreamRewindable; |
| 22 | 22 |
| 23 /** \class SkImageDecoder | 23 /** \class SkImageDecoder |
| 24 | 24 |
| 25 Base class for decoding compressed images into a SkBitmap | 25 Base class for decoding compressed images into a SkBitmap |
| 26 */ | 26 */ |
| 27 class SkImageDecoder : public SkNoncopyable { | 27 class SkImageDecoder : SkNoncopyable { |
| 28 public: | 28 public: |
| 29 virtual ~SkImageDecoder(); | 29 virtual ~SkImageDecoder(); |
| 30 | 30 |
| 31 enum Format { | 31 enum Format { |
| 32 kUnknown_Format, | 32 kUnknown_Format, |
| 33 kBMP_Format, | 33 kBMP_Format, |
| 34 kGIF_Format, | 34 kGIF_Format, |
| 35 kICO_Format, | 35 kICO_Format, |
| 36 kJPEG_Format, | 36 kJPEG_Format, |
| 37 kPNG_Format, | 37 kPNG_Format, |
| (...skipping 493 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 531 DECLARE_DECODER_CREATOR(WBMPImageDecoder); | 531 DECLARE_DECODER_CREATOR(WBMPImageDecoder); |
| 532 DECLARE_DECODER_CREATOR(WEBPImageDecoder); | 532 DECLARE_DECODER_CREATOR(WEBPImageDecoder); |
| 533 | 533 |
| 534 | 534 |
| 535 // Typedefs to make registering decoder and formatter callbacks easier. | 535 // Typedefs to make registering decoder and formatter callbacks easier. |
| 536 // These have to be defined outside SkImageDecoder. :( | 536 // These have to be defined outside SkImageDecoder. :( |
| 537 typedef SkTRegistry<SkImageDecoder*(*)(SkStreamRewindable*)> SkImageDecod
er_DecodeReg; | 537 typedef SkTRegistry<SkImageDecoder*(*)(SkStreamRewindable*)> SkImageDecod
er_DecodeReg; |
| 538 typedef SkTRegistry<SkImageDecoder::Format(*)(SkStreamRewindable*)> SkImageDecod
er_FormatReg; | 538 typedef SkTRegistry<SkImageDecoder::Format(*)(SkStreamRewindable*)> SkImageDecod
er_FormatReg; |
| 539 | 539 |
| 540 #endif | 540 #endif |
| OLD | NEW |