| 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_CODEC_CODEC_INT_H_ | 7 #ifndef CORE_SRC_FXCODEC_CODEC_CODEC_INT_H_ |
| 8 #define CORE_SRC_FXCODEC_CODEC_CODEC_INT_H_ | 8 #define CORE_SRC_FXCODEC_CODEC_CODEC_INT_H_ |
| 9 | 9 |
| 10 #include <limits.h> | 10 #include <limits.h> |
| (...skipping 229 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 240 CFX_BinaryBuf* pTransformKey); | 240 CFX_BinaryBuf* pTransformKey); |
| 241 | 241 |
| 242 FX_DWORD m_nComponents; | 242 FX_DWORD m_nComponents; |
| 243 std::map<CFX_ByteString, CFX_IccTransformCache*> m_MapTranform; | 243 std::map<CFX_ByteString, CFX_IccTransformCache*> m_MapTranform; |
| 244 std::map<CFX_ByteString, CFX_IccProfileCache*> m_MapProfile; | 244 std::map<CFX_ByteString, CFX_IccProfileCache*> m_MapProfile; |
| 245 }; | 245 }; |
| 246 | 246 |
| 247 class CCodec_JpxModule : public ICodec_JpxModule { | 247 class CCodec_JpxModule : public ICodec_JpxModule { |
| 248 public: | 248 public: |
| 249 CCodec_JpxModule(); | 249 CCodec_JpxModule(); |
| 250 ~CCodec_JpxModule() override; |
| 251 |
| 252 // ICodec_JpxModule: |
| 250 void* CreateDecoder(const uint8_t* src_buf, | 253 void* CreateDecoder(const uint8_t* src_buf, |
| 251 FX_DWORD src_size, | 254 FX_DWORD src_size, |
| 252 FX_BOOL useColorSpace = FALSE); | 255 FX_BOOL useColorSpace) override; |
| 253 void GetImageInfo(void* ctx, | 256 void GetImageInfo(void* ctx, |
| 254 FX_DWORD& width, | 257 FX_DWORD* width, |
| 255 FX_DWORD& height, | 258 FX_DWORD* height, |
| 256 FX_DWORD& codestream_nComps, | 259 FX_DWORD* codestream_nComps, |
| 257 FX_DWORD& output_nComps); | 260 FX_DWORD* output_nComps) override; |
| 258 FX_BOOL Decode(void* ctx, | 261 FX_BOOL Decode(void* ctx, |
| 259 uint8_t* dest_data, | 262 uint8_t* dest_data, |
| 260 int pitch, | 263 int pitch, |
| 261 FX_BOOL bTranslateColor, | 264 uint8_t* offsets) override; |
| 262 uint8_t* offsets); | 265 void DestroyDecoder(void* ctx) override; |
| 263 void DestroyDecoder(void* ctx); | |
| 264 }; | 266 }; |
| 265 | 267 |
| 266 class CPDF_Jbig2Interface : public CJBig2_Module { | 268 class CPDF_Jbig2Interface : public CJBig2_Module { |
| 267 public: | 269 public: |
| 268 virtual void* JBig2_Malloc(FX_DWORD dwSize) { | 270 virtual void* JBig2_Malloc(FX_DWORD dwSize) { |
| 269 return FX_Alloc(uint8_t, dwSize); | 271 return FX_Alloc(uint8_t, dwSize); |
| 270 } | 272 } |
| 271 virtual void* JBig2_Malloc2(FX_DWORD num, FX_DWORD dwSize) { | 273 virtual void* JBig2_Malloc2(FX_DWORD num, FX_DWORD dwSize) { |
| 272 if (dwSize && num >= UINT_MAX / dwSize) { | 274 if (dwSize && num >= UINT_MAX / dwSize) { |
| 273 return NULL; | 275 return NULL; |
| (...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 367 OPJ_SIZE_T opj_read_from_memory(void* p_buffer, | 369 OPJ_SIZE_T opj_read_from_memory(void* p_buffer, |
| 368 OPJ_SIZE_T nb_bytes, | 370 OPJ_SIZE_T nb_bytes, |
| 369 void* p_user_data); | 371 void* p_user_data); |
| 370 OPJ_SIZE_T opj_write_from_memory(void* p_buffer, | 372 OPJ_SIZE_T opj_write_from_memory(void* p_buffer, |
| 371 OPJ_SIZE_T nb_bytes, | 373 OPJ_SIZE_T nb_bytes, |
| 372 void* p_user_data); | 374 void* p_user_data); |
| 373 OPJ_OFF_T opj_skip_from_memory(OPJ_OFF_T nb_bytes, void* p_user_data); | 375 OPJ_OFF_T opj_skip_from_memory(OPJ_OFF_T nb_bytes, void* p_user_data); |
| 374 OPJ_BOOL opj_seek_from_memory(OPJ_OFF_T nb_bytes, void* p_user_data); | 376 OPJ_BOOL opj_seek_from_memory(OPJ_OFF_T nb_bytes, void* p_user_data); |
| 375 | 377 |
| 376 #endif // CORE_SRC_FXCODEC_CODEC_CODEC_INT_H_ | 378 #endif // CORE_SRC_FXCODEC_CODEC_CODEC_INT_H_ |
| OLD | NEW |