From ad95ec8759777c4b8df0dcd66fd8200d24e912b1 Mon Sep 17 00:00:00 2001 From: Anton Date: Fri, 14 Aug 2026 01:29:59 +0400 Subject: pica-client: VAAPI hardware acceleration --- pica-client/dialogs/settingsdialog.h | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'pica-client/dialogs/settingsdialog.h') 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); }; -- cgit v1.2.1