1// Copyright (C) 2013 Klaralvdalens Datakonsult AB (KDAB).
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QOPENGLPIXELUPLOADOPTIONS_H
5#define QOPENGLPIXELUPLOADOPTIONS_H
6
7#include <QtOpenGL/qtopenglglobal.h>
8
9#if !defined(QT_NO_OPENGL)
10
11#include <QtCore/QSharedDataPointer>
12
13QT_BEGIN_NAMESPACE
14
15class QOpenGLPixelTransferOptionsData;
16
17class Q_OPENGL_EXPORT QOpenGLPixelTransferOptions
18{
19public:
20 QOpenGLPixelTransferOptions();
21 QOpenGLPixelTransferOptions(const QOpenGLPixelTransferOptions &);
22 QT_MOVE_ASSIGNMENT_OPERATOR_IMPL_VIA_PURE_SWAP(QOpenGLPixelTransferOptions)
23 QOpenGLPixelTransferOptions &operator=(const QOpenGLPixelTransferOptions &);
24 ~QOpenGLPixelTransferOptions();
25
26 void swap(QOpenGLPixelTransferOptions &other) noexcept
27 { data.swap(other&: other.data); }
28
29 void setAlignment(int alignment);
30 int alignment() const;
31
32 void setSkipImages(int skipImages);
33 int skipImages() const;
34
35 void setSkipRows(int skipRows);
36 int skipRows() const;
37
38 void setSkipPixels(int skipPixels);
39 int skipPixels() const;
40
41 void setImageHeight(int imageHeight);
42 int imageHeight() const;
43
44 void setRowLength(int rowLength);
45 int rowLength() const;
46
47 void setLeastSignificantByteFirst(bool lsbFirst);
48 bool isLeastSignificantBitFirst() const;
49
50 void setSwapBytesEnabled(bool swapBytes);
51 bool isSwapBytesEnabled() const;
52
53private:
54 QSharedDataPointer<QOpenGLPixelTransferOptionsData> data;
55};
56
57Q_DECLARE_SHARED(QOpenGLPixelTransferOptions)
58
59QT_END_NAMESPACE
60
61#endif // QT_NO_OPENGL
62
63#endif // QOPENGLPIXELUPLOADOPTIONS_H
64

source code of qtbase/src/opengl/qopenglpixeltransferoptions.h