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

Unified Diff: core/fpdfapi/fpdf_page/pageint.h

Issue 1870463002: flesh out gradient shaders (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: fix linux-detected error Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: core/fpdfapi/fpdf_page/pageint.h
diff --git a/core/fpdfapi/fpdf_page/pageint.h b/core/fpdfapi/fpdf_page/pageint.h
index e6496cfd20abbd6b56253e8d229a21287a0cd476..98a05d5495035c3a5b664108ac5f81deb5229c79 100644
--- a/core/fpdfapi/fpdf_page/pageint.h
+++ b/core/fpdfapi/fpdf_page/pageint.h
@@ -393,6 +393,7 @@ class CPDF_Function {
uint32_t CountInputs() const { return m_nInputs; }
uint32_t CountOutputs() const { return m_nOutputs; }
FX_FLOAT GetDomain(int i) const { return m_pDomains[i]; }
+ FX_FLOAT GetRange(int i) const { return m_pRanges[i]; }
Type GetType() const { return m_Type; }
protected:
@@ -423,6 +424,33 @@ class CPDF_ExpIntFunc : public CPDF_Function {
FX_FLOAT* m_pEndValues;
};
+class CPDF_SampledFunc : public CPDF_Function {
+ public:
+ struct SampleEncodeInfo {
+ FX_FLOAT encode_max;
+ FX_FLOAT encode_min;
+ uint32_t sizes;
+ };
+
+ struct SampleDecodeInfo {
+ FX_FLOAT decode_max;
+ FX_FLOAT decode_min;
+ };
+
+ CPDF_SampledFunc();
+ ~CPDF_SampledFunc() override;
+
+ // CPDF_Function
+ FX_BOOL v_Init(CPDF_Object* pObj) override;
+ FX_BOOL v_Call(FX_FLOAT* inputs, FX_FLOAT* results) const override;
+
+ SampleEncodeInfo* m_pEncodeInfo;
+ SampleDecodeInfo* m_pDecodeInfo;
+ uint32_t m_nBitsPerSample;
+ uint32_t m_SampleMax;
+ CPDF_StreamAcc* m_pSampleStream;
+};
+
class CPDF_StitchFunc : public CPDF_Function {
public:
CPDF_StitchFunc();

Powered by Google App Engine
This is Rietveld 408576698