Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(538)

Side by Side Diff: core/src/fxcodec/jbig2/JBig2_Image.h

Issue 1265503005: clang-format all pdfium code. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: sigh Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 _JBIG2_IMAGE_H_ 7 #ifndef _JBIG2_IMAGE_H_
8 #define _JBIG2_IMAGE_H_ 8 #define _JBIG2_IMAGE_H_
9 #include "JBig2_Define.h" 9 #include "JBig2_Define.h"
10 #include "JBig2_Module.h" 10 #include "JBig2_Module.h"
11 typedef enum { 11 typedef enum {
12 JBIG2_COMPOSE_OR» » = 0, 12 JBIG2_COMPOSE_OR = 0,
13 JBIG2_COMPOSE_AND» » = 1, 13 JBIG2_COMPOSE_AND = 1,
14 JBIG2_COMPOSE_XOR» » = 2, 14 JBIG2_COMPOSE_XOR = 2,
15 JBIG2_COMPOSE_XNOR» » = 3, 15 JBIG2_COMPOSE_XNOR = 3,
16 JBIG2_COMPOSE_REPLACE» = 4 16 JBIG2_COMPOSE_REPLACE = 4
17 } JBig2ComposeOp; 17 } JBig2ComposeOp;
18 struct FX_RECT; 18 struct FX_RECT;
19 class CJBig2_Image : public CJBig2_Object 19 class CJBig2_Image : public CJBig2_Object {
20 { 20 public:
21 public: 21 CJBig2_Image(int32_t w, int32_t h);
22 22
23 CJBig2_Image(int32_t w, int32_t h); 23 CJBig2_Image(int32_t w, int32_t h, int32_t stride, uint8_t* pBuf);
24 24
25 CJBig2_Image(int32_t w, int32_t h, int32_t stride, uint8_t*pBuf); 25 CJBig2_Image(CJBig2_Image& im);
26 26
27 CJBig2_Image(CJBig2_Image &im); 27 ~CJBig2_Image();
28 28
29 ~CJBig2_Image(); 29 FX_BOOL getPixel(int32_t x, int32_t y);
30 30
31 FX_BOOL getPixel(int32_t x, int32_t y); 31 int32_t setPixel(int32_t x, int32_t y, FX_BOOL v);
32 32
33 int32_t setPixel(int32_t x, int32_t y, FX_BOOL v); 33 void copyLine(int32_t hTo, int32_t hFrom);
34 34
35 void copyLine(int32_t hTo, int32_t hFrom); 35 void fill(FX_BOOL v);
36 36
37 void fill(FX_BOOL v); 37 FX_BOOL composeTo(CJBig2_Image* pDst,
38 int32_t x,
39 int32_t y,
40 JBig2ComposeOp op);
41 FX_BOOL composeTo(CJBig2_Image* pDst,
42 int32_t x,
43 int32_t y,
44 JBig2ComposeOp op,
45 const FX_RECT* pSrcRect);
38 46
39 FX_BOOL composeTo(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2ComposeOp o p); 47 FX_BOOL composeTo_unopt(CJBig2_Image* pDst,
40 FX_BOOL composeTo(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2ComposeOp o p, const FX_RECT* pSrcRect); 48 int32_t x,
49 int32_t y,
50 JBig2ComposeOp op);
41 51
42 FX_BOOL composeTo_unopt(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2Compo seOp op); 52 FX_BOOL composeTo_opt(CJBig2_Image* pDst,
53 int32_t x,
54 int32_t y,
55 JBig2ComposeOp op);
43 56
44 FX_BOOL composeTo_opt(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2Compose Op op); 57 FX_BOOL composeTo_opt2(CJBig2_Image* pDst,
58 int32_t x,
59 int32_t y,
60 JBig2ComposeOp op);
61 FX_BOOL composeTo_opt2(CJBig2_Image* pDst,
62 int32_t x,
63 int32_t y,
64 JBig2ComposeOp op,
65 const FX_RECT* pSrcRect);
45 66
46 FX_BOOL composeTo_opt2(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2Compos eOp op); 67 FX_BOOL composeFrom(int32_t x,
47 FX_BOOL composeTo_opt2(CJBig2_Image *pDst, int32_t x, int32_t y, JBig2Compos eOp op, const FX_RECT* pSrcRect); 68 int32_t y,
69 CJBig2_Image* pSrc,
70 JBig2ComposeOp op);
71 FX_BOOL composeFrom(int32_t x,
72 int32_t y,
73 CJBig2_Image* pSrc,
74 JBig2ComposeOp op,
75 const FX_RECT* pSrcRect);
76 CJBig2_Image* subImage_unopt(int32_t x, int32_t y, int32_t w, int32_t h);
48 77
49 FX_BOOL composeFrom(int32_t x, int32_t y, CJBig2_Image *pSrc, JBig2ComposeOp op); 78 CJBig2_Image* subImage(int32_t x, int32_t y, int32_t w, int32_t h);
50 FX_BOOL composeFrom(int32_t x, int32_t y, CJBig2_Image *pSrc, JBig2ComposeOp op, const FX_RECT* pSrcRect);
51 CJBig2_Image *subImage_unopt(int32_t x, int32_t y, int32_t w, int32_t h);
52 79
53 CJBig2_Image *subImage(int32_t x, int32_t y, int32_t w, int32_t h); 80 void expand(int32_t h, FX_BOOL v);
54 81
55 void expand(int32_t h, FX_BOOL v); 82 public:
56 public: 83 int32_t m_nWidth;
57 84
58 int32_t m_nWidth; 85 int32_t m_nHeight;
59 86
60 int32_t m_nHeight; 87 int32_t m_nStride;
61 88
62 int32_t m_nStride; 89 uint8_t* m_pData;
63 90
64 uint8_t *m_pData; 91 FX_BOOL m_bNeedFree;
65
66 FX_BOOL m_bNeedFree;
67 }; 92 };
68 #endif 93 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698