-
Suggestion
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
6.6.3, 6.7.2
I need to achieve low-latency real-time video streaming playback. In my software, I use the win11 system, qt6.6.3 or 6.7.2, VideoOutput+QVideoSink to play the existing YUV420 video data, and I find that the rendering speed is slow, but
Set at the beginning of main
QQuickWindow::setGraphicsApi(QSGRendererInterface::OpenGL);
Then the rendering is very fast, 80~100ms faster. The decoding layer will not affect this delay, because I use ffmpeg to implement decoding alone, and Qt only participates in rendering.
This can be tested simply using the QML Video Recorder in the case.
The following picture is on a dual-screen PC. The left side shows the timing on the other screen in real time.
1. Enable OpenGL globally
2. not use OpenGL
Enabling OpenGL will make the rendering faster. I know that Qt6 uses d3d11 for rendering globally in win11, which can be known by using QQuickWindow::graphicsApi();. But why is d3d11 not as fast as opengl in rendering videos? Is there any problem when QRHI uses d3d11 to render videos?