Index: core/fpdfapi/fpdf_page/cpdf_meshstream.h |
diff --git a/core/fpdfapi/fpdf_page/cpdf_meshstream.h b/core/fpdfapi/fpdf_page/cpdf_meshstream.h |
index 462dcf09c75e0da0a731918f1551acecf2bf52a0..e5d37fe36b1c25075a15669ad47a562dff0b787e 100644 |
--- a/core/fpdfapi/fpdf_page/cpdf_meshstream.h |
+++ b/core/fpdfapi/fpdf_page/cpdf_meshstream.h |
@@ -7,6 +7,9 @@ |
#ifndef CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_ |
#define CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_ |
+#include <memory> |
+#include <vector> |
+ |
#include "core/fpdfapi/fpdf_parser/include/cpdf_stream_acc.h" |
#include "core/fxcrt/include/fx_basic.h" |
#include "core/fxcrt/include/fx_system.h" |
@@ -26,11 +29,10 @@ class CPDF_Stream; |
class CPDF_MeshStream { |
public: |
- FX_BOOL Load(CPDF_Stream* pShadingStream, |
- CPDF_Function** pFuncs, |
- int nFuncs, |
- CPDF_ColorSpace* pCS); |
+ CPDF_MeshStream(const std::vector<std::unique_ptr<CPDF_Function>>& funcs, |
+ CPDF_ColorSpace* pCS); |
+ bool Load(CPDF_Stream* pShadingStream); |
uint32_t GetFlag(); |
void GetCoords(FX_FLOAT& x, FX_FLOAT& y); |
@@ -41,9 +43,15 @@ class CPDF_MeshStream { |
int count, |
CFX_Matrix* pObject2Bitmap); |
- CPDF_Function** m_pFuncs; |
- CPDF_ColorSpace* m_pCS; |
- uint32_t m_nFuncs; |
+ CFX_BitStream* BitStream() { return &m_BitStream; } |
+ uint32_t CoordBits() const { return m_nCoordBits; } |
+ uint32_t CompBits() const { return m_nCompBits; } |
+ uint32_t FlagBits() const { return m_nFlagBits; } |
+ uint32_t comps() const { return m_nComps; } |
+ |
+ private: |
+ const std::vector<std::unique_ptr<CPDF_Function>>& m_funcs; |
+ CPDF_ColorSpace* const m_pCS; |
uint32_t m_nCoordBits; |
uint32_t m_nCompBits; |
uint32_t m_nFlagBits; |