OLD | NEW |
1 // Copyright 2014 PDFium Authors. All rights reserved. | 1 // Copyright 2014 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #ifndef CORE_SRC_FXCODEC_LBMP_FX_BMP_H_ | 7 #ifndef CORE_FXCODEC_LBMP_FX_BMP_H_ |
8 #define CORE_SRC_FXCODEC_LBMP_FX_BMP_H_ | 8 #define CORE_FXCODEC_LBMP_FX_BMP_H_ |
9 | 9 |
10 #include <setjmp.h> | 10 #include <setjmp.h> |
11 | 11 |
12 #include "core/include/fxcrt/fx_basic.h" | 12 #include "core/include/fxcrt/fx_basic.h" |
13 | 13 |
14 #define BMP_WIDTHBYTES(width, bitCount) ((width * bitCount) + 31) / 32 * 4 | 14 #define BMP_WIDTHBYTES(width, bitCount) ((width * bitCount) + 31) / 32 * 4 |
15 #define BMP_PAL_ENCODE(a, r, g, b) \ | 15 #define BMP_PAL_ENCODE(a, r, g, b) \ |
16 (((FX_DWORD)(a) << 24) | ((r) << 16) | ((g) << 8) | (b)) | 16 (((FX_DWORD)(a) << 24) | ((r) << 16) | ((g) << 8) | (b)) |
17 #define BMP_D_STATUS_HEADER 0x01 | 17 #define BMP_D_STATUS_HEADER 0x01 |
18 #define BMP_D_STATUS_PAL 0x02 | 18 #define BMP_D_STATUS_PAL 0x02 |
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
145 | 145 |
146 bmp_compress_struct_p bmp_create_compress(); | 146 bmp_compress_struct_p bmp_create_compress(); |
147 void bmp_destroy_compress(bmp_compress_struct_p bmp_ptr); | 147 void bmp_destroy_compress(bmp_compress_struct_p bmp_ptr); |
148 FX_BOOL bmp_encode_image(bmp_compress_struct_p bmp_ptr, | 148 FX_BOOL bmp_encode_image(bmp_compress_struct_p bmp_ptr, |
149 uint8_t*& dst_buf, | 149 uint8_t*& dst_buf, |
150 FX_DWORD& dst_size); | 150 FX_DWORD& dst_size); |
151 | 151 |
152 FX_WORD GetWord_LSBFirst(uint8_t* p); | 152 FX_WORD GetWord_LSBFirst(uint8_t* p); |
153 void SetWord_LSBFirst(uint8_t* p, FX_WORD v); | 153 void SetWord_LSBFirst(uint8_t* p, FX_WORD v); |
154 | 154 |
155 #endif // CORE_SRC_FXCODEC_LBMP_FX_BMP_H_ | 155 #endif // CORE_FXCODEC_LBMP_FX_BMP_H_ |
OLD | NEW |