• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright 2015 The PDFium Authors
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_JBIG2_JBIG2_PDDPROC_H_
8 #define CORE_FXCODEC_JBIG2_JBIG2_PDDPROC_H_
9 
10 #include <stdint.h>
11 
12 #include <memory>
13 
14 #include "core/fxcrt/span.h"
15 
16 class CJBig2_ArithDecoder;
17 class CJBig2_BitStream;
18 class CJBig2_GRDProc;
19 class CJBig2_PatternDict;
20 class JBig2ArithCtx;
21 class PauseIndicatorIface;
22 
23 class CJBig2_PDDProc {
24  public:
25   std::unique_ptr<CJBig2_PatternDict> DecodeArith(
26       CJBig2_ArithDecoder* pArithDecoder,
27       pdfium::span<JBig2ArithCtx> gbContexts,
28       PauseIndicatorIface* pPause);
29 
30   std::unique_ptr<CJBig2_PatternDict> DecodeMMR(CJBig2_BitStream* pStream);
31 
32   bool HDMMR;
33   uint8_t HDPW;
34   uint8_t HDPH;
35   uint32_t GRAYMAX;
36   uint8_t HDTEMPLATE;
37 
38  private:
39   std::unique_ptr<CJBig2_GRDProc> CreateGRDProc();
40 };
41 
42 #endif  // CORE_FXCODEC_JBIG2_JBIG2_PDDPROC_H_
43