LibreOffice Module vcl (master) 1
PngImageReader.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
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 *
9 */
10
11#ifndef INCLUDED_VCL_FILTER_PNGIMAGEREADER_HXX
12#define INCLUDED_VCL_FILTER_PNGIMAGEREADER_HXX
13
14#include <sal/config.h>
15
16#include <memory>
17#include <vector>
18
19#include <vcl/dllapi.h>
21
22#include <com/sun/star/uno/Reference.hxx>
23
25{
26class XStatusIndicator;
27}
28
29class Graphic;
30class BitmapEx;
31class SvStream;
32
33namespace vcl
34{
36{
38 css::uno::Reference<css::task::XStatusIndicator> mxStatusIndicator;
39
40public:
41 PngImageReader(SvStream& rStream);
42
43 // Returns true if image was successfully read without errors.
44 // A usable bitmap may be returned even if there were errors (e.g. incomplete image).
45 bool read(BitmapEx& rBitmap);
46 bool read(Graphic& rGraphic);
47 // Returns a bitmap without indicating if there were errors.
48 BitmapEx read();
49
50 // Returns the contents of the msOG chunk (containing a Gif image), if it exists.
51 // Does not change position in the stream.
52 static BinaryDataContainer getMicrosoftGifChunk(SvStream& rStream);
53
54 static bool isAPng(SvStream& rStream);
55};
56
57} // namespace vcl
58
59#endif
60
61/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
Container for the binary data, whose responsibility is to manage the make it as simple as possible to...
css::uno::Reference< css::task::XStatusIndicator > mxStatusIndicator
#define VCL_DLLPUBLIC
Definition: dllapi.h:29