1// Copyright (C) 2016 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 QT3DRENDER_QSTENCILOPERATION_P_H
5#define QT3DRENDER_QSTENCILOPERATION_P_H
6
7//
8// W A R N I N G
9// -------------
10//
11// This file is not part of the Qt API. It exists for the convenience
12// of other Qt classes. This header file may change from version to
13// version without notice, or even be removed.
14//
15// We mean it.
16//
17
18#include <Qt3DRender/private/qrenderstate_p.h>
19#include <Qt3DRender/qstenciloperation.h>
20#include <Qt3DRender/qstenciloperationarguments.h>
21#include <Qt3DRender/private/qstenciloperationarguments_p.h>
22#include <Qt3DRender/private/qt3drender_global_p.h>
23
24QT_BEGIN_NAMESPACE
25
26namespace Qt3DRender {
27
28struct QStencilOperationData
29{
30 QStencilOperationArgumentsData front;
31 QStencilOperationArgumentsData back;
32};
33
34class Q_3DRENDERSHARED_PRIVATE_EXPORT QStencilOperationPrivate : public QRenderStatePrivate
35{
36public:
37 QStencilOperationPrivate()
38 : QRenderStatePrivate(Render::StencilOpMask)
39 , m_front(new QStencilOperationArguments(QStencilOperationArguments::Front, q_ptr))
40 , m_back(new QStencilOperationArguments(QStencilOperationArguments::Back, q_ptr))
41 {}
42 ~QStencilOperationPrivate();
43
44 QStencilOperationArguments *m_front;
45 QStencilOperationArguments *m_back;
46
47 void fillData(QStencilOperationData &data) const;
48};
49
50} // namespace Qt3DRender
51
52QT_END_NAMESPACE
53
54Q_DECLARE_METATYPE(Qt3DRender::QStencilOperationData)
55
56#endif // QT3DRENDER_QSTENCILOPERATION_P_H
57

source code of qt3d/src/render/renderstates/qstenciloperation_p.h