summaryrefslogtreecommitdiff
path: root/core/fpdfapi/render
diff options
context:
space:
mode:
Diffstat (limited to 'core/fpdfapi/render')
-rw-r--r--core/fpdfapi/render/cpdf_transferfunc.cpp8
-rw-r--r--core/fpdfapi/render/cpdf_transferfunc.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/core/fpdfapi/render/cpdf_transferfunc.cpp b/core/fpdfapi/render/cpdf_transferfunc.cpp
index c28afde0d9..25717437d3 100644
--- a/core/fpdfapi/render/cpdf_transferfunc.cpp
+++ b/core/fpdfapi/render/cpdf_transferfunc.cpp
@@ -14,10 +14,10 @@ CPDF_TransferFunc::CPDF_TransferFunc(CPDF_Document* pDoc) : m_pPDFDoc(pDoc) {}
CPDF_TransferFunc::~CPDF_TransferFunc() {}
-FX_COLORREF CPDF_TransferFunc::TranslateColor(FX_COLORREF bgr) const {
- return FXSYS_RGB(m_Samples[FXSYS_GetRValue(bgr)],
- m_Samples[256 + FXSYS_GetGValue(bgr)],
- m_Samples[512 + FXSYS_GetBValue(bgr)]);
+FX_COLORREF CPDF_TransferFunc::TranslateColor(FX_COLORREF colorref) const {
+ return FXSYS_BGR(m_Samples[512 + FXSYS_GetBValue(colorref)],
+ m_Samples[256 + FXSYS_GetGValue(colorref)],
+ m_Samples[FXSYS_GetRValue(colorref)]);
}
RetainPtr<CFX_DIBSource> CPDF_TransferFunc::TranslateImage(
diff --git a/core/fpdfapi/render/cpdf_transferfunc.h b/core/fpdfapi/render/cpdf_transferfunc.h
index de95a439c3..dfc186ec6c 100644
--- a/core/fpdfapi/render/cpdf_transferfunc.h
+++ b/core/fpdfapi/render/cpdf_transferfunc.h
@@ -19,7 +19,7 @@ class CPDF_TransferFunc : public Retainable {
template <typename T, typename... Args>
friend RetainPtr<T> pdfium::MakeRetain(Args&&... args);
- FX_COLORREF TranslateColor(FX_COLORREF bgr) const;
+ FX_COLORREF TranslateColor(FX_COLORREF colorref) const;
RetainPtr<CFX_DIBSource> TranslateImage(const RetainPtr<CFX_DIBSource>& pSrc);
const CPDF_Document* GetDocument() const { return m_pPDFDoc.Get(); }