mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-13 05:12:11 +08:00
504453c3e4
* support live streaming * update live stream's time * cleanup stream classes * disable video control in live streaming mode * emit streamStarted() in LiveStream::streamThread * disable some features in live streaming mode * refactor charts to support live streaming mode * disable dynamic mode checkbox in live streaming mode * updateDispalyRange * thread safe events * TODO: add support for ZMQ * atomic time stamp * only keep settings.cached_segment_limit*60 seconds data in liveStream * make charts work better in live mode * cleanup ChartView * fix toolbar * cleanup cleanup * disable openpilotPrefix and useOpenGL on macos * add comment * exit gracefully * support ZMQ * use ::operator new/delete * cleanup streams * cleanup * align stream buffers * check looping back * check if series is empty * cleanup * add TODO: write stream to log file to replay it * upper_bound * remove class member event_range * change default settings value * cleanup updateDisplayrange * fix merge error old-commit-hash: f9490739ab37ae680aef272d51eb3cf2b36b4103
43 lines
720 B
C++
43 lines
720 B
C++
#pragma once
|
|
|
|
#include <QByteArray>
|
|
#include <QComboBox>
|
|
#include <QDialog>
|
|
#include <QSpinBox>
|
|
|
|
class Settings : public QObject {
|
|
Q_OBJECT
|
|
|
|
public:
|
|
Settings();
|
|
void save();
|
|
void load();
|
|
|
|
int fps = 10;
|
|
int cached_segment_limit = 5;
|
|
int chart_height = 200;
|
|
int chart_column_count = 1;
|
|
int max_chart_x_range = 3 * 60; // 3 minutes
|
|
QString last_dir;
|
|
QByteArray geometry;
|
|
QByteArray video_splitter_state;
|
|
QByteArray window_state;
|
|
|
|
signals:
|
|
void changed();
|
|
};
|
|
|
|
class SettingsDlg : public QDialog {
|
|
Q_OBJECT
|
|
|
|
public:
|
|
SettingsDlg(QWidget *parent);
|
|
void save();
|
|
QSpinBox *fps;
|
|
QSpinBox *cached_segment;
|
|
QSpinBox *chart_height;
|
|
QSpinBox *max_chart_x_range;
|
|
};
|
|
|
|
extern Settings settings;
|