154 QOpenGLContext context;
155 if (context.create()) {
156# ifdef QT_OPENGL_DYNAMIC
157 str <<
"Dynamic GL ";
159 switch (context.openGLModuleType()) {
160 case QOpenGLContext::LibGL:
163 case QOpenGLContext::LibGLES:
168 window.setSurfaceType(QSurface::OpenGLSurface);
170 context.makeCurrent(&window);
171 QOpenGLFunctions functions(&context);
173 str <<
" Vendor: " <<
reinterpret_cast<
const char *>(functions.glGetString(GL_VENDOR))
174 <<
"\nRenderer: " <<
reinterpret_cast<
const char *>(functions.glGetString(GL_RENDERER))
175 <<
"\nVersion: " <<
reinterpret_cast<
const char *>(functions.glGetString(GL_VERSION))
176 <<
"\nShading language: " <<
reinterpret_cast<
const char *>(functions.glGetString(GL_SHADING_LANGUAGE_VERSION))
177 <<
"\nFormat: " << context.format();
178# if !QT_CONFIG(opengles2)
180 functions.glGetIntegerv(GL_MAJOR_VERSION, &majorVersion);
182 functions.glGetIntegerv(GL_MINOR_VERSION, &minorVersion);
183 const QByteArray openGlVersionFunctionsName =
"QOpenGLFunctions_"
184 + QByteArray::number(majorVersion) +
'_' + QByteArray::number(minorVersion);
185 str <<
"\nProfile: None (" << openGlVersionFunctionsName <<
')';
186 if (majorVersion > 3 || (majorVersion == 3 && minorVersion >= 1)) {
187 QOpenGLVersionProfile profile;
188 profile.setVersion(majorVersion, minorVersion);
189 profile.setProfile(QSurfaceFormat::CoreProfile);
190 if (
auto f = QOpenGLVersionFunctionsFactory::get(profile, &context)) {
191 if (f->initializeOpenGLFunctions())
192 str <<
", Core (" << openGlVersionFunctionsName <<
"_Core)";
194 profile.setProfile(QSurfaceFormat::CompatibilityProfile);
195 if (
auto f = QOpenGLVersionFunctionsFactory::get(profile, &context)) {
196 if (f->initializeOpenGLFunctions())
197 str <<
", Compatibility (" << openGlVersionFunctionsName <<
"_Compatibility)";
202 if (listExtensions) {
203 QByteArrayList extensionList = context.extensions().values();
204 std::sort(extensionList.begin(), extensionList.end());
205 str <<
" \nFound " << extensionList.size() <<
" extensions:\n";
206 for (
const QByteArray &extension : std::as_const(extensionList))
207 str <<
" " << extension <<
'\n';
210 str <<
"Unable to create an Open GL context.\n";
254void dumpRhiBackendInfo(QTextStream &str,
const char *name, QRhi::Implementation impl, QRhiInitParams *initParams)
260 const RhiFeature features[] = {
261 {
"MultisampleTexture", QRhi::MultisampleTexture },
262 {
"MultisampleRenderBuffer", QRhi::MultisampleRenderBuffer },
263 {
"DebugMarkers", QRhi::DebugMarkers },
264 {
"Timestamps", QRhi::Timestamps },
265 {
"Instancing", QRhi::Instancing },
266 {
"CustomInstanceStepRate", QRhi::CustomInstanceStepRate },
267 {
"PrimitiveRestart", QRhi::PrimitiveRestart },
268 {
"NonDynamicUniformBuffers", QRhi::NonDynamicUniformBuffers },
269 {
"NonFourAlignedEffectiveIndexBufferOffset", QRhi::NonFourAlignedEffectiveIndexBufferOffset },
270 {
"NPOTTextureRepeat", QRhi::NPOTTextureRepeat },
271 {
"RedOrAlpha8IsRed", QRhi::RedOrAlpha8IsRed },
272 {
"ElementIndexUint", QRhi::ElementIndexUint },
273 {
"Compute", QRhi::Compute },
274 {
"WideLines", QRhi::WideLines },
275 {
"VertexShaderPointSize", QRhi::VertexShaderPointSize },
276 {
"BaseVertex", QRhi::BaseVertex },
277 {
"BaseInstance", QRhi::BaseInstance },
278 {
"TriangleFanTopology", QRhi::TriangleFanTopology },
279 {
"ReadBackNonUniformBuffer", QRhi::ReadBackNonUniformBuffer },
280 {
"ReadBackNonBaseMipLevel", QRhi::ReadBackNonBaseMipLevel },
281 {
"TexelFetch", QRhi::TexelFetch },
282 {
"RenderToNonBaseMipLevel", QRhi::RenderToNonBaseMipLevel },
283 {
"IntAttributes", QRhi::IntAttributes },
284 {
"ScreenSpaceDerivatives", QRhi::ScreenSpaceDerivatives },
285 {
"ReadBackAnyTextureFormat", QRhi::ReadBackAnyTextureFormat },
286 {
"PipelineCacheDataLoadSave", QRhi::PipelineCacheDataLoadSave },
287 {
"ImageDataStride", QRhi::ImageDataStride },
288 {
"RenderBufferImport", QRhi::RenderBufferImport },
289 {
"ThreeDimensionalTextures", QRhi::ThreeDimensionalTextures },
290 {
"RenderTo3DTextureSlice", QRhi::RenderTo3DTextureSlice },
291 {
"TextureArrays", QRhi::TextureArrays },
292 {
"Tessellation", QRhi::Tessellation },
293 {
"GeometryShader", QRhi::GeometryShader },
294 {
"TextureArrayRange", QRhi::TextureArrayRange },
295 {
"NonFillPolygonMode", QRhi::NonFillPolygonMode },
296 {
"OneDimensionalTextures", QRhi::OneDimensionalTextures },
297 {
"OneDimensionalTextureMipmaps", QRhi::OneDimensionalTextureMipmaps },
298 {
"HalfAttributes", QRhi::HalfAttributes },
299 {
"RenderToOneDimensionalTexture", QRhi::RenderToOneDimensionalTexture },
300 {
"ThreeDimensionalTextureMipmaps", QRhi::ThreeDimensionalTextureMipmaps },
302 {
nullptr, QRhi::Feature(0) }
304 struct RhiTextureFormat {
306 QRhiTexture::Format val;
308 const RhiTextureFormat textureFormats[] = {
309 {
"RGBA8", QRhiTexture::RGBA8 },
310 {
"BGRA8", QRhiTexture::BGRA8 },
311 {
"R8", QRhiTexture::R8 },
312 {
"RG8", QRhiTexture::RG8 },
313 {
"R16", QRhiTexture::R16 },
314 {
"RG16", QRhiTexture::RG16 },
315 {
"RED_OR_ALPHA8", QRhiTexture::RED_OR_ALPHA8 },
316 {
"RGBA16F", QRhiTexture::RGBA16F },
317 {
"RGBA32F", QRhiTexture::RGBA32F },
318 {
"R16F", QRhiTexture::R16F },
319 {
"R32F", QRhiTexture::R32F },
320 {
"RGB10A2", QRhiTexture::RGB10A2 },
321 {
"D16", QRhiTexture::D16 },
322 {
"D24", QRhiTexture::D24 },
323 {
"D24S8", QRhiTexture::D24S8 },
324 {
"D32F", QRhiTexture::D32F },
325 {
"BC1", QRhiTexture::BC1 },
326 {
"BC2", QRhiTexture::BC2 },
327 {
"BC3", QRhiTexture::BC3 },
328 {
"BC4", QRhiTexture::BC4 },
329 {
"BC5", QRhiTexture::BC5 },
330 {
"BC6H", QRhiTexture::BC6H },
331 {
"BC7", QRhiTexture::BC7 },
332 {
"ETC2_RGB8", QRhiTexture::ETC2_RGB8 },
333 {
"ETC2_RGB8A1", QRhiTexture::ETC2_RGB8A1 },
334 {
"ETC2_RGBA8", QRhiTexture::ETC2_RGBA8 },
335 {
"ASTC_4x4", QRhiTexture::ASTC_4x4 },
336 {
"ASTC_5x4", QRhiTexture::ASTC_5x4 },
337 {
"ASTC_5x5", QRhiTexture::ASTC_5x5 },
338 {
"ASTC_6x5", QRhiTexture::ASTC_6x5 },
339 {
"ASTC_6x6", QRhiTexture::ASTC_6x6 },
340 {
"ASTC_8x5", QRhiTexture::ASTC_8x5 },
341 {
"ASTC_8x6", QRhiTexture::ASTC_8x6 },
342 {
"ASTC_8x8", QRhiTexture::ASTC_8x8 },
343 {
"ASTC_10x5", QRhiTexture::ASTC_10x5 },
344 {
"ASTC_10x6", QRhiTexture::ASTC_10x6 },
345 {
"ASTC_10x8", QRhiTexture::ASTC_10x8 },
346 {
"ASTC_10x10", QRhiTexture::ASTC_10x10 },
347 {
"ASTC_12x10", QRhiTexture::ASTC_12x10 },
348 {
"ASTC_12x12", QRhiTexture::ASTC_12x12 },
349 {
nullptr, QRhiTexture::UnknownFormat }
352 QScopedPointer<QRhi> rhi(QRhi::create(impl, initParams, QRhi::Flags(),
nullptr));
354 str << name <<
":\n";
355 str <<
" Driver Info: " << rhi->driverInfo() <<
"\n";
356 str <<
" Min Texture Size: " << rhi->resourceLimit(QRhi::TextureSizeMin) <<
"\n";
357 str <<
" Max Texture Size: " << rhi->resourceLimit(QRhi::TextureSizeMax) <<
"\n";
358 str <<
" Max Color Attachments: " << rhi->resourceLimit(QRhi::MaxColorAttachments) <<
"\n";
359 str <<
" Frames in Flight: " << rhi->resourceLimit(QRhi::FramesInFlight) <<
"\n";
360 str <<
" Async Readback Limit: " << rhi->resourceLimit(QRhi::MaxAsyncReadbackFrames) <<
"\n";
361 str <<
" MaxThreadGroupsPerDimension: " << rhi->resourceLimit(QRhi::MaxThreadGroupsPerDimension) <<
"\n";
362 str <<
" MaxThreadsPerThreadGroup: " << rhi->resourceLimit(QRhi::MaxThreadsPerThreadGroup) <<
"\n";
363 str <<
" MaxThreadGroupX: " << rhi->resourceLimit(QRhi::MaxThreadGroupX) <<
"\n";
364 str <<
" MaxThreadGroupY: " << rhi->resourceLimit(QRhi::MaxThreadGroupY) <<
"\n";
365 str <<
" MaxThreadGroupZ: " << rhi->resourceLimit(QRhi::MaxThreadGroupZ) <<
"\n";
366 str <<
" TextureArraySizeMax: " << rhi->resourceLimit(QRhi::TextureArraySizeMax) <<
"\n";
367 str <<
" MaxUniformBufferRange: " << rhi->resourceLimit(QRhi::MaxUniformBufferRange) <<
"\n";
368 str <<
" MaxVertexInputs: " << rhi->resourceLimit(QRhi::MaxVertexInputs) <<
"\n";
369 str <<
" MaxVertexOutputs: " << rhi->resourceLimit(QRhi::MaxVertexOutputs) <<
"\n";
370 str <<
" Uniform Buffer Alignment: " << rhi->ubufAlignment() <<
"\n";
371 QByteArrayList supportedSampleCounts;
372 for (
int s : rhi->supportedSampleCounts())
373 supportedSampleCounts << QByteArray::number(s);
374 str <<
" Supported MSAA sample counts: " << supportedSampleCounts.join(
',') <<
"\n";
375 str <<
" Features:\n";
376 for (
int i = 0; features[i].name; i++) {
377 str <<
" " << (rhi->isFeatureSupported(features[i].val) ?
"v" :
"-") <<
" " << features[i].name <<
"\n";
379 str <<
" Texture formats:";
380 for (
int i = 0; textureFormats[i].name; i++) {
381 if (rhi->isTextureFormatSupported(textureFormats[i].val))
382 str <<
" " << textureFormats[i].name;
566 const QPlatformIntegration *platformIntegration = QGuiApplicationPrivate::platformIntegration();
567 str << QLibraryInfo::build() <<
" on \"" << QGuiApplication::platformName() <<
"\" "
569 <<
"OS: " << QSysInfo::prettyProductName()
570 <<
" [" << QSysInfo::kernelType() <<
" version " << QSysInfo::kernelVersion() <<
"]\n";
572 str <<
"\nArchitecture: " << QSysInfo::currentCpuArchitecture() <<
"; features:";
573#if defined(Q_PROCESSOR_X86)
574 DUMP_CPU_FEATURE(HYBRID,
"hybrid");
575 DUMP_CPU_FEATURE(SSE2,
"SSE2");
576 DUMP_CPU_FEATURE(SSE3,
"SSE3");
577 DUMP_CPU_FEATURE(SSSE3,
"SSSE3");
578 DUMP_CPU_FEATURE(SSE4_1,
"SSE4.1");
579 DUMP_CPU_FEATURE(SSE4_2,
"SSE4.2");
580 DUMP_CPU_FEATURE(AVX,
"AVX");
581 DUMP_CPU_FEATURE(AVX2,
"AVX2");
582 DUMP_CPU_FEATURE(AVX512F,
"AVX512F");
583 DUMP_CPU_FEATURE(AVX512IFMA,
"AVX512IFMA");
584 DUMP_CPU_FEATURE(AVX512VBMI2,
"AVX512VBMI2");
585 DUMP_CPU_FEATURE(AVX512FP16,
"AVX512FP16");
586 DUMP_CPU_FEATURE(RDRND,
"RDRAND");
587 DUMP_CPU_FEATURE(RDSEED,
"RDSEED");
588 DUMP_CPU_FEATURE(AES,
"AES");
589 DUMP_CPU_FEATURE(VAES,
"VAES");
590 DUMP_CPU_FEATURE(SHA,
"SHA");
591#elif defined(Q_PROCESSOR_ARM)
592 DUMP_CPU_FEATURE(ARM_NEON,
"Neon");
593#elif defined(Q_PROCESSOR_MIPS)
594 DUMP_CPU_FEATURE(DSP,
"DSP");
595 DUMP_CPU_FEATURE(DSPR2,
"DSPR2");
599#if QT_CONFIG(process)
600 const QProcessEnvironment systemEnvironment = QProcessEnvironment::systemEnvironment();
601 str <<
"\nEnvironment:\n";
602 const QStringList keys = systemEnvironment.keys();
603 for (
const QString &key : keys) {
604 if (key.size() < 2 || !key.startsWith(QLatin1Char(
'Q')))
606 if (key.at(1) ==
'T' || key.at(1) ==
'_')
607 str <<
" " << key <<
"=\"" << systemEnvironment.value(key) <<
"\"\n";
611 const QByteArrayList features = qtFeatures();
612 if (!features.isEmpty())
613 str <<
"\nFeatures: " << features.join(
' ') <<
'\n';
615 str <<
"\nLibrary info:\n";
631 str <<
"\nStandard paths [*...* denote writable entry]:\n";
652 str <<
"\nFile selectors (increasing order of precedence):\n ";
653 const QStringList allSelectors = QFileSelector().allSelectors();
654 for (
const QString &s : allSelectors)
657 str <<
"\n\nNetwork:\n ";
660 if (QSslSocket::supportsSsl()) {
661 str <<
"Using \"" << QSslSocket::sslLibraryVersionString() <<
"\", version: 0x"
662 << Qt::hex << QSslSocket::sslLibraryVersionNumber() << Qt::dec;
664 str <<
"\nSSL is not supported.";
667 str <<
"SSL is not available.";
670 str <<
"Qt Network module is not available.";
673 str <<
"\n\nPlatform capabilities:";
693 const QStyleHints *styleHints = QGuiApplication::styleHints();
694 const QChar passwordMaskCharacter = styleHints->passwordMaskCharacter();
695 str <<
"\nStyle hints:\n mouseDoubleClickInterval: " << styleHints->mouseDoubleClickInterval() <<
'\n'
696 <<
" mousePressAndHoldInterval: " << styleHints->mousePressAndHoldInterval() <<
'\n'
697 <<
" startDragDistance: " << styleHints->startDragDistance() <<
'\n'
698 <<
" startDragTime: " << styleHints->startDragTime() <<
'\n'
699 <<
" startDragVelocity: " << styleHints->startDragVelocity() <<
'\n'
700 <<
" keyboardInputInterval: " << styleHints->keyboardInputInterval() <<
'\n'
701 <<
" keyboardAutoRepeatRateF: " << styleHints->keyboardAutoRepeatRateF() <<
'\n'
702 <<
" cursorFlashTime: " << styleHints->cursorFlashTime() <<
'\n'
703 <<
" showIsFullScreen: " << styleHints->showIsFullScreen() <<
'\n'
704 <<
" showIsMaximized: " << styleHints->showIsMaximized() <<
'\n'
705 <<
" passwordMaskDelay: " << styleHints->passwordMaskDelay() <<
'\n'
706 <<
" passwordMaskCharacter: ";
707 const int passwordMaskCharacterUc = passwordMaskCharacter.unicode();
708 if (passwordMaskCharacterUc >= 32 && passwordMaskCharacterUc < 128) {
709 str <<
'\'' << passwordMaskCharacter <<
'\'';
711 str <<
"U+" << qSetFieldWidth(4) << qSetPadChar(
'0') << Qt::uppercasedigits << Qt::hex
712 << passwordMaskCharacterUc << Qt::dec << qSetFieldWidth(0);
715 <<
" fontSmoothingGamma: " << styleHints->fontSmoothingGamma() <<
'\n'
716 <<
" useRtlExtensions: " << styleHints->useRtlExtensions() <<
'\n'
717 <<
" setFocusOnTouchRelease: " << styleHints->setFocusOnTouchRelease() <<
'\n'
718 <<
" tabFocusBehavior: " << formatQDebug(styleHints->tabFocusBehavior()) <<
'\n'
719 <<
" singleClickActivation: " << styleHints->singleClickActivation() <<
'\n';
720 str <<
"\nAdditional style hints (QPlatformIntegration):\n"
721 <<
" ReplayMousePressOutsidePopup: "
722 << platformIntegration->styleHint(QPlatformIntegration::ReplayMousePressOutsidePopup).toBool() <<
'\n';
724 const QPlatformTheme *platformTheme = QGuiApplicationPrivate::platformTheme();
726 "\n Platforms requested : " << platformIntegration->themeNames()
727 <<
"\n available : " << QPlatformThemeFactory::keys()
729 <<
"\n Styles requested : " << platformTheme->themeHint(QPlatformTheme::StyleNames).toStringList()
730 <<
"\n available : " << QStyleFactory::keys()
733 const QString iconTheme = platformTheme->themeHint(QPlatformTheme::SystemIconThemeName).toString();
734 if (!iconTheme.isEmpty()) {
735 str <<
"\n Icon theme : " << iconTheme
736 <<
", " << platformTheme->themeHint(QPlatformTheme::SystemIconFallbackThemeName).toString()
737 <<
" from " << platformTheme->themeHint(QPlatformTheme::IconThemeSearchPaths).toStringList();
739 if (
const QFont *systemFont = platformTheme->font())
740 str <<
"\n System font : " << *systemFont<<
'\n';
742 if (platformTheme->usePlatformNativeDialog(QPlatformTheme::FileDialog))
743 str <<
" Native file dialog\n";
744 if (platformTheme->usePlatformNativeDialog(QPlatformTheme::ColorDialog))
745 str <<
" Native color dialog\n";
746 if (platformTheme->usePlatformNativeDialog(QPlatformTheme::FontDialog))
747 str <<
" Native font dialog\n";
748 if (platformTheme->usePlatformNativeDialog(QPlatformTheme::MessageDialog))
749 str <<
" Native message dialog\n";
751 str <<
"\nFonts:\n General font : " << QFontDatabase::systemFont(QFontDatabase::GeneralFont) <<
'\n'
752 <<
" Fixed font : " << QFontDatabase::systemFont(QFontDatabase::FixedFont) <<
'\n'
753 <<
" Title font : " << QFontDatabase::systemFont(QFontDatabase::TitleFont) <<
'\n'
754 <<
" Smallest font: " << QFontDatabase::systemFont(QFontDatabase::SmallestReadableFont) <<
'\n';
755 if (flags & QtDiagFonts) {
756 const QStringList families = QFontDatabase::families();
757 str <<
"\n Families (" << families.size() <<
"):\n";
758 for (
int i = 0, count = families.size(); i < count; ++i)
759 str <<
" " << families.at(i) <<
'\n';
761 const QList<
int> standardSizes = QFontDatabase::standardSizes();
762 str <<
"\n Standard Sizes:";
763 for (
int i = 0, count = standardSizes.size(); i < count; ++i)
764 str <<
' ' << standardSizes.at(i);
765 QList<QFontDatabase::WritingSystem> writingSystems = QFontDatabase::writingSystems();
766 str <<
"\n\n Writing systems:\n";
767 for (
int i = 0, count = writingSystems.size(); i < count; ++i)
768 str <<
" " << formatValueQDebug(writingSystems.at(i)) <<
'\n';
771 str <<
"\nPalette:\n" << QGuiApplication::palette();
773 const QList<QScreen*> screens = QGuiApplication::screens();
774 const int screenCount = screens.size();
775 str <<
"\nScreens: " << screenCount <<
", High DPI scaling: "
776 << (QHighDpiScaling::isActive() ?
"active" :
"inactive") <<
'\n';
777 for (
int s = 0; s < screenCount; ++s) {
778 const QScreen *screen = screens.at(s);
779 const QPlatformScreen *platformScreen = screen->handle();
780 const QRect geometry = screen->geometry();
781 const QDpi dpi(screen->logicalDotsPerInchX(), screen->logicalDotsPerInchY());
782 const QDpi nativeDpi = platformScreen->logicalDpi();
783 const QRect nativeGeometry = platformScreen->geometry();
784 str <<
'#' <<
' ' << s <<
" \"" << screen->name() <<
'"'
785 <<
" Depth: " << screen->depth()
786 <<
" Primary: " << (screen == QGuiApplication::primaryScreen() ?
"yes" :
"no")
787 <<
"\n Manufacturer: " << screen->manufacturer()
788 <<
"\n Model: " << screen->model()
789 <<
"\n Serial number: " << screen->serialNumber()
790 <<
"\n Geometry: " << geometry;
791 if (geometry != nativeGeometry)
792 str <<
" (native: " << nativeGeometry <<
')';
793 str <<
" Available: " << screen->availableGeometry();
794 if (geometry != screen->virtualGeometry())
795 str <<
"\n Virtual geometry: " << screen->virtualGeometry() <<
" Available: " << screen->availableVirtualGeometry();
796 if (screen->virtualSiblings().size() > 1)
797 str <<
"\n " << screen->virtualSiblings().size() <<
" virtual siblings";
798 str <<
"\n Physical size: " << screen->physicalSize() <<
" mm"
799 <<
" Refresh: " << screen->refreshRate() <<
" Hz"
800 <<
" Power state: " << platformScreen->powerState();
801 str <<
"\n Physical DPI: " << screen->physicalDotsPerInchX()
802 <<
',' << screen->physicalDotsPerInchY()
803 <<
" Logical DPI: " << dpi;
804 if (dpi != nativeDpi)
805 str <<
" (native: " << nativeDpi <<
')';
806 str <<
' ' << platformScreen->subpixelAntialiasingTypeHint() <<
"\n ";
807 if (QHighDpiScaling::isActive())
808 str <<
"High DPI scaling factor: " << QHighDpiScaling::factor(screen) <<
' ';
809 str <<
"DevicePixelRatio: " << screen->devicePixelRatio();
810 str <<
"\n Primary orientation: " << screen->primaryOrientation()
811 <<
" Orientation: " << screen->orientation()
812 <<
" Native orientation: " << screen->nativeOrientation()
816 const auto inputDevices = QInputDevice::devices();
817 if (!inputDevices.isEmpty()) {
818 str <<
"Input devices: " << inputDevices.size() <<
'\n';
819 for (
auto device : inputDevices) {
820 str <<
" " << formatValueQDebug(device->type())
821 <<
" \"" << device->name() <<
"\",";
822 if (!device->seatName().isEmpty())
823 str <<
" seat: \"" << device->seatName() <<
'"';
824 str <<
" capabilities:";
825 const auto capabilities = device->capabilities();
826 if (capabilities.testFlag(QInputDevice::Capability::Position))
828 if (capabilities.testFlag(QInputDevice::Capability::Area))
830 if (capabilities.testFlag(QInputDevice::Capability::Pressure))
832 if (capabilities.testFlag(QInputDevice::Capability::Velocity))
834 if (capabilities.testFlag(QInputDevice::Capability::NormalizedPosition))
835 str <<
" NormalizedPosition";
836 if (capabilities.testFlag(QInputDevice::Capability::MouseEmulation))
837 str <<
" MouseEmulation";
838 if (capabilities.testFlag(QInputDevice::Capability::Scroll))
840 if (capabilities.testFlag(QInputDevice::Capability::Hover))
842 if (capabilities.testFlag(QInputDevice::Capability::Rotation))
844 if (capabilities.testFlag(QInputDevice::Capability::XTilt))
846 if (capabilities.testFlag(QInputDevice::Capability::YTilt))
848 if (capabilities.testFlag(QInputDevice::Capability::TangentialPressure))
849 str <<
" TangentialPressure";
850 if (capabilities.testFlag(QInputDevice::Capability::ZPosition))
852 if (!device->availableVirtualGeometry().isNull()) {
853 const auto r = device->availableVirtualGeometry();
854 str <<
" availableVirtualGeometry: " << r.width() <<
'x' << r.height()
855 << Qt::forcesign << r.x() << r.y() << Qt::noforcesign;
863 if (flags & QtDiagGl) {
864 dumpGlInfo(str, flags & QtDiagGlExtensions);
872 if (flags & QtDiagVk) {
880 using QWindowsApplication = QNativeInterface::Private::QWindowsApplication;
881 if (
auto nativeWindowsApp =
dynamic_cast<QWindowsApplication *>(QGuiApplicationPrivate::platformIntegration())) {
882 const QVariant gpuInfoV = nativeWindowsApp->gpuList();
883 if (gpuInfoV.typeId() == QMetaType::QVariantList) {
884 const auto gpuList = gpuInfoV.toList();
885 for (
int i = 0; i < gpuList.size(); ++i) {
886 const QString description =
887 gpuList.at(i).toMap().value(QStringLiteral(
"printable")).toString();
888 if (!description.isEmpty())
889 str <<
"\nGPU #" << (i + 1) <<
":\n" << description <<
'\n';
896 if (flags & QtDiagRhi) {