| 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 "SkBitmapFactory.h" | 14 #include "SkBitmapFactory.h" |
| 15 #include "SkImage.h" | 15 #include "SkImage.h" |
| 16 #include "SkRect.h" | 16 #include "SkRect.h" |
| 17 #include "SkRefCnt.h" | 17 #include "SkRefCnt.h" |
| 18 #include "SkTRegistry.h" |
| 18 #include "SkTypes.h" | 19 #include "SkTypes.h" |
| 19 | 20 |
| 20 class SkStream; | 21 class SkStream; |
| 21 | 22 |
| 22 /** \class SkImageDecoder | 23 /** \class SkImageDecoder |
| 23 | 24 |
| 24 Base class for decoding compressed images into a SkBitmap | 25 Base class for decoding compressed images into a SkBitmap |
| 25 */ | 26 */ |
| 26 class SkImageDecoder : public SkNoncopyable { | 27 class SkImageDecoder : public SkNoncopyable { |
| 27 public: | 28 public: |
| (...skipping 522 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 550 // All the decoders known by Skia. Note that, depending on the compiler settings
, | 551 // All the decoders known by Skia. Note that, depending on the compiler settings
, |
| 551 // not all of these will be available | 552 // not all of these will be available |
| 552 DECLARE_DECODER_CREATOR(BMPImageDecoder); | 553 DECLARE_DECODER_CREATOR(BMPImageDecoder); |
| 553 DECLARE_DECODER_CREATOR(GIFImageDecoder); | 554 DECLARE_DECODER_CREATOR(GIFImageDecoder); |
| 554 DECLARE_DECODER_CREATOR(ICOImageDecoder); | 555 DECLARE_DECODER_CREATOR(ICOImageDecoder); |
| 555 DECLARE_DECODER_CREATOR(JPEGImageDecoder); | 556 DECLARE_DECODER_CREATOR(JPEGImageDecoder); |
| 556 DECLARE_DECODER_CREATOR(PNGImageDecoder); | 557 DECLARE_DECODER_CREATOR(PNGImageDecoder); |
| 557 DECLARE_DECODER_CREATOR(WBMPImageDecoder); | 558 DECLARE_DECODER_CREATOR(WBMPImageDecoder); |
| 558 DECLARE_DECODER_CREATOR(WEBPImageDecoder); | 559 DECLARE_DECODER_CREATOR(WEBPImageDecoder); |
| 559 | 560 |
| 561 |
| 562 // Typedefs to make registering decoder and formatter callbacks easier. |
| 563 // These have to be defined outside SkImageDecoder. :( |
| 564 typedef SkTRegistry<SkImageDecoder*(*)(SkStream*)> SkImageDecoder_DecodeR
eg; |
| 565 typedef SkTRegistry<SkImageDecoder::Format(*)(SkStream*)> SkImageDecoder_FormatR
eg; |
| 566 |
| 560 #endif | 567 #endif |
| OLD | NEW |