diff options
author | Dan Sinclair <dsinclair@chromium.org> | 2017-03-21 15:59:13 -0400 |
---|---|---|
committer | Chromium commit bot <commit-bot@chromium.org> | 2017-03-21 22:10:47 +0000 |
commit | 7dd72a3f39c09a7fdc34558061831620bc149420 (patch) | |
tree | 35deeb8f5d8a63c7644ad133135c06bba65a923c /core/fxcrt/fx_basic.h | |
parent | 72a39ceb264156446f91fcdc6522ea0c05e4eaae (diff) | |
download | pdfium-7dd72a3f39c09a7fdc34558061831620bc149420.tar.xz |
Move colorspace specific code to colorspace class
This Cl moves the Matrix and Vector code which is only used by the
colorspace code into the colorspace cpp file.
Change-Id: Ie37bcee0978278a56d345e63704494b5b67e5b24
Reviewed-on: https://pdfium-review.googlesource.com/3137
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'core/fxcrt/fx_basic.h')
-rw-r--r-- | core/fxcrt/fx_basic.h | 61 |
1 files changed, 2 insertions, 59 deletions
diff --git a/core/fxcrt/fx_basic.h b/core/fxcrt/fx_basic.h index ee630e100d..076766a0a2 100644 --- a/core/fxcrt/fx_basic.h +++ b/core/fxcrt/fx_basic.h @@ -338,18 +338,12 @@ class CFX_BitStream { public: void Init(const uint8_t* pData, uint32_t dwSize); - uint32_t GetBits(uint32_t nBits); - void ByteAlign(); - - bool IsEOF() { return m_BitPos >= m_BitSize; } - + bool IsEOF() const { return m_BitPos >= m_BitSize; } + uint32_t GetBits(uint32_t nBits); void SkipBits(uint32_t nBits) { m_BitPos += nBits; } - void Rewind() { m_BitPos = 0; } - uint32_t GetPos() const { return m_BitPos; } - uint32_t BitsRemaining() const { return m_BitSize >= m_BitPos ? m_BitSize - m_BitPos : 0; } @@ -378,57 +372,6 @@ class CFX_AutoRestorer { const T m_OldValue; }; -class CFX_Vector_3by1 { - public: - CFX_Vector_3by1() : a(0.0f), b(0.0f), c(0.0f) {} - - CFX_Vector_3by1(float a1, float b1, float c1) : a(a1), b(b1), c(c1) {} - - float a; - float b; - float c; -}; -class CFX_Matrix_3by3 { - public: - CFX_Matrix_3by3() - : a(0.0f), - b(0.0f), - c(0.0f), - d(0.0f), - e(0.0f), - f(0.0f), - g(0.0f), - h(0.0f), - i(0.0f) {} - - CFX_Matrix_3by3(float a1, - float b1, - float c1, - float d1, - float e1, - float f1, - float g1, - float h1, - float i1) - : a(a1), b(b1), c(c1), d(d1), e(e1), f(f1), g(g1), h(h1), i(i1) {} - - CFX_Matrix_3by3 Inverse(); - - CFX_Matrix_3by3 Multiply(const CFX_Matrix_3by3& m); - - CFX_Vector_3by1 TransformVector(const CFX_Vector_3by1& v); - - float a; - float b; - float c; - float d; - float e; - float f; - float g; - float h; - float i; -}; - uint32_t GetBits32(const uint8_t* pData, int bitpos, int nbits); #endif // CORE_FXCRT_FX_BASIC_H_ |