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_INCLUDE_FXCODEC_FX_CODEC_H_ | 7 #ifndef CORE_INCLUDE_FXCODEC_FX_CODEC_H_ |
8 #define CORE_INCLUDE_FXCODEC_FX_CODEC_H_ | 8 #define CORE_INCLUDE_FXCODEC_FX_CODEC_H_ |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "core/include/fxcrt/fx_basic.h" | 12 #include "core/include/fxcrt/fx_basic.h" |
13 #include "fx_codec_def.h" | 13 #include "fx_codec_def.h" |
14 #include "third_party/base/nonstd_unique_ptr.h" | 14 #include "third_party/base/nonstd_unique_ptr.h" |
15 | 15 |
16 class CFX_DIBSource; | 16 class CFX_DIBSource; |
17 class CJPX_Decoder; | 17 class CJPX_Decoder; |
| 18 class CPDF_ColorSpace; |
18 class CPDF_PrivateData; | 19 class CPDF_PrivateData; |
19 class CPDF_StreamAcc; | 20 class CPDF_StreamAcc; |
20 class ICodec_ScanlineDecoder; | 21 class ICodec_ScanlineDecoder; |
21 class ICodec_BasicModule; | 22 class ICodec_BasicModule; |
22 class ICodec_FaxModule; | 23 class ICodec_FaxModule; |
23 class ICodec_JpegModule; | 24 class ICodec_JpegModule; |
24 class ICodec_JpxModule; | 25 class ICodec_JpxModule; |
25 class ICodec_Jbig2Module; | 26 class ICodec_Jbig2Module; |
26 class ICodec_IccModule; | 27 class ICodec_IccModule; |
27 class ICodec_FlateModule; | 28 class ICodec_FlateModule; |
(...skipping 172 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
200 virtual FX_DWORD GetAvailInput(void* pContext, | 201 virtual FX_DWORD GetAvailInput(void* pContext, |
201 uint8_t** avail_buf_ptr = NULL) = 0; | 202 uint8_t** avail_buf_ptr = NULL) = 0; |
202 }; | 203 }; |
203 | 204 |
204 class ICodec_JpxModule { | 205 class ICodec_JpxModule { |
205 public: | 206 public: |
206 virtual ~ICodec_JpxModule() {} | 207 virtual ~ICodec_JpxModule() {} |
207 | 208 |
208 virtual CJPX_Decoder* CreateDecoder(const uint8_t* src_buf, | 209 virtual CJPX_Decoder* CreateDecoder(const uint8_t* src_buf, |
209 FX_DWORD src_size, | 210 FX_DWORD src_size, |
210 bool use_colorspace) = 0; | 211 CPDF_ColorSpace* cs) = 0; |
211 | 212 |
212 virtual void GetImageInfo(CJPX_Decoder* pDecoder, | 213 virtual void GetImageInfo(CJPX_Decoder* pDecoder, |
213 FX_DWORD* width, | 214 FX_DWORD* width, |
214 FX_DWORD* height, | 215 FX_DWORD* height, |
215 FX_DWORD* components) = 0; | 216 FX_DWORD* components) = 0; |
216 | 217 |
217 virtual bool Decode(CJPX_Decoder* pDecoder, | 218 virtual bool Decode(CJPX_Decoder* pDecoder, |
218 uint8_t* dest_data, | 219 uint8_t* dest_data, |
219 int pitch, | 220 int pitch, |
220 const std::vector<uint8_t>& offsets) = 0; | 221 const std::vector<uint8_t>& offsets) = 0; |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
335 FX_BOOL MD5ComputeID(const void* buf, FX_DWORD dwSize, uint8_t ID[16]); | 336 FX_BOOL MD5ComputeID(const void* buf, FX_DWORD dwSize, uint8_t ID[16]); |
336 void FaxG4Decode(const uint8_t* src_buf, | 337 void FaxG4Decode(const uint8_t* src_buf, |
337 FX_DWORD src_size, | 338 FX_DWORD src_size, |
338 int* pbitpos, | 339 int* pbitpos, |
339 uint8_t* dest_buf, | 340 uint8_t* dest_buf, |
340 int width, | 341 int width, |
341 int height, | 342 int height, |
342 int pitch); | 343 int pitch); |
343 | 344 |
344 #endif // CORE_INCLUDE_FXCODEC_FX_CODEC_H_ | 345 #endif // CORE_INCLUDE_FXCODEC_FX_CODEC_H_ |
OLD | NEW |