内容表

上一话题

QSGGeometry.Point2D

下一话题

QQuickFramebufferObject

QQuickAsyncImageProvider

QQuickAsyncImageProvider class provides an interface for for asynchronous control of QML image requests. 更多 …

Inheritance diagram of PySide2.QtQuick.QQuickAsyncImageProvider

New in version 5.6.

详细描述

见 Image Response Provider Example for a complete implementation.

class QQuickAsyncImageProvider
PySide2.QtQuick.QQuickAsyncImageProvider. requestImageResponse ( id , requestedSize )
参数
  • id – unicode

  • requestedSize – QSize

返回类型

QQuickImageResponse

Implement this method to return the job that will provide the texture with id .

id is the requested image source, with the “image:” scheme and provider identifier removed. For example, if the image source was “image://myprovider/icons/home”, the given id would be “icons/home”.

requestedSize corresponds to the Image::sourceSize requested by an Image item. If requestedSize is a valid size, the image returned should be of that size.

注意

this method may be called by multiple threads, so ensure the implementation of this method is reentrant.