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_QTEXTUREIMAGEDATAGENERATOR_H
5#define QT3DRENDER_QTEXTUREIMAGEDATAGENERATOR_H
6
7#include <Qt3DCore/qabstractfunctor.h>
8#include <Qt3DRender/qt3drender_global.h>
9#include <QtCore/QSharedPointer>
10
11// TO DO TexImageDataPtr -> QImageDataPtr + d_ptr
12// We might also get rid of the layer, face, mipmap level from
13// TexImageDataPtr and store that in the functor directly
14// or use the QTextureImage instead
15
16QT_BEGIN_NAMESPACE
17
18namespace Qt3DRender {
19
20class QTextureImageData;
21typedef QSharedPointer<QTextureImageData> QTextureImageDataPtr;
22
23class Q_3DRENDERSHARED_EXPORT QTextureImageDataGenerator : public Qt3DCore::QAbstractFunctor
24{
25public:
26 virtual ~QTextureImageDataGenerator();
27 virtual QTextureImageDataPtr operator()() = 0;
28 virtual bool operator ==(const QTextureImageDataGenerator &other) const = 0;
29};
30
31typedef QSharedPointer<QTextureImageDataGenerator> QTextureImageDataGeneratorPtr;
32
33} // namespace Qt3DRender
34
35QT_END_NAMESPACE
36
37Q_DECLARE_METATYPE(Qt3DRender::QTextureImageDataGeneratorPtr) // LCOV_EXCL_LINE
38
39#endif // QT3DRENDER_QTEXTUREIMAGEDATAGENERATOR_H
40

source code of qt3d/src/render/texture/qtextureimagedatagenerator.h