1// qquickimageprovider.sip generated by MetaSIP 2// 3// This file is part of the QtQuick Python extension module. 4// 5// Copyright (c) 2021 Riverbank Computing Limited <info@riverbankcomputing.com> 6// 7// This file is part of PyQt5. 8// 9// This file may be used under the terms of the GNU General Public License 10// version 3.0 as published by the Free Software Foundation and appearing in 11// the file LICENSE included in the packaging of this file. Please review the 12// following information to ensure the GNU General Public License version 3.0 13// requirements will be met: http://www.gnu.org/copyleft/gpl.html. 14// 15// If you do not wish to use this file under the terms of the GPL version 3.0 16// then you may purchase a commercial license. For more information contact 17// info@riverbankcomputing.com. 18// 19// This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 20// WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 21 22 23class QQuickTextureFactory : QObject 24{ 25%TypeHeaderCode 26#include <qquickimageprovider.h> 27%End 28 29public: 30 QQuickTextureFactory(); 31 virtual ~QQuickTextureFactory(); 32 virtual QSGTexture *createTexture(QQuickWindow *window) const = 0 /Factory/; 33 virtual QSize textureSize() const = 0; 34 virtual int textureByteCount() const = 0; 35 virtual QImage image() const; 36%If (Qt_5_6_0 -) 37 static QQuickTextureFactory *textureFactoryForImage(const QImage &image) /Factory/; 38%End 39}; 40 41class QQuickImageProvider : QQmlImageProviderBase 42{ 43%TypeHeaderCode 44#include <qquickimageprovider.h> 45%End 46 47public: 48 QQuickImageProvider(QQmlImageProviderBase::ImageType type, QQmlImageProviderBase::Flags flags = QQmlImageProviderBase::Flags()); 49 virtual ~QQuickImageProvider(); 50 virtual QQmlImageProviderBase::ImageType imageType() const; 51 virtual QQmlImageProviderBase::Flags flags() const; 52 virtual QImage requestImage(const QString &id, QSize *size /Out/, const QSize &requestedSize); 53 virtual QPixmap requestPixmap(const QString &id, QSize *size /Out/, const QSize &requestedSize); 54 virtual QQuickTextureFactory *requestTexture(const QString &id, QSize *size /Out/, const QSize &requestedSize) /Factory/; 55}; 56 57%If (Qt_5_6_0 -) 58 59class QQuickImageResponse : QObject 60{ 61%TypeHeaderCode 62#include <qquickimageprovider.h> 63%End 64 65public: 66 QQuickImageResponse(); 67 virtual ~QQuickImageResponse(); 68 virtual QQuickTextureFactory *textureFactory() const = 0 /Factory/; 69 virtual QString errorString() const; 70 71public slots: 72 virtual void cancel(); 73 74signals: 75 void finished(); 76}; 77 78%End 79%If (Qt_5_6_0 -) 80 81class QQuickAsyncImageProvider : QQuickImageProvider 82{ 83%TypeHeaderCode 84#include <qquickimageprovider.h> 85%End 86 87public: 88 QQuickAsyncImageProvider(); 89 virtual ~QQuickAsyncImageProvider(); 90 virtual QQuickImageResponse *requestImageResponse(const QString &id, const QSize &requestedSize) = 0 /Factory/; 91}; 92 93%End 94