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

Side by Side Diff: core/src/fpdfapi/fpdf_render/render_int.h

Issue 1254703002: FX_BOOL considered harmful, part 2. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 5 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
« no previous file with comments | « core/src/fpdfapi/fpdf_render/fpdf_render_text.cpp ('k') | core/src/fpdfdoc/doc_action.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_ 7 #ifndef CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_
8 #define CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_ 8 #define CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_
9 9
10 #include <map> 10 #include <map>
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 protected: 42 protected:
43 CFX_GlyphBitmap* RenderGlyph(CPDF_Type3Glyphs* pSize, FX_DWORD ch arcode, const CFX_AffineMatrix* pMatrix, FX_FLOAT retinaScaleX = 1.0f, FX_FLOAT retinaScaleY = 1.0f); 43 CFX_GlyphBitmap* RenderGlyph(CPDF_Type3Glyphs* pSize, FX_DWORD ch arcode, const CFX_AffineMatrix* pMatrix, FX_FLOAT retinaScaleX = 1.0f, FX_FLOAT retinaScaleY = 1.0f);
44 CPDF_Type3Font* m_pFont; 44 CPDF_Type3Font* m_pFont;
45 CFX_MapByteStringToPtr m_SizeMap; 45 CFX_MapByteStringToPtr m_SizeMap;
46 }; 46 };
47 class CPDF_TransferFunc 47 class CPDF_TransferFunc
48 { 48 {
49 public: 49 public:
50 CPDF_Document* m_pPDFDoc; 50 CPDF_Document* m_pPDFDoc;
51 uint8_t m_Samples[256 * 3]; 51 uint8_t m_Samples[256 * 3];
52 FX_BOOL» » » m_bIdentity; 52 bool» » » m_bIdentity;
53 53
54 CFX_DIBSource*» TranslateImage(const CFX_DIBSource* pSrc, FX_BOOL bAutoD ropSrc); 54 CFX_DIBSource*» TranslateImage(const CFX_DIBSource* pSrc, bool bAutoDrop Src);
55 FX_COLORREF TranslateColor(FX_COLORREF src); 55 FX_COLORREF TranslateColor(FX_COLORREF src);
56 }; 56 };
57 57
58 class CPDF_DocRenderData 58 class CPDF_DocRenderData
59 { 59 {
60 public: 60 public:
61 CPDF_DocRenderData(CPDF_Document* pPDFDoc = NULL); 61 CPDF_DocRenderData(CPDF_Document* pPDFDoc = NULL);
62 ~CPDF_DocRenderData(); 62 ~CPDF_DocRenderData();
63 CPDF_Type3Cache* GetCachedType3(CPDF_Type3Font* pFont); 63 CPDF_Type3Cache* GetCachedType3(CPDF_Type3Font* pFont);
64 CPDF_TransferFunc* GetTransferFunc(CPDF_Object* pObj); 64 CPDF_TransferFunc* GetTransferFunc(CPDF_Object* pObj);
65 CFX_FontCache* GetFontCache() 65 CFX_FontCache* GetFontCache()
66 { 66 {
67 return m_pFontCache; 67 return m_pFontCache;
68 } 68 }
69 void» » » » Clear(FX_BOOL bRelease = FALSE); 69 void» » » » Clear(bool bRelease = false);
70 void ReleaseCachedType3(CPDF_Type3Font* pFont ); 70 void ReleaseCachedType3(CPDF_Type3Font* pFont );
71 void ReleaseTransferFunc(CPDF_Object* pObj); 71 void ReleaseTransferFunc(CPDF_Object* pObj);
72 private: 72 private:
73 using CPDF_Type3CacheMap = 73 using CPDF_Type3CacheMap =
74 std::map<CPDF_Font*, CPDF_CountedObject<CPDF_Type3Cache>*>; 74 std::map<CPDF_Font*, CPDF_CountedObject<CPDF_Type3Cache>*>;
75 using CPDF_TransferFuncMap = 75 using CPDF_TransferFuncMap =
76 std::map<CPDF_Object*, CPDF_CountedObject<CPDF_TransferFunc>*> ; 76 std::map<CPDF_Object*, CPDF_CountedObject<CPDF_TransferFunc>*> ;
77 77
78 CPDF_Document* m_pPDFDoc; 78 CPDF_Document* m_pPDFDoc;
79 CFX_FontCache* m_pFontCache; 79 CFX_FontCache* m_pFontCache;
80 CPDF_Type3CacheMap m_Type3FaceMap; 80 CPDF_Type3CacheMap m_Type3FaceMap;
81 CPDF_TransferFuncMap m_TransferFuncMap; 81 CPDF_TransferFuncMap m_TransferFuncMap;
82 }; 82 };
83 struct _PDF_RenderItem { 83 struct _PDF_RenderItem {
84 public: 84 public:
85 CPDF_PageObjects* m_pObjectList; 85 CPDF_PageObjects* m_pObjectList;
86 CFX_AffineMatrix m_Matrix; 86 CFX_AffineMatrix m_Matrix;
87 }; 87 };
88 typedef CFX_ArrayTemplate<_PDF_RenderItem> CPDF_RenderLayer; 88 typedef CFX_ArrayTemplate<_PDF_RenderItem> CPDF_RenderLayer;
89 class IPDF_ObjectRenderer 89 class IPDF_ObjectRenderer
90 { 90 {
91 public: 91 public:
92 static IPDF_ObjectRenderer* Create(int type); 92 static IPDF_ObjectRenderer* Create(int type);
93 virtual ~IPDF_ObjectRenderer() {} 93 virtual ~IPDF_ObjectRenderer() {}
94 virtual FX_BOOL Start(CPDF_RenderStatus* pRenderStatus, const CPDF_PageObjec t* pObj, const CFX_AffineMatrix* pObj2Device, FX_BOOL bStdCS, int blendType = FX DIB_BLEND_NORMAL) = 0; 94 virtual bool Start(CPDF_RenderStatus* pRenderStatus, const CPDF_PageObject* pObj, const CFX_AffineMatrix* pObj2Device, bool bStdCS, int blendType = FXDIB_BL END_NORMAL) = 0;
95 virtual FX_BOOL Continue(IFX_Pause* pPause) = 0; 95 virtual bool Continue(IFX_Pause* pPause) = 0;
96 FX_BOOL» » m_Result; 96 bool» » m_Result;
97 }; 97 };
98 class CPDF_RenderStatus 98 class CPDF_RenderStatus
99 { 99 {
100 public: 100 public:
101 CPDF_RenderStatus(); 101 CPDF_RenderStatus();
102 ~CPDF_RenderStatus(); 102 ~CPDF_RenderStatus();
103 FX_BOOL» » » Initialize(class CPDF_RenderContext* pContext, C FX_RenderDevice* pDevice, const CFX_AffineMatrix* pDeviceMatrix, 103 bool» » » Initialize(class CPDF_RenderContext* pContext, C FX_RenderDevice* pDevice, const CFX_AffineMatrix* pDeviceMatrix,
104 const CPDF_PageObject* pStopObj, const CPDF_Rende rStatus* pParentStatus, 104 const CPDF_PageObject* pStopObj, const CPDF_Rende rStatus* pParentStatus,
105 const CPDF_GraphicStates* pInitialStates, const C PDF_RenderOptions* pOptions, 105 const CPDF_GraphicStates* pInitialStates, const C PDF_RenderOptions* pOptions,
106 int transparency, FX_BOOL bDropObjects, CPDF_Dict ionary* pFormResource = NULL, 106 int transparency, bool bDropObjects, CPDF_Diction ary* pFormResource = NULL,
107 FX_BOOL bStdCS = FALSE,» CPDF_Type3Char* pType3Ch ar = NULL, FX_ARGB fill_color = 0, 107 bool bStdCS = false,» CPDF_Type3Char* pType3Ch ar = NULL, FX_ARGB fill_color = 0,
108 FX_DWORD GroupFamily = 0, FX_BOOL bLoadMask = FAL SE); 108 FX_DWORD GroupFamily = 0, bool bLoadMask = false) ;
109 void RenderObjectList(const CPDF_PageObjects* pObjs, const CFX_AffineMatrix* pObj2Device); 109 void RenderObjectList(const CPDF_PageObjects* pObjs, const CFX_AffineMatrix* pObj2Device);
110 void RenderSingleObject(const CPDF_PageObject* pObj, const CFX_AffineMatrix* pObj2Device); 110 void RenderSingleObject(const CPDF_PageObject* pObj, const CFX_AffineMatrix* pObj2Device);
111 FX_BOOL» » » ContinueSingleObject(const CPDF_PageObject* pObj , const CFX_AffineMatrix* pObj2Device, IFX_Pause* pPause); 111 bool» » » ContinueSingleObject(const CPDF_PageObject* pObj , const CFX_AffineMatrix* pObj2Device, IFX_Pause* pPause);
112 CPDF_RenderOptions m_Options; 112 CPDF_RenderOptions m_Options;
113 CPDF_Dictionary* m_pFormResource; 113 CPDF_Dictionary* m_pFormResource;
114 CPDF_Dictionary* m_pPageResource; 114 CPDF_Dictionary* m_pPageResource;
115 CFX_PtrArray m_Type3FontCache; 115 CFX_PtrArray m_Type3FontCache;
116 CPDF_RenderContext* GetContext() 116 CPDF_RenderContext* GetContext()
117 { 117 {
118 return m_pContext; 118 return m_pContext;
119 } 119 }
120 protected: 120 protected:
121 friend class CPDF_ImageRenderer; 121 friend class CPDF_ImageRenderer;
122 friend class CPDF_RenderContext; 122 friend class CPDF_RenderContext;
123 void ProcessClipPath(CPDF_ClipPath ClipPath, const CF X_AffineMatrix* pObj2Device); 123 void ProcessClipPath(CPDF_ClipPath ClipPath, const CF X_AffineMatrix* pObj2Device);
124 void DrawClipPath(CPDF_ClipPath ClipPath, const CFX_A ffineMatrix* pObj2Device); 124 void DrawClipPath(CPDF_ClipPath ClipPath, const CFX_A ffineMatrix* pObj2Device);
125 FX_BOOL» » » ProcessTransparency(const CPDF_PageObject* PageO bj, const CFX_AffineMatrix* pObj2Device); 125 bool» » » ProcessTransparency(const CPDF_PageObject* PageO bj, const CFX_AffineMatrix* pObj2Device);
126 void ProcessObjectNoClip(const CPDF_PageObject* PageO bj, const CFX_AffineMatrix* pObj2Device); 126 void ProcessObjectNoClip(const CPDF_PageObject* PageO bj, const CFX_AffineMatrix* pObj2Device);
127 void DrawObjWithBackground(const CPDF_PageObject* pOb j, const CFX_AffineMatrix* pObj2Device); 127 void DrawObjWithBackground(const CPDF_PageObject* pOb j, const CFX_AffineMatrix* pObj2Device);
128 FX_BOOL DrawObjWithBlend(const CPDF_PageObject* pObj, const CFX_Affi neMatrix* pObj2Device); 128 bool DrawObjWithBlend(const CPDF_PageObject* pObj, const CFX_AffineM atrix* pObj2Device);
129 FX_BOOL» » » ProcessPath(CPDF_PathObject* pPathObj, const CFX _AffineMatrix* pObj2Device); 129 bool» » » ProcessPath(CPDF_PathObject* pPathObj, const CFX _AffineMatrix* pObj2Device);
130 void» » » ProcessPathPattern(CPDF_PathObject* pPathObj, co nst CFX_AffineMatrix* pObj2Device, int& filltype, FX_BOOL& bStroke); 130 void» » » ProcessPathPattern(CPDF_PathObject* pPathObj, co nst CFX_AffineMatrix* pObj2Device, int& filltype, bool& bStroke);
131 void» » » DrawPathWithPattern(CPDF_PathObject* pPathObj, c onst CFX_AffineMatrix* pObj2Device, CPDF_Color* pColor, FX_BOOL bStroke); 131 void» » » DrawPathWithPattern(CPDF_PathObject* pPathObj, c onst CFX_AffineMatrix* pObj2Device, CPDF_Color* pColor, bool bStroke);
132 void» » » DrawTilingPattern(CPDF_TilingPattern* pPattern, CPDF_PageObject* pPageObj, const CFX_AffineMatrix* pObj2Device, FX_BOOL bStroke) ; 132 void» » » DrawTilingPattern(CPDF_TilingPattern* pPattern, CPDF_PageObject* pPageObj, const CFX_AffineMatrix* pObj2Device, bool bStroke);
133 void» » » DrawShadingPattern(CPDF_ShadingPattern* pPattern , CPDF_PageObject* pPageObj, const CFX_AffineMatrix* pObj2Device, FX_BOOL bStrok e); 133 void» » » DrawShadingPattern(CPDF_ShadingPattern* pPattern , CPDF_PageObject* pPageObj, const CFX_AffineMatrix* pObj2Device, bool bStroke);
134 FX_BOOL» » » SelectClipPath(CPDF_PathObject* pPathObj, const CFX_AffineMatrix* pObj2Device, FX_BOOL bStroke); 134 bool» » » SelectClipPath(CPDF_PathObject* pPathObj, const CFX_AffineMatrix* pObj2Device, bool bStroke);
135 FX_BOOL» » » ProcessImage(CPDF_ImageObject* pImageObj, const CFX_AffineMatrix* pObj2Device); 135 bool» » » ProcessImage(CPDF_ImageObject* pImageObj, const CFX_AffineMatrix* pObj2Device);
136 FX_BOOL» » » OutputBitmapAlpha(CPDF_ImageObject* pImageObj, c onst CFX_AffineMatrix* pImage2Device); 136 bool» » » OutputBitmapAlpha(CPDF_ImageObject* pImageObj, c onst CFX_AffineMatrix* pImage2Device);
137 FX_BOOL» » » OutputImage(CPDF_ImageObject* pImageObj, const C FX_AffineMatrix* pImage2Device); 137 bool» » » OutputImage(CPDF_ImageObject* pImageObj, const C FX_AffineMatrix* pImage2Device);
138 FX_BOOL» » » OutputDIBSource(const CFX_DIBSource* pOutputBitm ap, FX_ARGB fill_argb, int bitmap_alpha, 138 bool» » » OutputDIBSource(const CFX_DIBSource* pOutputBitm ap, FX_ARGB fill_argb, int bitmap_alpha,
139 const CFX_AffineMatrix* pImage2Device, CPDF_ ImageCache* pImageCache, FX_DWORD flags); 139 const CFX_AffineMatrix* pImage2Device, CPDF_ ImageCache* pImageCache, FX_DWORD flags);
140 void CompositeDIBitmap(CFX_DIBitmap* pDIBitmap, int l eft, int top, FX_ARGB mask_argb, 140 void CompositeDIBitmap(CFX_DIBitmap* pDIBitmap, int l eft, int top, FX_ARGB mask_argb,
141 int bitmap_alpha, int blend_mode, int bIso lated); 141 int bitmap_alpha, int blend_mode, int bIso lated);
142 FX_BOOL» » » ProcessShading(CPDF_ShadingObject* pShadingObj, const CFX_AffineMatrix* pObj2Device); 142 bool» » » ProcessShading(CPDF_ShadingObject* pShadingObj, const CFX_AffineMatrix* pObj2Device);
143 void DrawShading(CPDF_ShadingPattern* pPattern, CFX_A ffineMatrix* pMatrix, FX_RECT& clip_rect, 143 void DrawShading(CPDF_ShadingPattern* pPattern, CFX_A ffineMatrix* pMatrix, FX_RECT& clip_rect,
144 int alpha, FX_BOOL bAlphaMode); 144 int alpha, bool bAlphaMode);
145 FX_BOOL» » » ProcessType3Text(const CPDF_TextObject* textobj, const CFX_AffineMatrix* pObj2Device); 145 bool» » » ProcessType3Text(const CPDF_TextObject* textobj, const CFX_AffineMatrix* pObj2Device);
146 FX_BOOL» » » ProcessText(const CPDF_TextObject* textobj, cons t CFX_AffineMatrix* pObj2Device, CFX_PathData* pClippingPath); 146 bool» » » ProcessText(const CPDF_TextObject* textobj, cons t CFX_AffineMatrix* pObj2Device, CFX_PathData* pClippingPath);
147 void DrawTextPathWithPattern(const CPDF_TextObject* t extobj, const CFX_AffineMatrix* pObj2Device, 147 void DrawTextPathWithPattern(const CPDF_TextObject* t extobj, const CFX_AffineMatrix* pObj2Device,
148 CPDF_Font* pFont, FX_FLOAT font_size , 148 CPDF_Font* pFont, FX_FLOAT font_size ,
149 const CFX_AffineMatrix* pTextMatrix, FX_BOOL bFill, FX_BOOL bStroke); 149 const CFX_AffineMatrix* pTextMatrix, bool bFill, bool bStroke);
150 FX_BOOL» » » ProcessForm(CPDF_FormObject* pFormObj, const CFX _AffineMatrix* pObj2Device); 150 bool» » » ProcessForm(CPDF_FormObject* pFormObj, const CFX _AffineMatrix* pObj2Device);
151 CFX_DIBitmap* GetBackdrop(const CPDF_PageObject* pObj, const FX_RECT& rect, int& left, int& top, 151 CFX_DIBitmap* GetBackdrop(const CPDF_PageObject* pObj, const FX_RECT& rect, int& left, int& top,
152 FX_BOOL bBackAlphaRequired); 152 bool bBackAlphaRequired);
153 CFX_DIBitmap* LoadSMask(CPDF_Dictionary* pSMaskDict, FX_RECT* pClipRec t, const CFX_AffineMatrix* pMatrix); 153 CFX_DIBitmap* LoadSMask(CPDF_Dictionary* pSMaskDict, FX_RECT* pClipRec t, const CFX_AffineMatrix* pMatrix);
154 void Init(CPDF_RenderContext* pParent); 154 void Init(CPDF_RenderContext* pParent);
155 static class CPDF_Type3Cache* GetCachedType3(CPDF_Type3Font* pFont); 155 static class CPDF_Type3Cache* GetCachedType3(CPDF_Type3Font* pFont);
156 static CPDF_GraphicStates* CloneObjStates(const CPDF_GraphicStates* pPathObj , FX_BOOL bStroke); 156 static CPDF_GraphicStates* CloneObjStates(const CPDF_GraphicStates* pPathObj , bool bStroke);
157 CPDF_TransferFunc* GetTransferFunc(CPDF_Object* pObject) const; 157 CPDF_TransferFunc* GetTransferFunc(CPDF_Object* pObject) const;
158 FX_ARGB» » » GetFillArgb(const CPDF_PageObject* pObj, FX_BOOL bType3 = FALSE) const; 158 FX_ARGB» » » GetFillArgb(const CPDF_PageObject* pObj, bool bT ype3 = false) const;
159 FX_ARGB GetStrokeArgb(const CPDF_PageObject* pObj) const ; 159 FX_ARGB GetStrokeArgb(const CPDF_PageObject* pObj) const ;
160 CPDF_RenderContext* m_pContext; 160 CPDF_RenderContext* m_pContext;
161 FX_BOOL» » » » » m_bStopped; 161 bool» » » » » m_bStopped;
162 void DitherObjectArea(const CPDF_PageObject* pObj, co nst CFX_AffineMatrix* pObj2Device); 162 void DitherObjectArea(const CPDF_PageObject* pObj, co nst CFX_AffineMatrix* pObj2Device);
163 FX_BOOL» » » GetObjectClippedRect(const CPDF_PageObject* pObj , const CFX_AffineMatrix* pObj2Device, FX_BOOL bLogical, FX_RECT &rect) const; 163 bool» » » GetObjectClippedRect(const CPDF_PageObject* pObj , const CFX_AffineMatrix* pObj2Device, bool bLogical, FX_RECT &rect) const;
164 void GetScaledMatrix(CFX_Matrix &matrix) const; 164 void GetScaledMatrix(CFX_Matrix &matrix) const;
165 165
166 protected: 166 protected:
167 static const int kRenderMaxRecursionDepth = 64; 167 static const int kRenderMaxRecursionDepth = 64;
168 static int s_CurrentRecursionDepth; 168 static int s_CurrentRecursionDepth;
169 169
170 CFX_RenderDevice* m_pDevice; 170 CFX_RenderDevice* m_pDevice;
171 CFX_AffineMatrix m_DeviceMatrix; 171 CFX_AffineMatrix m_DeviceMatrix;
172 CPDF_ClipPath m_LastClipPath; 172 CPDF_ClipPath m_LastClipPath;
173 const CPDF_PageObject* m_pCurObj; 173 const CPDF_PageObject* m_pCurObj;
174 const CPDF_PageObject* m_pStopObj; 174 const CPDF_PageObject* m_pStopObj;
175 CPDF_GraphicStates m_InitialStates; 175 CPDF_GraphicStates m_InitialStates;
176 int m_HalftoneLimit; 176 int m_HalftoneLimit;
177 IPDF_ObjectRenderer* m_pObjectRenderer; 177 IPDF_ObjectRenderer* m_pObjectRenderer;
178 FX_BOOL» » » » » m_bPrint; 178 bool» » » » » m_bPrint;
179 int m_Transparency; 179 int m_Transparency;
180 int m_DitherBits; 180 int m_DitherBits;
181 FX_BOOL» » » » » m_bDropObjects; 181 bool» » » » » m_bDropObjects;
182 FX_BOOL» » » » » m_bStdCS; 182 bool» » » » » m_bStdCS;
183 FX_DWORD m_GroupFamily; 183 FX_DWORD m_GroupFamily;
184 FX_BOOL m_bLoadMask; 184 bool m_bLoadMask;
185 CPDF_Type3Char * m_pType3Char; 185 CPDF_Type3Char * m_pType3Char;
186 FX_ARGB m_T3FillColor; 186 FX_ARGB m_T3FillColor;
187 int m_curBlend; 187 int m_curBlend;
188 }; 188 };
189 class CPDF_ImageLoader 189 class CPDF_ImageLoader
190 { 190 {
191 public: 191 public:
192 CPDF_ImageLoader() 192 CPDF_ImageLoader()
193 { 193 {
194 m_pBitmap = NULL; 194 m_pBitmap = NULL;
195 m_pMask = NULL; 195 m_pMask = NULL;
196 m_MatteColor = 0; 196 m_MatteColor = 0;
197 m_bCached = FALSE; 197 m_bCached = false;
198 m_nDownsampleWidth = 0; 198 m_nDownsampleWidth = 0;
199 m_nDownsampleHeight = 0; 199 m_nDownsampleHeight = 0;
200 } 200 }
201 201
202 FX_BOOL» » » » » Load(const CPDF_ImageObject* pIm age, CPDF_PageRenderCache* pCache, FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatus = NULL); 202 bool» » » » » Load(const CPDF_ImageObject* pIm age, CPDF_PageRenderCache* pCache, bool bStdCS = false, FX_DWORD GroupFamily = 0 , bool bLoadMask = false, CPDF_RenderStatus* pRenderStatus = NULL);
203 203
204 FX_BOOL» » » » » StartLoadImage(const CPDF_ImageO bject* pImage, CPDF_PageRenderCache* pCache, void*& LoadHandle, FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatus = NULL, int32_t nDownsampleWidth = 0, int32_t nDownsampleHeight = 0); 204 bool» » » » » StartLoadImage(const CPDF_ImageO bject* pImage, CPDF_PageRenderCache* pCache, void*& LoadHandle, bool bStdCS = fa lse, FX_DWORD GroupFamily = 0, bool bLoadMask = false, CPDF_RenderStatus* pRende rStatus = NULL, int32_t nDownsampleWidth = 0, int32_t nDownsampleHeight = 0);
205 FX_BOOL» » » » » Continue(void* LoadHandle, IFX_P ause* pPause); 205 bool» » » » » Continue(void* LoadHandle, IFX_P ause* pPause);
206 ~CPDF_ImageLoader(); 206 ~CPDF_ImageLoader();
207 CFX_DIBSource* m_pBitmap; 207 CFX_DIBSource* m_pBitmap;
208 CFX_DIBSource* m_pMask; 208 CFX_DIBSource* m_pMask;
209 FX_DWORD m_MatteColor; 209 FX_DWORD m_MatteColor;
210 FX_BOOL» » » » » m_bCached; 210 bool» » » » » m_bCached;
211 protected: 211 protected:
212 int32_t m_nDownsampleWidth; 212 int32_t m_nDownsampleWidth;
213 int32_t m_nDownsampleHeight; 213 int32_t m_nDownsampleHeight;
214 }; 214 };
215 class CPDF_ProgressiveImageLoaderHandle 215 class CPDF_ProgressiveImageLoaderHandle
216 { 216 {
217 public: 217 public:
218 CPDF_ProgressiveImageLoaderHandle(); 218 CPDF_ProgressiveImageLoaderHandle();
219 ~CPDF_ProgressiveImageLoaderHandle(); 219 ~CPDF_ProgressiveImageLoaderHandle();
220 220
221 FX_BOOL» » » Start(CPDF_ImageLoader* pImageLoader, const CPDF _ImageObject* pImage, CPDF_PageRenderCache* pCache, FX_BOOL bStdCS = FALSE, FX_D WORD GroupFamily = 0, FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatu s = NULL, int32_t nDownsampleWidth = 0, int32_t nDownsampleHeight = 0); 221 bool» » » Start(CPDF_ImageLoader* pImageLoader, const CPDF _ImageObject* pImage, CPDF_PageRenderCache* pCache, bool bStdCS = false, FX_DWOR D GroupFamily = 0, bool bLoadMask = false, CPDF_RenderStatus* pRenderStatus = NU LL, int32_t nDownsampleWidth = 0, int32_t nDownsampleHeight = 0);
222 FX_BOOL» » » Continue(IFX_Pause* pPause); 222 bool» » » Continue(IFX_Pause* pPause);
223 protected: 223 protected:
224 CPDF_ImageLoader* m_pImageLoader; 224 CPDF_ImageLoader* m_pImageLoader;
225 CPDF_PageRenderCache* m_pCache; 225 CPDF_PageRenderCache* m_pCache;
226 CPDF_ImageObject* m_pImage; 226 CPDF_ImageObject* m_pImage;
227 int32_t m_nDownsampleWidth; 227 int32_t m_nDownsampleWidth;
228 int32_t m_nDownsampleHeight; 228 int32_t m_nDownsampleHeight;
229 }; 229 };
230 class CFX_ImageTransformer; 230 class CFX_ImageTransformer;
231 class CPDF_ImageRenderer : public IPDF_ObjectRenderer 231 class CPDF_ImageRenderer : public IPDF_ObjectRenderer
232 { 232 {
233 public: 233 public:
234 CPDF_ImageRenderer(); 234 CPDF_ImageRenderer();
235 ~CPDF_ImageRenderer(); 235 ~CPDF_ImageRenderer();
236 FX_BOOL» » Start(CPDF_RenderStatus* pStatus, const CPDF_PageObject* pObj, const CFX_AffineMatrix* pObj2Device, FX_BOOL bStdCS, int blendType = FXDI B_BLEND_NORMAL); 236 bool» » Start(CPDF_RenderStatus* pStatus, const CPDF_PageObject* pObj, const CFX_AffineMatrix* pObj2Device, bool bStdCS, int blendType = FXDIB_B LEND_NORMAL);
237 FX_BOOL» » Start(CPDF_RenderStatus* pStatus, const CFX_DIBSource* p DIBSource, FX_ARGB bitmap_argb, 237 bool» » Start(CPDF_RenderStatus* pStatus, const CFX_DIBSource* p DIBSource, FX_ARGB bitmap_argb,
238 int bitmap_alpha, const CFX_AffineMatrix* pImage2Device, F X_DWORD flags, FX_BOOL bStdCS, int blendType = FXDIB_BLEND_NORMAL); 238 int bitmap_alpha, const CFX_AffineMatrix* pImage2Device, F X_DWORD flags, bool bStdCS, int blendType = FXDIB_BLEND_NORMAL);
239 FX_BOOL» » Continue(IFX_Pause* pPause); 239 bool» » Continue(IFX_Pause* pPause);
240 protected: 240 protected:
241 CPDF_RenderStatus* m_pRenderStatus; 241 CPDF_RenderStatus* m_pRenderStatus;
242 CPDF_ImageObject* m_pImageObject; 242 CPDF_ImageObject* m_pImageObject;
243 int m_Status; 243 int m_Status;
244 const CFX_AffineMatrix* m_pObj2Device; 244 const CFX_AffineMatrix* m_pObj2Device;
245 CFX_AffineMatrix m_ImageMatrix; 245 CFX_AffineMatrix m_ImageMatrix;
246 CPDF_ImageLoader m_Loader; 246 CPDF_ImageLoader m_Loader;
247 const CFX_DIBSource* m_pDIBSource; 247 const CFX_DIBSource* m_pDIBSource;
248 CFX_DIBitmap* m_pClone; 248 CFX_DIBitmap* m_pClone;
249 int m_BitmapAlpha; 249 int m_BitmapAlpha;
250 FX_BOOL» » » » m_bPatternColor; 250 bool» » » » m_bPatternColor;
251 CPDF_Pattern* m_pPattern; 251 CPDF_Pattern* m_pPattern;
252 FX_ARGB m_FillArgb; 252 FX_ARGB m_FillArgb;
253 FX_DWORD m_Flags; 253 FX_DWORD m_Flags;
254 CPDF_QuickStretcher* m_pQuickStretcher; 254 CPDF_QuickStretcher* m_pQuickStretcher;
255 CFX_ImageTransformer* m_pTransformer; 255 CFX_ImageTransformer* m_pTransformer;
256 void* m_DeviceHandle; 256 void* m_DeviceHandle;
257 void* m_LoadHandle; 257 void* m_LoadHandle;
258 FX_BOOL» » » » m_bStdCS; 258 bool» » » » m_bStdCS;
259 int m_BlendType; 259 int m_BlendType;
260 FX_BOOL» » » » StartBitmapAlpha(); 260 bool» » » » StartBitmapAlpha();
261 FX_BOOL» » » » StartDIBSource(); 261 bool» » » » StartDIBSource();
262 FX_BOOL» » » » StartRenderDIBSource(); 262 bool» » » » StartRenderDIBSource();
263 FX_BOOL» » » » StartLoadDIBSource(); 263 bool» » » » StartLoadDIBSource();
264 FX_BOOL» » » » DrawMaskedImage(); 264 bool» » » » DrawMaskedImage();
265 FX_BOOL» » » » DrawPatternImage(const CFX_Matrix* pObj2 Device); 265 bool» » » » DrawPatternImage(const CFX_Matrix* pObj2 Device);
266 }; 266 };
267 class CPDF_ScaledRenderBuffer 267 class CPDF_ScaledRenderBuffer
268 { 268 {
269 public: 269 public:
270 CPDF_ScaledRenderBuffer(); 270 CPDF_ScaledRenderBuffer();
271 ~CPDF_ScaledRenderBuffer(); 271 ~CPDF_ScaledRenderBuffer();
272 FX_BOOL» » » » Initialize(CPDF_RenderContext* pContext, CFX_RenderDevice* pDevice, FX_RECT* pRect, 272 bool» » » » Initialize(CPDF_RenderContext* pContext, CFX_RenderDevice* pDevice, FX_RECT* pRect,
273 const CPDF_PageObject* pObj, const CPDF_Rende rOptions *pOptions = NULL, int max_dpi = 0); 273 const CPDF_PageObject* pObj, const CPDF_Rende rOptions *pOptions = NULL, int max_dpi = 0);
274 CFX_RenderDevice* GetDevice() 274 CFX_RenderDevice* GetDevice()
275 { 275 {
276 return m_pBitmapDevice ? m_pBitmapDevice : m_pDevice; 276 return m_pBitmapDevice ? m_pBitmapDevice : m_pDevice;
277 } 277 }
278 CFX_AffineMatrix* GetMatrix() 278 CFX_AffineMatrix* GetMatrix()
279 { 279 {
280 return &m_Matrix; 280 return &m_Matrix;
281 } 281 }
282 void OutputToDevice(); 282 void OutputToDevice();
283 private: 283 private:
284 CFX_RenderDevice* m_pDevice; 284 CFX_RenderDevice* m_pDevice;
285 CPDF_RenderContext* m_pContext; 285 CPDF_RenderContext* m_pContext;
286 FX_RECT m_Rect; 286 FX_RECT m_Rect;
287 const CPDF_PageObject* m_pObject; 287 const CPDF_PageObject* m_pObject;
288 CFX_FxgeDevice* m_pBitmapDevice; 288 CFX_FxgeDevice* m_pBitmapDevice;
289 CFX_AffineMatrix m_Matrix; 289 CFX_AffineMatrix m_Matrix;
290 }; 290 };
291 class ICodec_ScanlineDecoder; 291 class ICodec_ScanlineDecoder;
292 class CPDF_QuickStretcher 292 class CPDF_QuickStretcher
293 { 293 {
294 public: 294 public:
295 CPDF_QuickStretcher(); 295 CPDF_QuickStretcher();
296 ~CPDF_QuickStretcher(); 296 ~CPDF_QuickStretcher();
297 FX_BOOL» » Start(CPDF_ImageObject* pImageObj, CFX_AffineMatrix* pIm age2Device, const FX_RECT* pClipBox); 297 bool» » Start(CPDF_ImageObject* pImageObj, CFX_AffineMatrix* pIm age2Device, const FX_RECT* pClipBox);
298 FX_BOOL» » Continue(IFX_Pause* pPause); 298 bool» » Continue(IFX_Pause* pPause);
299 CFX_DIBitmap* m_pBitmap; 299 CFX_DIBitmap* m_pBitmap;
300 int m_ResultLeft, m_ResultTop, m_ClipLeft, m_ClipTop; 300 int m_ResultLeft, m_ResultTop, m_ClipLeft, m_ClipTop;
301 int m_DestWidth, m_DestHeight, m_ResultWidth, m_ResultHeight ; 301 int m_DestWidth, m_DestHeight, m_ResultWidth, m_ResultHeight ;
302 int m_Bpp, m_SrcWidth, m_SrcHeight; 302 int m_Bpp, m_SrcWidth, m_SrcHeight;
303 FX_BOOL» » m_bFlipX, m_bFlipY; 303 bool» » m_bFlipX, m_bFlipY;
304 CPDF_ColorSpace* m_pCS; 304 CPDF_ColorSpace* m_pCS;
305 ICodec_ScanlineDecoder* m_pDecoder; 305 ICodec_ScanlineDecoder* m_pDecoder;
306 CPDF_StreamAcc m_StreamAcc; 306 CPDF_StreamAcc m_StreamAcc;
307 int m_LineIndex; 307 int m_LineIndex;
308 }; 308 };
309 class CPDF_DeviceBuffer 309 class CPDF_DeviceBuffer
310 { 310 {
311 public: 311 public:
312 CPDF_DeviceBuffer(); 312 CPDF_DeviceBuffer();
313 ~CPDF_DeviceBuffer(); 313 ~CPDF_DeviceBuffer();
314 FX_BOOL» » » » Initialize(CPDF_RenderContext* pContext, CFX_RenderDevice* pDevice, FX_RECT* pRect, 314 bool» » » » Initialize(CPDF_RenderContext* pContext, CFX_RenderDevice* pDevice, FX_RECT* pRect,
315 const CPDF_PageObject* pObj, int max_dpi = 0) ; 315 const CPDF_PageObject* pObj, int max_dpi = 0) ;
316 void OutputToDevice(); 316 void OutputToDevice();
317 CFX_DIBitmap* GetBitmap() const 317 CFX_DIBitmap* GetBitmap() const
318 { 318 {
319 return m_pBitmap; 319 return m_pBitmap;
320 } 320 }
321 const CFX_AffineMatrix* GetMatrix() const 321 const CFX_AffineMatrix* GetMatrix() const
322 { 322 {
323 return &m_Matrix; 323 return &m_Matrix;
324 } 324 }
325 private: 325 private:
326 CFX_RenderDevice* m_pDevice; 326 CFX_RenderDevice* m_pDevice;
327 CPDF_RenderContext* m_pContext; 327 CPDF_RenderContext* m_pContext;
328 FX_RECT m_Rect; 328 FX_RECT m_Rect;
329 const CPDF_PageObject* m_pObject; 329 const CPDF_PageObject* m_pObject;
330 CFX_DIBitmap* m_pBitmap; 330 CFX_DIBitmap* m_pBitmap;
331 CFX_AffineMatrix m_Matrix; 331 CFX_AffineMatrix m_Matrix;
332 }; 332 };
333 class CPDF_ImageCache 333 class CPDF_ImageCache
334 { 334 {
335 public: 335 public:
336 CPDF_ImageCache(CPDF_Document* pDoc, CPDF_Stream* pStream); 336 CPDF_ImageCache(CPDF_Document* pDoc, CPDF_Stream* pStream);
337 ~CPDF_ImageCache(); 337 ~CPDF_ImageCache();
338 void ClearImageData(); 338 void ClearImageData();
339 void Reset(const CFX_DIBitmap* pBitmap); 339 void Reset(const CFX_DIBitmap* pBitmap);
340 FX_BOOL» » » » GetCachedBitmap(CFX_DIBSource*& pBitmap, CFX_DIBSource*& pMask, FX_DWORD& MatteColor, CPDF_Dictionary* pPageResources, 340 bool» » » » GetCachedBitmap(CFX_DIBSource*& pBitmap, CFX_DIBSource*& pMask, FX_DWORD& MatteColor, CPDF_Dictionary* pPageResources,
341 FX_BOOL bStdCS = FALSE, FX_DWORD GroupFa mily = 0, FX_BOOL bLoadMask = FALSE, 341 bool bStdCS = false, FX_DWORD GroupFamil y = 0, bool bLoadMask = false,
342 CPDF_RenderStatus* pRenderStatus = NULL, int32_t downsampleWidth = 0, int32_t downsampleHeight = 0); 342 CPDF_RenderStatus* pRenderStatus = NULL, int32_t downsampleWidth = 0, int32_t downsampleHeight = 0);
343 FX_DWORD EstimateSize() const 343 FX_DWORD EstimateSize() const
344 { 344 {
345 return m_dwCacheSize; 345 return m_dwCacheSize;
346 } 346 }
347 FX_DWORD GetTimeCount() const 347 FX_DWORD GetTimeCount() const
348 { 348 {
349 return m_dwTimeCount; 349 return m_dwTimeCount;
350 } 350 }
351 CPDF_Stream* GetStream() const 351 CPDF_Stream* GetStream() const
352 { 352 {
353 return m_pStream; 353 return m_pStream;
354 } 354 }
355 void SetTimeCount(FX_DWORD dwTimeCount) 355 void SetTimeCount(FX_DWORD dwTimeCount)
356 { 356 {
357 m_dwTimeCount = dwTimeCount; 357 m_dwTimeCount = dwTimeCount;
358 } 358 }
359 int m_dwTimeCount; 359 int m_dwTimeCount;
360 public: 360 public:
361 int StartGetCachedBitmap(CPDF_Dictionary* pF ormResources, CPDF_Dictionary* pPageResources, 361 int StartGetCachedBitmap(CPDF_Dictionary* pF ormResources, CPDF_Dictionary* pPageResources,
362 FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, 362 bool bStdCS = false, FX_DWORD GroupFamily = 0,
363 FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatus = NULL, int32_t downsampleWidth = 0, int32_t downsampleHeight = 0); 363 bool bLoadMask = false, CPDF_RenderStatus* pRenderStatus = NULL, int 32_t downsampleWidth = 0, int32_t downsampleHeight = 0);
364 int Continue(IFX_Pause* pPause); 364 int Continue(IFX_Pause* pPause);
365 int ContinueGetCachedBitmap(); 365 int ContinueGetCachedBitmap();
366 CFX_DIBSource* DetachBitmap(); 366 CFX_DIBSource* DetachBitmap();
367 CFX_DIBSource* DetachMask(); 367 CFX_DIBSource* DetachMask();
368 CFX_DIBSource* m_pCurBitmap; 368 CFX_DIBSource* m_pCurBitmap;
369 CFX_DIBSource* m_pCurMask; 369 CFX_DIBSource* m_pCurMask;
370 FX_DWORD m_MatteColor; 370 FX_DWORD m_MatteColor;
371 CPDF_RenderStatus* m_pRenderStatus; 371 CPDF_RenderStatus* m_pRenderStatus;
372 protected: 372 protected:
373 CPDF_Document* m_pDocument; 373 CPDF_Document* m_pDocument;
374 CPDF_Stream* m_pStream; 374 CPDF_Stream* m_pStream;
375 CFX_DIBSource* m_pCachedBitmap; 375 CFX_DIBSource* m_pCachedBitmap;
376 CFX_DIBSource* m_pCachedMask; 376 CFX_DIBSource* m_pCachedMask;
377 FX_DWORD m_dwCacheSize; 377 FX_DWORD m_dwCacheSize;
378 void CalcSize(); 378 void CalcSize();
379 }; 379 };
380 typedef struct { 380 typedef struct {
381 FX_FLOAT m_DecodeMin; 381 FX_FLOAT m_DecodeMin;
382 FX_FLOAT m_DecodeStep; 382 FX_FLOAT m_DecodeStep;
383 int m_ColorKeyMin; 383 int m_ColorKeyMin;
384 int m_ColorKeyMax; 384 int m_ColorKeyMax;
385 } DIB_COMP_DATA; 385 } DIB_COMP_DATA;
386 class CPDF_DIBSource : public CFX_DIBSource 386 class CPDF_DIBSource : public CFX_DIBSource
387 { 387 {
388 public: 388 public:
389 CPDF_DIBSource(); 389 CPDF_DIBSource();
390 virtual ~CPDF_DIBSource(); 390 virtual ~CPDF_DIBSource();
391 FX_BOOL» » » » Load(CPDF_Document* pDoc, const CPDF_Str eam* pStream, 391 bool» » » » Load(CPDF_Document* pDoc, const CPDF_Str eam* pStream,
392 CPDF_DIBSource** ppMask, FX_DWORD* pMatteColor, 392 CPDF_DIBSource** ppMask, FX_DWORD* pMatteColor,
393 CPDF_Dictionary* pFormResources, CPDF_Dictionary* p PageResources, 393 CPDF_Dictionary* pFormResources, CPDF_Dictionary* p PageResources,
394 FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, F X_BOOL bLoadMask = FALSE); 394 bool bStdCS = false, FX_DWORD GroupFamily = 0, bool bLoadMask = false);
395 virtual FX_BOOL» » SkipToScanline(int line, IFX_Pause* pPause) cons t; 395 virtual bool» » SkipToScanline(int line, IFX_Pause* pPause) cons t;
396 virtual uint8_t* GetBuffer() const; 396 virtual uint8_t* GetBuffer() const;
397 virtual const uint8_t* GetScanline(int line) const; 397 virtual const uint8_t* GetScanline(int line) const;
398 virtual void DownSampleScanline(int line, uint8_t* dest_scan, int dest_bpp, 398 virtual void DownSampleScanline(int line, uint8_t* dest_scan, int dest_bpp,
399 int dest_width, FX_BOOL bFlipX, int c lip_left, int clip_width) const; 399 int dest_width, bool bFlipX, int clip _left, int clip_width) const;
400 virtual void SetDownSampleSize(int dest_width, int dest_heigh t) const; 400 virtual void SetDownSampleSize(int dest_width, int dest_heigh t) const;
401 CFX_DIBitmap* GetBitmap() const; 401 CFX_DIBitmap* GetBitmap() const;
402 void ReleaseBitmap(CFX_DIBitmap*) const; 402 void ReleaseBitmap(CFX_DIBitmap*) const;
403 void ClearImageData(); 403 void ClearImageData();
404 public: 404 public:
405 int»» » » » StartLoadDIBSource(CPDF_Document* pDoc, const CPDF_Stream* pStream, FX_BOOL bHasMask, 405 int»» » » » StartLoadDIBSource(CPDF_Document* pDoc, const CPDF_Stream* pStream, bool bHasMask,
406 CPDF_Dictionary* pFormResources, CPDF _Dictionary* pPageResources, 406 CPDF_Dictionary* pFormResources, CPDF _Dictionary* pPageResources,
407 FX_BOOL bStdCS = FALSE, FX_DWORD Grou pFamily = 0, FX_BOOL bLoadMask = FALSE); 407 bool bStdCS = false, FX_DWORD GroupFa mily = 0, bool bLoadMask = false);
408 int ContinueLoadDIBSource(IFX_Pause* pPause) ; 408 int ContinueLoadDIBSource(IFX_Pause* pPause) ;
409 int StratLoadMask(); 409 int StratLoadMask();
410 int StartLoadMaskDIB(); 410 int StartLoadMaskDIB();
411 int ContinueLoadMaskDIB(IFX_Pause* pPause); 411 int ContinueLoadMaskDIB(IFX_Pause* pPause);
412 int ContinueToLoadMask(); 412 int ContinueToLoadMask();
413 CPDF_DIBSource* DetachMask(); 413 CPDF_DIBSource* DetachMask();
414 CPDF_DIBSource* m_pMask; 414 CPDF_DIBSource* m_pMask;
415 FX_DWORD m_MatteColor; 415 FX_DWORD m_MatteColor;
416 void* m_pJbig2Context; 416 void* m_pJbig2Context;
417 CPDF_StreamAcc* m_pGlobalStream; 417 CPDF_StreamAcc* m_pGlobalStream;
418 FX_BOOL» » » » m_bStdCS; 418 bool» » » » m_bStdCS;
419 int m_Status; 419 int m_Status;
420 CPDF_Object* m_pMaskStream; 420 CPDF_Object* m_pMaskStream;
421 FX_BOOL» » » » m_bHasMask; 421 bool» » » » m_bHasMask;
422 protected: 422 protected:
423 FX_BOOL» » » » LoadColorInfo(CPDF_Dictionary* pFormReso urces, CPDF_Dictionary* pPageResources); 423 bool» » » » LoadColorInfo(CPDF_Dictionary* pFormReso urces, CPDF_Dictionary* pPageResources);
424 DIB_COMP_DATA* GetDecodeAndMaskArray(FX_BOOL& bDefaultDecode, FX_BOOL& bColorKey); 424 DIB_COMP_DATA* GetDecodeAndMaskArray(bool& bDefaultDecode, bool& bColor Key);
425 CPDF_DIBSource* LoadMask(FX_DWORD& MatteColor); 425 CPDF_DIBSource* LoadMask(FX_DWORD& MatteColor);
426 CPDF_DIBSource* LoadMaskDIB(CPDF_Stream* pMask); 426 CPDF_DIBSource* LoadMaskDIB(CPDF_Stream* pMask);
427 void LoadJpxBitmap(); 427 void LoadJpxBitmap();
428 void LoadPalette(); 428 void LoadPalette();
429 int CreateDecoder(); 429 int CreateDecoder();
430 void TranslateScanline24bpp(uint8_t* dest_sca n, const uint8_t* src_scan) const; 430 void TranslateScanline24bpp(uint8_t* dest_sca n, const uint8_t* src_scan) const;
431 void ValidateDictParam(); 431 void ValidateDictParam();
432 CPDF_Document* m_pDocument; 432 CPDF_Document* m_pDocument;
433 const CPDF_Stream* m_pStream; 433 const CPDF_Stream* m_pStream;
434 CPDF_StreamAcc* m_pStreamAcc; 434 CPDF_StreamAcc* m_pStreamAcc;
435 const CPDF_Dictionary* m_pDict; 435 const CPDF_Dictionary* m_pDict;
436 CPDF_ColorSpace* m_pColorSpace; 436 CPDF_ColorSpace* m_pColorSpace;
437 FX_DWORD m_Family; 437 FX_DWORD m_Family;
438 FX_DWORD m_bpc; 438 FX_DWORD m_bpc;
439 FX_DWORD m_bpc_orig; 439 FX_DWORD m_bpc_orig;
440 FX_DWORD m_nComponents; 440 FX_DWORD m_nComponents;
441 FX_DWORD m_GroupFamily; 441 FX_DWORD m_GroupFamily;
442 FX_BOOL» » » » m_bLoadMask; 442 bool» » » » m_bLoadMask;
443 FX_BOOL» » » » m_bDefaultDecode; 443 bool» » » » m_bDefaultDecode;
444 FX_BOOL» » » » m_bImageMask; 444 bool» » » » m_bImageMask;
445 FX_BOOL» » » » m_bDoBpcCheck; 445 bool» » » » m_bDoBpcCheck;
446 FX_BOOL» » » » m_bColorKey; 446 bool» » » » m_bColorKey;
447 DIB_COMP_DATA* m_pCompData; 447 DIB_COMP_DATA* m_pCompData;
448 uint8_t* m_pLineBuf; 448 uint8_t* m_pLineBuf;
449 uint8_t* m_pMaskedLine; 449 uint8_t* m_pMaskedLine;
450 nonstd::unique_ptr<CFX_DIBitmap> m_pCachedBitmap; 450 nonstd::unique_ptr<CFX_DIBitmap> m_pCachedBitmap;
451 ICodec_ScanlineDecoder* m_pDecoder; 451 ICodec_ScanlineDecoder* m_pDecoder;
452 }; 452 };
453 #define FPDF_HUGE_IMAGE_SIZE 60000000 453 #define FPDF_HUGE_IMAGE_SIZE 60000000
454 class CPDF_DIBTransferFunc : public CFX_FilteredDIB 454 class CPDF_DIBTransferFunc : public CFX_FilteredDIB
455 { 455 {
456 public: 456 public:
457 CPDF_DIBTransferFunc(const CPDF_TransferFunc* pTransferFunc); 457 CPDF_DIBTransferFunc(const CPDF_TransferFunc* pTransferFunc);
458 virtual FXDIB_Format GetDestFormat(); 458 virtual FXDIB_Format GetDestFormat();
459 virtual FX_ARGB* GetDestPalette() 459 virtual FX_ARGB* GetDestPalette()
460 { 460 {
461 return NULL; 461 return NULL;
462 } 462 }
463 virtual void TranslateScanline(uint8_t* dest_buf, con st uint8_t* src_buf) const; 463 virtual void TranslateScanline(uint8_t* dest_buf, con st uint8_t* src_buf) const;
464 virtual void TranslateDownSamples(uint8_t* dest_buf, const uint8_t* src_buf, int pixels, int Bpp) const; 464 virtual void TranslateDownSamples(uint8_t* dest_buf, const uint8_t* src_buf, int pixels, int Bpp) const;
465 const uint8_t* m_RampR; 465 const uint8_t* m_RampR;
466 const uint8_t* m_RampG; 466 const uint8_t* m_RampG;
467 const uint8_t* m_RampB; 467 const uint8_t* m_RampB;
468 }; 468 };
469 struct _CPDF_UniqueKeyGen { 469 struct _CPDF_UniqueKeyGen {
470 void Generate(int count, ...); 470 void Generate(int count, ...);
471 FX_CHAR m_Key[128]; 471 FX_CHAR m_Key[128];
472 int m_KeyLen; 472 int m_KeyLen;
473 }; 473 };
474 474
475 #endif // CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_ 475 #endif // CORE_SRC_FPDFAPI_FPDF_RENDER_RENDER_INT_H_
OLDNEW
« no previous file with comments | « core/src/fpdfapi/fpdf_render/fpdf_render_text.cpp ('k') | core/src/fpdfdoc/doc_action.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698