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

Side by Side Diff: src/pdf/SkDeflateWStream.h

Issue 957323003: miniz support in SkFlate / PDF (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: class comment Created 5 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 | « src/core/SkFlate.cpp ('k') | src/pdf/SkDeflateWStream.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 /*
2 * Copyright 2015 Google Inc.
3 *
4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file.
6 */
7
8 #ifndef SkDeflateWStream_DEFINED
9 #define SkDeflateWStream_DEFINED
10
11 #include "SkStream.h"
12 // https://skia.org/dev/contrib/style#no-define-before-sktypes
13
14 #ifndef SK_NO_FLATE // Clients of this class should be guarded.
15
16 /**
17 * Wrap a stream in this class to compress the information written to
18 * this stream using the Deflate algorithm. Uses Zlib's
19 * Z_DEFAULT_COMPRESSION level.
20 *
21 * See http://en.wikipedia.org/wiki/DEFLATE
22 */
23 class SkDeflateWStream : public SkWStream {
24 public:
25 /** Does not take ownership of the stream. */
26 SkDeflateWStream(SkWStream*);
27
28 /** The destructor calls finalize(). */
29 ~SkDeflateWStream();
30
31 /** Write the end of the compressed stream. All subsequent calls to
32 write() will fail. Subsequent calls to finalize() do nothing. */
33 void finalize();
34
35 // The SkWStream interface:
36 bool write(const void*, size_t) SK_OVERRIDE;
37 size_t bytesWritten() const SK_OVERRIDE;
38
39 private:
40 struct Impl;
41 SkAutoTDelete<Impl> fImpl;
42 };
43 #endif // SK_NO_FLATE
44
45 #endif // SkDeflateWStream_DEFINED
OLDNEW
« no previous file with comments | « src/core/SkFlate.cpp ('k') | src/pdf/SkDeflateWStream.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698