Line data Source code
1 :
2 : /* Copyright (c) 2016, Stefan Eilemann <eile@eyescale.ch>
3 : *
4 : * This library is free software; you can redistribute it and/or modify it under
5 : * the terms of the GNU Lesser General Public License version 2.1 as published
6 : * by the Free Software Foundation.
7 : *
8 : * This library is distributed in the hope that it will be useful, but WITHOUT
9 : * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
10 : * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
11 : * details.
12 : *
13 : * You should have received a copy of the GNU Lesser General Public License
14 : * along with this library; if not, write to the Free Software Foundation, Inc.,
15 : * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
16 : */
17 :
18 : #ifndef PRESSION_PLUGIN_COMPRESSORZSTD
19 : #define PRESSION_PLUGIN_COMPRESSORZSTD
20 :
21 : #include "compressor.h"
22 :
23 : namespace pression
24 : {
25 : namespace plugin
26 : {
27 :
28 : class CompressorZSTD : public Compressor
29 : {
30 : public:
31 37 : CompressorZSTD() : Compressor() {}
32 74 : virtual ~CompressorZSTD() {}
33 :
34 : void compress( const void* const inData, const eq_uint64_t nPixels,
35 : const bool useAlpha ) override;
36 :
37 : static void decompress( const void* const* inData,
38 : const eq_uint64_t* const inSizes,
39 : unsigned nInputs, void* const outData,
40 : eq_uint64_t* const outDims, eq_uint64_t flags,
41 : void* const );
42 :
43 37 : static Compressor* getNewCompressor( const unsigned /*name*/ )
44 37 : { return new CompressorZSTD; }
45 : };
46 : }
47 : }
48 : #endif
|