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

Side by Side Diff: src/codec/SkPngCodec.cpp

Issue 2267343004: GN: more optional components: jpeg, pdf, png, xml (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Do not include png.h from SkPngCodec.h Created 4 years, 4 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 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBitmap.h" 8 #include "SkBitmap.h"
9 #include "SkCodecPriv.h" 9 #include "SkCodecPriv.h"
10 #include "SkColorPriv.h" 10 #include "SkColorPriv.h"
11 #include "SkColorSpace_Base.h" 11 #include "SkColorSpace_Base.h"
12 #include "SkColorTable.h" 12 #include "SkColorTable.h"
13 #include "SkMath.h" 13 #include "SkMath.h"
14 #include "SkOpts.h" 14 #include "SkOpts.h"
15 #include "SkPngCodec.h" 15 #include "SkPngCodec.h"
16 #include "SkPoint3.h" 16 #include "SkPoint3.h"
17 #include "SkSize.h" 17 #include "SkSize.h"
18 #include "SkStream.h" 18 #include "SkStream.h"
19 #include "SkSwizzler.h" 19 #include "SkSwizzler.h"
20 #include "SkTemplates.h" 20 #include "SkTemplates.h"
21 #include "SkUtils.h" 21 #include "SkUtils.h"
22 22
23 #include "png.h"
24
23 // This warning triggers false postives way too often in here. 25 // This warning triggers false postives way too often in here.
24 #if defined(__GNUC__) && !defined(__clang__) 26 #if defined(__GNUC__) && !defined(__clang__)
25 #pragma GCC diagnostic ignored "-Wclobbered" 27 #pragma GCC diagnostic ignored "-Wclobbered"
26 #endif 28 #endif
27 29
28 /////////////////////////////////////////////////////////////////////////////// 30 ///////////////////////////////////////////////////////////////////////////////
29 // Callback functions 31 // Callback functions
30 /////////////////////////////////////////////////////////////////////////////// 32 ///////////////////////////////////////////////////////////////////////////////
31 33
32 static void sk_error_fn(png_structp png_ptr, png_const_charp msg) { 34 static void sk_error_fn(png_structp png_ptr, png_const_charp msg) {
(...skipping 891 matching lines...) Expand 10 before | Expand all | Expand 10 after
924 SkCodec* outCodec; 926 SkCodec* outCodec;
925 if (read_header(stream, chunkReader, &outCodec, nullptr, nullptr)) { 927 if (read_header(stream, chunkReader, &outCodec, nullptr, nullptr)) {
926 // Codec has taken ownership of the stream. 928 // Codec has taken ownership of the stream.
927 SkASSERT(outCodec); 929 SkASSERT(outCodec);
928 streamDeleter.release(); 930 streamDeleter.release();
929 return outCodec; 931 return outCodec;
930 } 932 }
931 933
932 return nullptr; 934 return nullptr;
933 } 935 }
OLDNEW
« src/codec/SkPngCodec.h ('K') | « src/codec/SkPngCodec.h ('k') | src/pdf/SkPDFFont.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698