Obsolete Members for QQuickWindow

以下成員源於類 QQuickWindow 已過時。 提供它們是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它們。

公共函數

(obsolete) QSGTexture * createTextureFromId (uint id , const QSize & size , QQuickWindow::CreateTextureOptions options = CreateTextureOption()) const
(obsolete) bool sendEvent (QQuickItem * item , QEvent * e )

成員函數文檔編製

QSGTexture *QQuickWindow:: createTextureFromId ( uint id , const QSize & size , QQuickWindow::CreateTextureOptions options = CreateTextureOption()) const

此函數已過時。提供它是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它。

創建新的 QSGTexture object from an existing OpenGL texture id and size .

The caller of the function is responsible for deleting the returned texture.

The returned texture will be using GL_TEXTURE_2D as texture target and assumes that internal format is GL_RGBA 。重實現 QSGTexture 能創建具有不同參數的紋理。

使用 options to customize the texture attributes. The TextureUsesAtlas option is ignored.

警告: This function will return null if the scenegraph has not yet been initialized or OpenGL is not in use.

注意: 此函數纔起作用,當使用默認 OpenGL 場景圖形適配時。

注意: This function has no effect when running on the RHI graphics abstraction. Use createTextureFromNativeObject () 代替。

另請參閱 sceneGraphInitialized () 和 QSGTexture .

bool QQuickWindow:: sendEvent ( QQuickItem * item , QEvent * e )

此函數已過時。提供它是為使舊源代碼能繼續工作。強烈建議不要在新代碼中使用它。

Propagates an event e QQuickItem item on the window.

使用 QCoreApplication::sendEvent () directly instead.

The return value is currently not used.