OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2010 Google Inc. All rights reserved. | 2 * Copyright (C) 2010 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 17 matching lines...) Expand all Loading... |
28 | 28 |
29 #ifndef WEBPImageDecoder_h | 29 #ifndef WEBPImageDecoder_h |
30 #define WEBPImageDecoder_h | 30 #define WEBPImageDecoder_h |
31 | 31 |
32 #include "platform/image-decoders/ImageDecoder.h" | 32 #include "platform/image-decoders/ImageDecoder.h" |
33 #include "webp/decode.h" | 33 #include "webp/decode.h" |
34 #include "webp/demux.h" | 34 #include "webp/demux.h" |
35 | 35 |
36 namespace blink { | 36 namespace blink { |
37 | 37 |
38 class PLATFORM_EXPORT WEBPImageDecoder : public ImageDecoder { | 38 class PLATFORM_EXPORT WEBPImageDecoder final : public ImageDecoder { |
39 WTF_MAKE_NONCOPYABLE(WEBPImageDecoder); | 39 WTF_MAKE_NONCOPYABLE(WEBPImageDecoder); |
40 public: | 40 public: |
41 WEBPImageDecoder(AlphaOption, GammaAndColorProfileOption, size_t maxDecodedB
ytes); | 41 WEBPImageDecoder(AlphaOption, GammaAndColorProfileOption, size_t maxDecodedB
ytes); |
42 ~WEBPImageDecoder() override; | 42 ~WEBPImageDecoder() override; |
43 | 43 |
44 // ImageDecoder: | 44 // ImageDecoder: |
45 String filenameExtension() const override { return "webp"; } | 45 String filenameExtension() const override { return "webp"; } |
46 bool hasColorProfile() const override { return m_hasColorProfile; } | 46 bool hasColorProfile() const override { return m_hasColorProfile; } |
47 void onSetData(SharedBuffer* data) override; | 47 void onSetData(SharedBuffer* data) override; |
48 int repetitionCount() const override; | 48 int repetitionCount() const override; |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
88 typedef void (*AlphaBlendFunction)(ImageFrame&, ImageFrame&, int, int, int); | 88 typedef void (*AlphaBlendFunction)(ImageFrame&, ImageFrame&, int, int, int); |
89 AlphaBlendFunction m_blendFunction; | 89 AlphaBlendFunction m_blendFunction; |
90 | 90 |
91 void clear(); | 91 void clear(); |
92 void clearDecoder(); | 92 void clearDecoder(); |
93 }; | 93 }; |
94 | 94 |
95 } // namespace blink | 95 } // namespace blink |
96 | 96 |
97 #endif | 97 #endif |
OLD | NEW |