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

Side by Side Diff: core/fpdfapi/fpdf_page/cpdf_meshstream.h

Issue 2027053002: Relax checks added in commit 8f3a311. (Closed) Base URL: https://pdfium.googlesource.com/pdfium@bug_616248
Patch Set: components Created 4 years, 6 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 | « no previous file | core/fpdfapi/fpdf_page/cpdf_meshstream.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 2016 PDFium Authors. All rights reserved. 1 // Copyright 2016 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_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_ 7 #ifndef CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_
8 #define CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_ 8 #define CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_
9 9
10 #include <memory> 10 #include <memory>
(...skipping 29 matching lines...) Expand all
40 uint32_t GetFlag(); 40 uint32_t GetFlag();
41 void GetCoords(FX_FLOAT& x, FX_FLOAT& y); 41 void GetCoords(FX_FLOAT& x, FX_FLOAT& y);
42 void GetColor(FX_FLOAT& r, FX_FLOAT& g, FX_FLOAT& b); 42 void GetColor(FX_FLOAT& r, FX_FLOAT& g, FX_FLOAT& b);
43 43
44 uint32_t GetVertex(CPDF_MeshVertex& vertex, CFX_Matrix* pObject2Bitmap); 44 uint32_t GetVertex(CPDF_MeshVertex& vertex, CFX_Matrix* pObject2Bitmap);
45 FX_BOOL GetVertexRow(CPDF_MeshVertex* vertex, 45 FX_BOOL GetVertexRow(CPDF_MeshVertex* vertex,
46 int count, 46 int count,
47 CFX_Matrix* pObject2Bitmap); 47 CFX_Matrix* pObject2Bitmap);
48 48
49 CFX_BitStream* BitStream() { return &m_BitStream; } 49 CFX_BitStream* BitStream() { return &m_BitStream; }
50 uint32_t CompBits() const { return m_nCompBits; } 50 uint32_t ComponentBits() const { return m_nComponentBits; }
51 uint32_t comps() const { return m_nComps; } 51 uint32_t Components() const { return m_nComponents; }
52 52
53 private: 53 private:
54 static const uint32_t kMaxResults = 8; 54 static const uint32_t kMaxComponents = 8;
55 55
56 const ShadingType m_type; 56 const ShadingType m_type;
57 const std::vector<std::unique_ptr<CPDF_Function>>& m_funcs; 57 const std::vector<std::unique_ptr<CPDF_Function>>& m_funcs;
58 CPDF_Stream* const m_pShadingStream; 58 CPDF_Stream* const m_pShadingStream;
59 CPDF_ColorSpace* const m_pCS; 59 CPDF_ColorSpace* const m_pCS;
60 uint32_t m_nCoordBits; 60 uint32_t m_nCoordBits;
61 uint32_t m_nCompBits; 61 uint32_t m_nComponentBits;
62 uint32_t m_nFlagBits; 62 uint32_t m_nFlagBits;
63 uint32_t m_nComps; 63 uint32_t m_nComponents;
64 uint32_t m_CoordMax; 64 uint32_t m_CoordMax;
65 uint32_t m_CompMax; 65 uint32_t m_ComponentMax;
66 FX_FLOAT m_xmin; 66 FX_FLOAT m_xmin;
67 FX_FLOAT m_xmax; 67 FX_FLOAT m_xmax;
68 FX_FLOAT m_ymin; 68 FX_FLOAT m_ymin;
69 FX_FLOAT m_ymax; 69 FX_FLOAT m_ymax;
70 FX_FLOAT m_ColorMin[kMaxResults]; 70 FX_FLOAT m_ColorMin[kMaxComponents];
71 FX_FLOAT m_ColorMax[kMaxResults]; 71 FX_FLOAT m_ColorMax[kMaxComponents];
72 CPDF_StreamAcc m_Stream; 72 CPDF_StreamAcc m_Stream;
73 CFX_BitStream m_BitStream; 73 CFX_BitStream m_BitStream;
74 }; 74 };
75 75
76 #endif // CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_ 76 #endif // CORE_FPDFAPI_FPDF_PAGE_CPDF_MESHSTREAM_H_
OLDNEW
« no previous file with comments | « no previous file | core/fpdfapi/fpdf_page/cpdf_meshstream.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698