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_FPDFAPI_FPDF_RENDER_H_ | 7 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_ |
8 #define CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_ | 8 #define CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_ |
9 | 9 |
10 #include "../fxge/fx_ge.h" | 10 #include "../fxge/fx_ge.h" |
(...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
234 m_pCurImageCaches = NULL; | 234 m_pCurImageCaches = NULL; |
235 } | 235 } |
236 ~CPDF_PageRenderCache() | 236 ~CPDF_PageRenderCache() |
237 { | 237 { |
238 ClearAll(); | 238 ClearAll(); |
239 } | 239 } |
240 void ClearAll(); | 240 void ClearAll(); |
241 void ClearImageData(); | 241 void ClearImageData(); |
242 | 242 |
243 FX_DWORD EstimateSize(); | 243 FX_DWORD EstimateSize(); |
244 void» » » » CacheOptimization(FX_INT32 dwLimitCacheS
ize); | 244 void» » » » CacheOptimization(int32_t dwLimitCacheSi
ze); |
245 FX_DWORD GetCachedSize(CPDF_Stream* pStream) const; | 245 FX_DWORD GetCachedSize(CPDF_Stream* pStream) const; |
246 FX_DWORD GetTimeCount() const | 246 FX_DWORD GetTimeCount() const |
247 { | 247 { |
248 return m_nTimeCount; | 248 return m_nTimeCount; |
249 } | 249 } |
250 void SetTimeCount(FX_DWORD dwTimeCount) | 250 void SetTimeCount(FX_DWORD dwTimeCount) |
251 { | 251 { |
252 m_nTimeCount = dwTimeCount; | 252 m_nTimeCount = dwTimeCount; |
253 } | 253 } |
254 | 254 |
255 void GetCachedBitmap(CPDF_Stream* pStream, CF
X_DIBSource*& pBitmap, CFX_DIBSource*& pMask, FX_DWORD& MatteColor, | 255 void GetCachedBitmap(CPDF_Stream* pStream, CF
X_DIBSource*& pBitmap, CFX_DIBSource*& pMask, FX_DWORD& MatteColor, |
256 FX_BOOL bStdCS = FALSE, FX_DWORD GroupFa
mily = 0, FX_BOOL bLoadMask = FALSE, | 256 FX_BOOL bStdCS = FALSE, FX_DWORD GroupFa
mily = 0, FX_BOOL bLoadMask = FALSE, |
257 CPDF_RenderStatus* pRenderStatus = NULL,
FX_INT32 downsampleWidth = 0, FX_INT32 downsampleHeight = 0); | 257 CPDF_RenderStatus* pRenderStatus = NULL,
int32_t downsampleWidth = 0, int32_t downsampleHeight = 0); |
258 | 258 |
259 void ResetBitmap(CPDF_Stream* pStream, const
CFX_DIBitmap* pBitmap); | 259 void ResetBitmap(CPDF_Stream* pStream, const
CFX_DIBitmap* pBitmap); |
260 void ClearImageCache(CPDF_Stream* pStream); | 260 void ClearImageCache(CPDF_Stream* pStream); |
261 CPDF_Page* GetPage() | 261 CPDF_Page* GetPage() |
262 { | 262 { |
263 return m_pPage; | 263 return m_pPage; |
264 } | 264 } |
265 CFX_MapPtrToPtr m_ImageCaches; | 265 CFX_MapPtrToPtr m_ImageCaches; |
266 public: | 266 public: |
267 FX_BOOL StartGetCachedBitmap(CPDF_Stream* pStrea
m, FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, | 267 FX_BOOL StartGetCachedBitmap(CPDF_Stream* pStrea
m, FX_BOOL bStdCS = FALSE, FX_DWORD GroupFamily = 0, |
268 FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatus = NULL, | 268 FX_BOOL bLoadMask = FALSE, CPDF_RenderStatus* pRenderStatus = NULL, |
269 FX_INT32 downsampleWidth = 0, FX_INT32 downsampleHeight = 0); | 269 int32_t downsampleWidth = 0, int32_t downsampleHeight = 0); |
270 | 270 |
271 FX_BOOL Continue(IFX_Pause* pPause); | 271 FX_BOOL Continue(IFX_Pause* pPause); |
272 CPDF_ImageCache* m_pCurImageCache; | 272 CPDF_ImageCache* m_pCurImageCache; |
273 CFX_PtrArray* m_pCurImageCaches; | 273 CFX_PtrArray* m_pCurImageCaches; |
274 protected: | 274 protected: |
275 friend class CPDF_Page; | 275 friend class CPDF_Page; |
276 CPDF_Page* m_pPage; | 276 CPDF_Page* m_pPage; |
277 | 277 |
278 FX_DWORD m_nTimeCount; | 278 FX_DWORD m_nTimeCount; |
279 FX_DWORD m_nCacheSize; | 279 FX_DWORD m_nCacheSize; |
280 FX_BOOL m_bCurFindCache; | 280 FX_BOOL m_bCurFindCache; |
281 }; | 281 }; |
282 class CPDF_RenderConfig | 282 class CPDF_RenderConfig |
283 { | 283 { |
284 public: | 284 public: |
285 CPDF_RenderConfig(); | 285 CPDF_RenderConfig(); |
286 ~CPDF_RenderConfig(); | 286 ~CPDF_RenderConfig(); |
287 int m_HalftoneLimit; | 287 int m_HalftoneLimit; |
288 int m_RenderStepLimit; | 288 int m_RenderStepLimit; |
289 }; | 289 }; |
290 | 290 |
291 #endif // CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_ | 291 #endif // CORE_INCLUDE_FPDFAPI_FPDF_RENDER_H_ |
OLD | NEW |