summaryrefslogtreecommitdiffstats
path: root/pica-client/dialogs/settingsdialog.h
diff options
context:
space:
mode:
authorAnton <anton@picapica.im>2026-08-14 01:29:59 +0400
committerAnton <anton@picapica.im>2026-08-14 01:29:59 +0400
commitad95ec8759777c4b8df0dcd66fd8200d24e912b1 (patch)
treec5da156d51d1839abaa3ae0804ae588ea64a8cf7 /pica-client/dialogs/settingsdialog.h
parent6ef469ba767574384c0373daa5363efb95102ed9 (diff)
downloadpica-pica-ad95ec8759777c4b8df0dcd66fd8200d24e912b1.tar.gz
pica-pica-ad95ec8759777c4b8df0dcd66fd8200d24e912b1.zip
pica-client: VAAPI hardware acceleration
Diffstat (limited to 'pica-client/dialogs/settingsdialog.h')
-rw-r--r--pica-client/dialogs/settingsdialog.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/pica-client/dialogs/settingsdialog.h b/pica-client/dialogs/settingsdialog.h
index a6e6832..e3ebea7 100644
--- a/pica-client/dialogs/settingsdialog.h
+++ b/pica-client/dialogs/settingsdialog.h
@@ -33,6 +33,9 @@
#include "../audiodevice.h"
#include "../videodevice.h"
#include "../toneplayer/toneplayer.h"
+#ifdef HAVE_VAAPI
+#include "../vaapivideowidget.h"
+#endif
class SettingsDialog : public QDialog
{
@@ -118,7 +121,20 @@ private:
// the network, so the whole chain can be checked from this dialog.
QPushButton *btVideoTest;
QLabel *videoPreview;
+ // Shown under the preview: the format the camera settled on, and whether
+ // the GPU or the CPU ended up doing the encoding and decoding.
+ QLabel *videoTestStatus;
+ QString videoTestFormat;
+ QString videoTestPathReport;
QCheckBox *cbPreferCompressed;
+#ifdef HAVE_VAAPI
+ QCheckBox *cbVaapiEncoding;
+ QCheckBox *cbVaapiDecoding;
+ QCheckBox *cbVaapiRendering;
+ // Shown in place of videoPreview while frames are being drawn straight
+ // from GPU memory; only one of the two is ever visible.
+ VaapiVideoWidget *videoPreviewGpu;
+#endif
VideoDevice *testCam;
VideoDevice *testDecoder;
QThread testCamThread;
@@ -159,8 +175,13 @@ private slots:
void toggleVideoTest();
void videoTestCaptureStarted(QString codec, int width, int height);
+ void videoTestPath(QString description);
void videoTestFragment(QByteArray data, bool is_last_fragment);
void videoTestFrame(QImage frame);
+#ifdef HAVE_VAAPI
+ void videoTestHwFrame(AVFramePtr frame);
+ void videoTestRenderFailed(QString message);
+#endif
void videoTestError(QString message);
};