OLD | NEW |
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_FXGE_CFX_PATHDATA_H_ | 7 #ifndef CORE_FXGE_CFX_PATHDATA_H_ |
8 #define CORE_FXGE_CFX_PATHDATA_H_ | 8 #define CORE_FXGE_CFX_PATHDATA_H_ |
9 | 9 |
10 #include "core/fxcrt/fx_coordinates.h" | 10 #include "core/fxcrt/fx_coordinates.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 FX_FLOAT GetPointX(int index) const { return m_pPoints[index].m_PointX; } | 28 FX_FLOAT GetPointX(int index) const { return m_pPoints[index].m_PointX; } |
29 FX_FLOAT GetPointY(int index) const { return m_pPoints[index].m_PointY; } | 29 FX_FLOAT GetPointY(int index) const { return m_pPoints[index].m_PointY; } |
30 FX_PATHPOINT* GetPoints() const { return m_pPoints; } | 30 FX_PATHPOINT* GetPoints() const { return m_pPoints; } |
31 | 31 |
32 void SetPointCount(int nPoints); | 32 void SetPointCount(int nPoints); |
33 void AllocPointCount(int nPoints); | 33 void AllocPointCount(int nPoints); |
34 void AddPointCount(int addPoints); | 34 void AddPointCount(int addPoints); |
35 CFX_FloatRect GetBoundingBox() const; | 35 CFX_FloatRect GetBoundingBox() const; |
36 CFX_FloatRect GetBoundingBox(FX_FLOAT line_width, FX_FLOAT miter_limit) const; | 36 CFX_FloatRect GetBoundingBox(FX_FLOAT line_width, FX_FLOAT miter_limit) const; |
37 void Transform(const CFX_Matrix* pMatrix); | 37 void Transform(const CFX_Matrix* pMatrix); |
38 FX_BOOL IsRect() const; | 38 bool IsRect() const; |
39 FX_BOOL GetZeroAreaPath(CFX_PathData& NewPath, | 39 bool GetZeroAreaPath(CFX_PathData& NewPath, |
40 CFX_Matrix* pMatrix, | 40 CFX_Matrix* pMatrix, |
41 FX_BOOL& bThin, | 41 bool& bThin, |
42 FX_BOOL bAdjust) const; | 42 bool bAdjust) const; |
43 FX_BOOL IsRect(const CFX_Matrix* pMatrix, CFX_FloatRect* rect) const; | 43 bool IsRect(const CFX_Matrix* pMatrix, CFX_FloatRect* rect) const; |
44 void Append(const CFX_PathData* pSrc, const CFX_Matrix* pMatrix); | 44 void Append(const CFX_PathData* pSrc, const CFX_Matrix* pMatrix); |
45 void AppendRect(FX_FLOAT left, FX_FLOAT bottom, FX_FLOAT right, FX_FLOAT top); | 45 void AppendRect(FX_FLOAT left, FX_FLOAT bottom, FX_FLOAT right, FX_FLOAT top); |
46 void SetPoint(int index, FX_FLOAT x, FX_FLOAT y, int flag); | 46 void SetPoint(int index, FX_FLOAT x, FX_FLOAT y, int flag); |
47 void TrimPoints(int nPoints); | 47 void TrimPoints(int nPoints); |
48 void Copy(const CFX_PathData& src); | 48 void Copy(const CFX_PathData& src); |
49 | 49 |
50 private: | 50 private: |
51 int m_PointCount; | 51 int m_PointCount; |
52 int m_AllocCount; | 52 int m_AllocCount; |
53 FX_PATHPOINT* m_pPoints; | 53 FX_PATHPOINT* m_pPoints; |
54 }; | 54 }; |
55 | 55 |
56 #endif // CORE_FXGE_CFX_PATHDATA_H_ | 56 #endif // CORE_FXGE_CFX_PATHDATA_H_ |
OLD | NEW |