QNativeInterface::QSGD3D11Texture Struct
Permite acceder a los objetos de textura de Direct3D 11 y facilita su adopción. Más información...
| Encabezado: | #include <QSGTexture> |
| CMake: | find_package(Qt6 REQUIRED COMPONENTS Quick) target_link_libraries(mytarget PRIVATE Qt6::Quick) |
| qmake: | QT += quick |
| Desde: | Qt 6.0 |
- Lista de todos los miembros, incluidos los heredados
- QSGD3D11Texture forma parte de Interfaces nativas.
Funciones públicas
| QSGD3D11Texture() | |
| QSGD3D11Texture(const QNativeInterface::QSGD3D11Texture &) | |
| QSGD3D11Texture(QNativeInterface::QSGD3D11Texture &&) | |
| virtual void * | nativeTexture() const = 0 |
| QNativeInterface::QSGD3D11Texture & | operator=(QNativeInterface::QSGD3D11Texture &&) |
| QNativeInterface::QSGD3D11Texture & | operator=(const QNativeInterface::QSGD3D11Texture &) |
Miembros públicos estáticos
(since 6.0) QSGTexture * | fromNative(void *texture, QQuickWindow *window, const QSize &size, QQuickWindow::CreateTextureOptions options = {}) |
Documentación de las funciones de miembro
[constexpr noexcept default] QSGD3D11Texture::QSGD3D11Texture()
Crea por defecto una instancia de ` QSGD3D11Texture`.
[delete] QSGD3D11Texture::QSGD3D11Texture(const QNativeInterface::QSGD3D11Texture &)
Crea una instancia de ` QSGD3D11Texture` mediante copia. Esta función se ha eliminado.
[delete] QSGD3D11Texture::QSGD3D11Texture(QNativeInterface::QSGD3D11Texture &&)
Crea una instancia de ` QSGD3D11Texture`. Esta función se ha eliminado.
[static, since 6.0] QSGTexture *QSGD3D11Texture::fromNative(void *texture, QQuickWindow *window, const QSize &size, QQuickWindow::CreateTextureOptions options = {})
Crea un nuevo objeto ` QSGTexture ` que envuelve un objeto ` texture ` de Direct 3D 11 ya existente para ` window`.
El objeto nativo queda envuelto por el QSGTexture resultante, pero no pasa a ser propiedad de este. Quien llama a la función es responsable de eliminar el QSGTexture devuelto, pero eso no destruirá el objeto nativo subyacente.
Actualmente, esta función solo es apta para texturas RGBA en 2D.
Advertencia: Esta función devolverá «null» si el grafo de escena aún no se ha inicializado.
Utiliza ` options ` para personalizar los atributos de la textura. Aquí solo se tienen en cuenta `TextureHasAlphaChannel` y `TextureHasMipmaps`.
size especifica el tamaño en píxeles.
Nota: Esta función debe llamarse en el hilo de renderizado del grafo de escena.
Esta función se introdujo en Qt 6.0.
Véase también ` QQuickWindow::sceneGraphInitialized()`, ` QSGTexture` , «Grafo de escena: importación de texturas Metal» y «Grafo de escena: importación de texturas Vulkan».
[pure virtual] void *QSGD3D11Texture::nativeTexture() const
Devuelve el objeto ID3D11Texture2D.
[delete] QNativeInterface::QSGD3D11Texture &QSGD3D11Texture::operator=(QNativeInterface::QSGD3D11Texture &&)
Asigna mediante «move» other a esta instancia de QSGD3D11Texture. Esta función se elimina.
[delete] QNativeInterface::QSGD3D11Texture &QSGD3D11Texture::operator=(const QNativeInterface::QSGD3D11Texture &)
Asigna por copia other a esta instancia de QSGD3D11Texture. Esta función se ha eliminado.
© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.