OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 PDFium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | |
6 | |
7 #ifndef CORE_FXCODEC_CODEC_CCODEC_GIFMODULE_H_ | |
8 #define CORE_FXCODEC_CODEC_CCODEC_GIFMODULE_H_ | |
9 | |
10 #include "core/fxcrt/include/fx_system.h" | |
11 | |
12 class CCodec_GifModule { | |
13 public: | |
14 CCodec_GifModule() { FXSYS_memset(m_szLastError, '\0', 256); } | |
Tom Sepez
2016/04/11 17:16:21
howzabout just 0 and sizeof(m_szLastError) for con
dsinclair
2016/04/11 20:40:39
Done.
| |
15 | |
16 void* Start(void* pModule); | |
17 void Finish(void* pContext); | |
18 | |
19 uint32_t GetAvailInput(void* pContext, uint8_t** avail_buf_ptr = nullptr); | |
20 void Input(void* pContext, const uint8_t* src_buf, uint32_t src_size); | |
21 | |
22 int32_t ReadHeader(void* pContext, | |
23 int* width, | |
24 int* height, | |
25 int* pal_num, | |
26 void** pal_pp, | |
27 int* bg_index, | |
28 CFX_DIBAttribute* pAttribute); | |
29 | |
30 int32_t LoadFrameInfo(void* pContext, int* frame_num); | |
31 | |
32 int32_t LoadFrame(void* pContext, | |
33 int frame_num, | |
34 CFX_DIBAttribute* pAttribute); | |
35 | |
36 void (*RecordCurrentPositionCallback)(void* pModule, uint32_t& cur_pos); | |
37 uint8_t* (*AskLocalPaletteBufCallback)(void* pModule, | |
38 int32_t frame_num, | |
39 int32_t pal_size); | |
40 FX_BOOL (*InputRecordPositionBufCallback)(void* pModule, | |
41 uint32_t rcd_pos, | |
42 const FX_RECT& img_rc, | |
43 int32_t pal_num, | |
44 void* pal_ptr, | |
45 int32_t delay_time, | |
46 FX_BOOL user_input, | |
47 int32_t trans_index, | |
48 int32_t disposal_method, | |
49 FX_BOOL interlace); | |
50 void (*ReadScanlineCallback)(void* pModule, | |
51 int32_t row_num, | |
52 uint8_t* row_buf); | |
53 | |
54 protected: | |
55 FX_CHAR m_szLastError[256]; | |
56 }; | |
57 | |
58 #endif // CORE_FXCODEC_CODEC_CCODEC_GIFMODULE_H_ | |
OLD | NEW |