fbfcd56021
This CL is part I of IV (I broke down the 1280 files into 4 CLs). Review URL: https://codereview.appspot.com/6485054 git-svn-id: http://skia.googlecode.com/svn/trunk@5262 2bbb7eff-a529-9590-31e7-b0007b416f81
53 lines
1.3 KiB
C++
53 lines
1.3 KiB
C++
|
|
/*
|
|
* Copyright 2010 The Android Open Source Project
|
|
*
|
|
* Use of this source code is governed by a BSD-style license that can be
|
|
* found in the LICENSE file.
|
|
*/
|
|
|
|
|
|
#ifndef SkFlate_DEFINED
|
|
#define SkFlate_DEFINED
|
|
|
|
#include "SkTypes.h"
|
|
|
|
class SkData;
|
|
class SkWStream;
|
|
class SkStream;
|
|
|
|
/** \class SkFlate
|
|
A class to provide access to the flate compression algorithm.
|
|
*/
|
|
class SkFlate {
|
|
public:
|
|
/** Indicates if the flate algorithm is available.
|
|
*/
|
|
static bool HaveFlate();
|
|
|
|
/**
|
|
* Use the flate compression algorithm to compress the data in src,
|
|
* putting the result into dst. Returns false if an error occurs.
|
|
*/
|
|
static bool Deflate(SkStream* src, SkWStream* dst);
|
|
|
|
/**
|
|
* Use the flate compression algorithm to compress the data in src,
|
|
* putting the result into dst. Returns false if an error occurs.
|
|
*/
|
|
static bool Deflate(const void* src, size_t len, SkWStream* dst);
|
|
|
|
/**
|
|
* Use the flate compression algorithm to compress the data,
|
|
* putting the result into dst. Returns false if an error occurs.
|
|
*/
|
|
static bool Deflate(const SkData*, SkWStream* dst);
|
|
|
|
/** Use the flate compression algorithm to decompress the data in src,
|
|
putting the result into dst. Returns false if an error occurs.
|
|
*/
|
|
static bool Inflate(SkStream* src, SkWStream* dst);
|
|
};
|
|
|
|
#endif
|