En esta página

QRhiDriverInfo Struct

Describe el dispositivo físico, el adaptador o la implementación de la API gráfica que utiliza un objeto ` QRhi` inicializado. Más información...

Encabezado: #include <rhi/qrhi.h>
CMake: find_package(Qt6 REQUIRED COMPONENTS GuiPrivate)
target_link_libraries(mytarget PRIVATE Qt6::GuiPrivate)
qmake: QT += gui-private
Desde: Qt 6.6

Tipos públicos

enum DeviceType { UnknownDevice, IntegratedDevice, DiscreteDevice, ExternalDevice, VirtualDevice, CpuDevice }

Variables públicas

quint64 deviceId
QByteArray deviceName
QRhiDriverInfo::DeviceType deviceType
quint64 vendorId

Descripción detallada

Las API gráficas ofrecen diferentes niveles y tipos de información. El único valor disponible en todas las API es « deviceName », que es una descripción de texto libre del dispositivo físico o del adaptador, o bien una combinación de las cadenas devueltas por « GL_VENDOR », « GL_RENDERER » y « GL_VERSION ». « deviceId » es siempre 0 para OpenGL. « vendorId » es siempre 0 para OpenGL y Metal. « deviceType » es siempre « UnknownDevice » para OpenGL y Direct 3D.

Nota: Se trata de una API de RHI con garantías de compatibilidad limitadas; consulta QRhi para obtener más detalles.

Documentación sobre los tipos de miembros

enum QRhiDriverInfo::DeviceType

Especifica el tipo de dispositivo gráfico, cuando la información está disponible.

En la práctica, esto solo es aplicable con Vulkan y Metal. Con Direct 3D 11 y 12, el uso de un adaptador con el indicador de software activado da como resultado el valor « CpuDevice ». En los demás casos, y con OpenGL, el valor es siempre «UnknownDevice».

ConstanteValor
QRhiDriverInfo::UnknownDevice0
QRhiDriverInfo::IntegratedDevice1
QRhiDriverInfo::DiscreteDevice2
QRhiDriverInfo::ExternalDevice3
QRhiDriverInfo::VirtualDevice4
QRhiDriverInfo::CpuDevice5

Documentación de la variable miembro

quint64 QRhiDriverInfo::deviceId

Véase también QRhi::driverInfo().

QByteArray QRhiDriverInfo::deviceName

Véase también QRhi::driverInfo().

QRhiDriverInfo::DeviceType QRhiDriverInfo::deviceType

Véase también QRhi::driverInfo() y QRhiDriverInfo::DeviceType.

quint64 QRhiDriverInfo::vendorId

Véase también QRhi::driverInfo().

© 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.