summaryrefslogtreecommitdiff
path: root/core/fpdfapi/page/pageint.h
diff options
context:
space:
mode:
authorLei Zhang <thestig@chromium.org>2017-03-15 13:26:37 -0700
committerChromium commit bot <commit-bot@chromium.org>2017-03-15 21:10:29 +0000
commita12159b17085796e2b72d2b49e850092e0b4e8b7 (patch)
treedf7a5d149c9bbfe5c2d2ec16631c3dcb6ae9a901 /core/fpdfapi/page/pageint.h
parent59d9416553b293f6df923c2f3ef33def2d51d7b7 (diff)
downloadpdfium-a12159b17085796e2b72d2b49e850092e0b4e8b7.tar.xz
Refactor some CPDF_ColorSpace code.
Change-Id: I1e30d68dae3bf70cf3c426f6126d593b7f1c3ba4 Reviewed-on: https://pdfium-review.googlesource.com/2991 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: Nicolás Peña <npm@chromium.org>
Diffstat (limited to 'core/fpdfapi/page/pageint.h')
-rw-r--r--core/fpdfapi/page/pageint.h21
1 files changed, 13 insertions, 8 deletions
diff --git a/core/fpdfapi/page/pageint.h b/core/fpdfapi/page/pageint.h
index 88e9c15ff2..0737c2ed6e 100644
--- a/core/fpdfapi/page/pageint.h
+++ b/core/fpdfapi/page/pageint.h
@@ -33,10 +33,11 @@ class CPDF_Function {
static Type IntegerToFunctionType(int iType);
virtual ~CPDF_Function();
+
bool Call(float* inputs,
uint32_t ninputs,
float* results,
- int& nresults) const;
+ int* nresults) const;
uint32_t CountInputs() const { return m_nInputs; }
uint32_t CountOutputs() const { return m_nOutputs; }
float GetDomain(int i) const { return m_pDomains[i]; }
@@ -148,14 +149,16 @@ class CPDF_IccProfile {
class CPDF_DeviceCS : public CPDF_ColorSpace {
public:
CPDF_DeviceCS(CPDF_Document* pDoc, int family);
+ ~CPDF_DeviceCS() override;
- bool GetRGB(float* pBuf, float& R, float& G, float& B) const override;
+ // CPDF_ColorSpace:
+ bool GetRGB(float* pBuf, float* R, float* G, float* B) const override;
bool SetRGB(float* pBuf, float R, float G, float B) const override;
bool v_GetCMYK(float* pBuf,
- float& c,
- float& m,
- float& y,
- float& k) const override;
+ float* c,
+ float* m,
+ float* y,
+ float* k) const override;
bool v_SetCMYK(float* pBuf,
float c,
float m,
@@ -166,15 +169,17 @@ class CPDF_DeviceCS : public CPDF_ColorSpace {
int pixels,
int image_width,
int image_height,
- bool bTransMask = false) const override;
+ bool bTransMask) const override;
};
class CPDF_PatternCS : public CPDF_ColorSpace {
public:
explicit CPDF_PatternCS(CPDF_Document* pDoc);
~CPDF_PatternCS() override;
+
+ // CPDF_ColorSpace:
bool v_Load(CPDF_Document* pDoc, CPDF_Array* pArray) override;
- bool GetRGB(float* pBuf, float& R, float& G, float& B) const override;
+ bool GetRGB(float* pBuf, float* R, float* G, float* B) const override;
CPDF_ColorSpace* GetBaseCS() const override;
private: