bump product version to 7.6.3.2-android
[LibreOffice.git] / include / vcl / filter / PngImageWriter.hxx
blobdb34e0826136d0292622ab5c9c894a2004e3a9e7
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 */
10 #include <vcl/dllapi.h>
11 #include <com/sun/star/task/XStatusIndicator.hpp>
12 #include <com/sun/star/beans/PropertyValue.hpp>
13 #include <com/sun/star/uno/Sequence.hxx>
14 #include <tools/stream.hxx>
15 #include <vcl/bitmapex.hxx>
16 #include <vector>
18 #pragma once
20 namespace vcl
22 // Similar to png_unknown_chunk
23 struct PngChunk
25 std::array<uint8_t, 5> name;
26 std::vector<sal_uInt8> data;
27 size_t size;
29 class VCL_DLLPUBLIC PngImageWriter
31 SvStream& mrStream;
32 css::uno::Reference<css::task::XStatusIndicator> mxStatusIndicator;
34 sal_Int32 mnCompressionLevel;
35 bool mbInterlaced, mbTranslucent;
36 std::vector<PngChunk> maAdditionalChunks;
38 public:
39 PngImageWriter(SvStream& rStream);
41 void setParameters(css::uno::Sequence<css::beans::PropertyValue> const& rParameters);
42 bool write(const BitmapEx& rBitmap);
45 } // namespace vcl
47 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */