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

Side by Side Diff: core/src/fpdfapi/fpdf_page/fpdf_page_colors.cpp

Issue 1776913007: Split fpdf_parser_objects.cpp into per-class .cpp/.h files. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Address comments Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « core/src/fpdfapi/fpdf_page/fpdf_page.cpp ('k') | core/src/fpdfapi/fpdf_page/fpdf_page_doc.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 #include "core/src/fpdfapi/fpdf_page/pageint.h" 7 #include "core/src/fpdfapi/fpdf_page/pageint.h"
8 8
9 #include <limits.h> 9 #include <limits.h>
10 10
11 #include <algorithm> 11 #include <algorithm>
12 12
13 #include "core/include/fpdfapi/cpdf_array.h"
14 #include "core/include/fpdfapi/cpdf_dictionary.h"
13 #include "core/include/fpdfapi/cpdf_document.h" 15 #include "core/include/fpdfapi/cpdf_document.h"
16 #include "core/include/fpdfapi/cpdf_string.h"
14 #include "core/include/fpdfapi/fpdf_module.h" 17 #include "core/include/fpdfapi/fpdf_module.h"
15 #include "core/include/fpdfapi/fpdf_page.h" 18 #include "core/include/fpdfapi/fpdf_page.h"
16 #include "core/include/fxcodec/fx_codec.h" 19 #include "core/include/fxcodec/fx_codec.h"
17 20
18 namespace { 21 namespace {
19 22
20 void sRGB_to_AdobeCMYK(FX_FLOAT R, 23 void sRGB_to_AdobeCMYK(FX_FLOAT R,
21 FX_FLOAT G, 24 FX_FLOAT G,
22 FX_FLOAT B, 25 FX_FLOAT B,
23 FX_FLOAT& c, 26 FX_FLOAT& c,
(...skipping 1514 matching lines...) Expand 10 before | Expand all | Expand 10 after
1538 if (!m_pBuffer || m_pCS->GetFamily() != PDFCS_PATTERN) { 1541 if (!m_pBuffer || m_pCS->GetFamily() != PDFCS_PATTERN) {
1539 return NULL; 1542 return NULL;
1540 } 1543 }
1541 PatternValue* pvalue = (PatternValue*)m_pBuffer; 1544 PatternValue* pvalue = (PatternValue*)m_pBuffer;
1542 return pvalue->m_nComps ? pvalue->m_Comps : NULL; 1545 return pvalue->m_nComps ? pvalue->m_Comps : NULL;
1543 } 1546 }
1544 FX_BOOL CPDF_Color::IsEqual(const CPDF_Color& other) const { 1547 FX_BOOL CPDF_Color::IsEqual(const CPDF_Color& other) const {
1545 return m_pCS && m_pCS == other.m_pCS && 1548 return m_pCS && m_pCS == other.m_pCS &&
1546 FXSYS_memcmp(m_pBuffer, other.m_pBuffer, m_pCS->GetBufSize()) == 0; 1549 FXSYS_memcmp(m_pBuffer, other.m_pBuffer, m_pCS->GetBufSize()) == 0;
1547 } 1550 }
OLDNEW
« no previous file with comments | « core/src/fpdfapi/fpdf_page/fpdf_page.cpp ('k') | core/src/fpdfapi/fpdf_page/fpdf_page_doc.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698