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

Side by Side Diff: core/include/fpdfapi/fpdf_resource.h

Issue 1418623011: Give names to the shading types (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 5 years, 1 month 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
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_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_ 7 #ifndef CORE_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_
8 #define CORE_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_ 8 #define CORE_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_
9 9
10 #include "../fxcrt/fx_system.h" 10 #include "../fxcrt/fx_system.h"
(...skipping 661 matching lines...) Expand 10 before | Expand all | Expand 10 after
672 FX_BOOL m_bColored; 672 FX_BOOL m_bColored;
673 673
674 CFX_FloatRect m_BBox; 674 CFX_FloatRect m_BBox;
675 675
676 FX_FLOAT m_XStep; 676 FX_FLOAT m_XStep;
677 677
678 FX_FLOAT m_YStep; 678 FX_FLOAT m_YStep;
679 679
680 CPDF_Form* m_pForm; 680 CPDF_Form* m_pForm;
681 }; 681 };
682
683 typedef enum {
684 kInvalidShading = 0,
685 kFunctionBasedShading = 1,
686 kAxialShading = 2,
687 kRadialShading = 3,
688 kFreeFormGouraudTriangleMeshShading = 4,
689 kLatticeFormGouraudTriangleMeshShading = 5,
690 kCoonsPatchMeshShading = 6,
691 kTensorProductPatchMeshShading = 7,
692 kMaxShading = 8
693 } ShadingType;
694
682 class CPDF_ShadingPattern : public CPDF_Pattern { 695 class CPDF_ShadingPattern : public CPDF_Pattern {
683 public: 696 public:
684 CPDF_ShadingPattern(CPDF_Document* pDoc, 697 CPDF_ShadingPattern(CPDF_Document* pDoc,
685 CPDF_Object* pPatternObj, 698 CPDF_Object* pPatternObj,
686 FX_BOOL bShading, 699 FX_BOOL bShading,
687 const CFX_AffineMatrix* parentMatrix); 700 const CFX_AffineMatrix* parentMatrix);
688 701
689 ~CPDF_ShadingPattern() override; 702 ~CPDF_ShadingPattern() override;
690 703
691 CPDF_Object* m_pShadingObj; 704 CPDF_Object* m_pShadingObj;
692 705
693 FX_BOOL m_bShadingObj; 706 FX_BOOL m_bShadingObj;
694 707
695 FX_BOOL Load(); 708 FX_BOOL Load();
696 709
697 FX_BOOL Reload(); 710 FX_BOOL Reload();
698 711
699 int m_ShadingType; 712 ShadingType m_ShadingType;
700 713
701 CPDF_ColorSpace* m_pCS; // Still keep m_pCS as some CPDF_ColorSpace (name 714 CPDF_ColorSpace* m_pCS; // Still keep m_pCS as some CPDF_ColorSpace (name
702 // object) are not managed as counted objects. Refer 715 // object) are not managed as counted objects. Refer
703 // to CPDF_DocPageData::GetColorSpace. 716 // to CPDF_DocPageData::GetColorSpace.
704 717
705 CPDF_CountedColorSpace* m_pCountedCS; 718 CPDF_CountedColorSpace* m_pCountedCS;
706 719
707 CPDF_Function* m_pFunctions[4]; 720 CPDF_Function* m_pFunctions[4];
708 721
709 int m_nFuncs; 722 int m_nFuncs;
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
834 847
835 FX_BOOL m_bInterpolate; 848 FX_BOOL m_bInterpolate;
836 849
837 CPDF_Document* m_pDocument; 850 CPDF_Document* m_pDocument;
838 851
839 CPDF_Dictionary* m_pOC; 852 CPDF_Dictionary* m_pOC;
840 CPDF_Dictionary* InitJPEG(uint8_t* pData, FX_DWORD size); 853 CPDF_Dictionary* InitJPEG(uint8_t* pData, FX_DWORD size);
841 }; 854 };
842 855
843 #endif // CORE_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_ 856 #endif // CORE_INCLUDE_FPDFAPI_FPDF_RESOURCE_H_
OLDNEW
« no previous file with comments | « no previous file | core/src/fpdfapi/fpdf_page/fpdf_page_parser.cpp » ('j') | core/src/fpdfapi/fpdf_page/fpdf_page_pattern.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698