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

Side by Side Diff: core/src/fxcodec/codec/fx_codec_png.cpp

Issue 1392373004: Rename lpng and tiff to third_party/ (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@xfa
Patch Set: GN Created 5 years, 2 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
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 "../../../include/fxcodec/fx_codec.h" 7 #include "../../../include/fxcodec/fx_codec.h"
8 #include "../../../include/fxge/fx_dib.h" 8 #include "../../../include/fxge/fx_dib.h"
9 #include "codec_int.h" 9 #include "codec_int.h"
10 extern "C" { 10 extern "C" {
11 #undef FAR 11 #undef FAR
12 #include "../fx_lpng/include/fx_png.h" 12 #include "../../../../third_party/lpng_v163/png.h"
13 } 13 }
14 static void _png_error_data(png_structp png_ptr, png_const_charp error_msg) { 14 static void _png_error_data(png_structp png_ptr, png_const_charp error_msg) {
15 if (png_get_error_ptr(png_ptr)) { 15 if (png_get_error_ptr(png_ptr)) {
16 FXSYS_strncpy((char*)png_get_error_ptr(png_ptr), error_msg, 16 FXSYS_strncpy((char*)png_get_error_ptr(png_ptr), error_msg,
17 PNG_ERROR_SIZE - 1); 17 PNG_ERROR_SIZE - 1);
18 } 18 }
19 longjmp(png_jmpbuf(png_ptr), 1); 19 longjmp(png_jmpbuf(png_ptr), 1);
20 } 20 }
21 static void _png_warning_data(png_structp png_ptr, png_const_charp error_msg) {} 21 static void _png_warning_data(png_structp png_ptr, png_const_charp error_msg) {}
22 static void _png_load_bmp_attribute(png_structp png_ptr, 22 static void _png_load_bmp_attribute(png_structp png_ptr,
(...skipping 220 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 if (setjmp(png_jmpbuf(p->png_ptr))) { 243 if (setjmp(png_jmpbuf(p->png_ptr))) {
244 if (pAttribute && 244 if (pAttribute &&
245 0 == FXSYS_strcmp(m_szLastError, "Read Header Callback Error")) { 245 0 == FXSYS_strcmp(m_szLastError, "Read Header Callback Error")) {
246 _png_load_bmp_attribute(p->png_ptr, p->info_ptr, pAttribute); 246 _png_load_bmp_attribute(p->png_ptr, p->info_ptr, pAttribute);
247 } 247 }
248 return FALSE; 248 return FALSE;
249 } 249 }
250 png_process_data(p->png_ptr, p->info_ptr, (uint8_t*)src_buf, src_size); 250 png_process_data(p->png_ptr, p->info_ptr, (uint8_t*)src_buf, src_size);
251 return TRUE; 251 return TRUE;
252 } 252 }
OLDNEW
« no previous file with comments | « BUILD.gn ('k') | core/src/fxcodec/codec/fx_codec_tiff.cpp » ('j') | third_party/BUILD.gn » ('J')

Powered by Google App Engine
This is Rietveld 408576698