summaryrefslogtreecommitdiff
path: root/src/qcam/main_window.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/qcam/main_window.h')
-rw-r--r--src/qcam/main_window.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/qcam/main_window.h b/src/qcam/main_window.h
index 46a494a9..f58cb6a6 100644
--- a/src/qcam/main_window.h
+++ b/src/qcam/main_window.h
@@ -10,7 +10,10 @@
#include <map>
#include <memory>
+#include <QElapsedTimer>
#include <QMainWindow>
+#include <QObject>
+#include <QTimer>
#include <libcamera/camera.h>
#include <libcamera/stream.h>
@@ -28,10 +31,15 @@ enum {
class MainWindow : public QMainWindow
{
+ Q_OBJECT
+
public:
MainWindow(const OptionsParser::Options &options);
~MainWindow();
+private Q_SLOTS:
+ void updateTitle();
+
private:
int openCamera();
@@ -43,6 +51,8 @@ private:
int display(Buffer *buffer);
QString title_;
+ QTimer titleTimer_;
+
const OptionsParser::Options &options_;
std::shared_ptr<Camera> camera_;
@@ -51,6 +61,10 @@ private:
uint64_t lastBufferTime_;
+ QElapsedTimer frameRateInterval_;
+ uint32_t previousFrames_;
+ uint32_t framesCaptured_;
+
ViewFinder *viewfinder_;
};